@jetthai/cuora 1.1.355-dev-5 → 1.1.355-dev-6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [1.1.355-dev-6](https://github.com/jetthai/cuora-module/compare/v1.1.355-dev-5...v1.1.355-dev-6) (2025-04-29)
6
+
5
7
  ### [1.1.355-dev-5](https://github.com/jetthai/cuora-module/compare/v1.1.355-dev-4...v1.1.355-dev-5) (2025-04-29)
6
8
 
7
9
  ### [1.1.356](https://github.com/jetthai/cuora-module/compare/v1.1.355-dev-2...v1.1.356) (2025-04-29)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jetthai/cuora",
3
- "version": "1.1.355-dev-5",
3
+ "version": "1.1.355-dev-6",
4
4
  "description": "",
5
5
  "main": "./src/index.js",
6
6
  "type": "module",
@@ -151,15 +151,14 @@ export default function (request) {
151
151
  }
152
152
  }),
153
153
  setRankingOptions: assign((context, event) => {
154
+ const isChampion = event.data?.rule === 'CHAMPION'
154
155
  const cycle = event.data?.cycle
155
156
  const currentRound = event.data?.currentRound || []
156
157
  // 取得結算週期選單列表
157
- const cycleOptions = cycleMapping.slice(0, currentRound.length)
158
- // 取得每週期的歷史期數選單列表
159
- const cycles = event.data?.rule === 'NORMAL' ? [cycle] : cycleMapping
160
- const roundOptions = roundProcess(currentRound, cycles)
161
- // 如果是月結算,則加入全部選項
162
- if (cycle === 'MONTHLY') {
158
+ const cycleOptions = isChampion ? cycleMapping.slice(0, currentRound.length) : [cycle]
159
+ const roundOptions = roundProcess(currentRound, cycleOptions)
160
+ // 如果是冠軍龍虎月結算,則加入全部選項
161
+ if (cycle === 'MONTHLY' && isChampion) {
163
162
  cycleOptions.push('ALL')
164
163
  roundOptions.ALL = roundOptions.MONTHLY
165
164
  }
@@ -167,7 +166,7 @@ export default function (request) {
167
166
  ...event.data,
168
167
  options: { cycle: cycleOptions, round: roundOptions },
169
168
  // 初始固定顯示 DAILY
170
- cycle: event.data?.rule !== 'NORMAL' ? 'DAILY' : cycle,
169
+ cycle: isChampion ? 'DAILY' : cycle,
171
170
  round: currentRound[0],
172
171
  }
173
172
  }),