@jetthai/cuora 1.1.67 → 1.1.68
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.68](https://github.com/jetthai/cuora-module/compare/v1.1.67...v1.1.68) (2023-04-06)
|
|
6
|
+
|
|
5
7
|
### [1.1.67](https://github.com/jetthai/cuora-module/compare/v1.1.65-doubleWallet-2...v1.1.67) (2023-04-06)
|
|
6
8
|
|
|
7
9
|
### [1.1.66](https://github.com/jetthai/cuora-module/compare/v1.1.65...v1.1.66) (2023-03-28)
|
package/dist/bundle.mjs
CHANGED
|
@@ -23382,13 +23382,20 @@ function loadcard_vn (request) {
|
|
|
23382
23382
|
setInitData: assign((context, event) => {
|
|
23383
23383
|
const { siteConfig, paymentDetail } = event.data;
|
|
23384
23384
|
const cards = paymentDetail.filter((element) => element.category === context.currentCategory);
|
|
23385
|
+
let selectedCard = null;
|
|
23386
|
+
if (siteConfig.walletMode === '4') {
|
|
23387
|
+
selectedCard = cards.find((card) => parseFloat(`${card.charge || 0}`) === 0);
|
|
23388
|
+
} else {
|
|
23389
|
+
selectedCard = cards[0];
|
|
23390
|
+
}
|
|
23391
|
+
|
|
23385
23392
|
return {
|
|
23386
23393
|
siteConfig,
|
|
23387
23394
|
paymentDetail,
|
|
23388
23395
|
cards,
|
|
23389
|
-
selectedCard
|
|
23390
|
-
currentMethod:
|
|
23391
|
-
options:
|
|
23396
|
+
selectedCard,
|
|
23397
|
+
currentMethod: selectedCard?.method,
|
|
23398
|
+
options: selectedCard?.optional,
|
|
23392
23399
|
}
|
|
23393
23400
|
}),
|
|
23394
23401
|
setBonusPreview: assign((context, event) => {
|
|
@@ -23821,15 +23828,21 @@ function qrcode_v2 (request) {
|
|
|
23821
23828
|
setInitData: assign((context, event) => {
|
|
23822
23829
|
const { siteConfig, paymentDetail } = event.data;
|
|
23823
23830
|
const qrcodes = paymentDetail.filter((element) => element.category === context.currentCategory);
|
|
23831
|
+
let selectedQrcode = null;
|
|
23832
|
+
if (siteConfig.walletMode === '4') {
|
|
23833
|
+
selectedQrcode = qrcodes.find((qrcode) => parseFloat(`${qrcode.charge || 0}`) === 0);
|
|
23834
|
+
} else {
|
|
23835
|
+
selectedQrcode = qrcodes[0];
|
|
23836
|
+
}
|
|
23824
23837
|
|
|
23825
23838
|
return {
|
|
23826
23839
|
siteConfig,
|
|
23827
23840
|
paymentDetail,
|
|
23828
23841
|
qrcodes,
|
|
23829
|
-
selectedQrcode
|
|
23830
|
-
currentMethod:
|
|
23831
|
-
options:
|
|
23832
|
-
grandTotalEnable:
|
|
23842
|
+
selectedQrcode,
|
|
23843
|
+
currentMethod: selectedQrcode?.method,
|
|
23844
|
+
options: selectedQrcode?.optional,
|
|
23845
|
+
grandTotalEnable: selectedQrcode?.grandTotalEnable,
|
|
23833
23846
|
}
|
|
23834
23847
|
}),
|
|
23835
23848
|
setBonusPreview: assign((context, event) => {
|
|
@@ -25418,13 +25431,19 @@ function direct (request) {
|
|
|
25418
25431
|
setInitData: assign((context, event) => {
|
|
25419
25432
|
const { siteConfig, paymentDetail } = event.data;
|
|
25420
25433
|
const directs = paymentDetail.filter((element) => element.category === context.currentCategory);
|
|
25434
|
+
let currentDirect = null;
|
|
25435
|
+
if (siteConfig.walletMode === '4') {
|
|
25436
|
+
currentDirect = directs.find((direct) => parseFloat(`${direct.charge || 0}`) === 0);
|
|
25437
|
+
} else {
|
|
25438
|
+
currentDirect = directs[0];
|
|
25439
|
+
}
|
|
25421
25440
|
|
|
25422
25441
|
return {
|
|
25423
25442
|
siteConfig,
|
|
25424
25443
|
paymentDetail,
|
|
25425
25444
|
directs,
|
|
25426
|
-
currentDirect
|
|
25427
|
-
currentMethod:
|
|
25445
|
+
currentDirect,
|
|
25446
|
+
currentMethod: currentDirect?.method,
|
|
25428
25447
|
}
|
|
25429
25448
|
}),
|
|
25430
25449
|
setBanks: assign((context, event) => {
|
package/package.json
CHANGED
|
@@ -187,13 +187,20 @@ export default function (request) {
|
|
|
187
187
|
setInitData: assign((context, event) => {
|
|
188
188
|
const { siteConfig, paymentDetail } = event.data
|
|
189
189
|
const directs = paymentDetail.filter((element) => element.category === context.currentCategory)
|
|
190
|
+
let currentDirect = null
|
|
191
|
+
let currentMethod = null
|
|
192
|
+
if (siteConfig.walletMode === '4') {
|
|
193
|
+
currentDirect = directs.find((direct) => parseFloat(`${direct.charge || 0}`) === 0)
|
|
194
|
+
} else {
|
|
195
|
+
currentDirect = directs[0]
|
|
196
|
+
}
|
|
190
197
|
|
|
191
198
|
return {
|
|
192
199
|
siteConfig,
|
|
193
200
|
paymentDetail,
|
|
194
201
|
directs,
|
|
195
|
-
currentDirect
|
|
196
|
-
currentMethod:
|
|
202
|
+
currentDirect,
|
|
203
|
+
currentMethod: currentDirect?.method,
|
|
197
204
|
}
|
|
198
205
|
}),
|
|
199
206
|
setBanks: assign((context, event) => {
|
|
@@ -244,13 +244,20 @@ export default function (request) {
|
|
|
244
244
|
setInitData: assign((context, event) => {
|
|
245
245
|
const { siteConfig, paymentDetail } = event.data
|
|
246
246
|
const cards = paymentDetail.filter((element) => element.category === context.currentCategory)
|
|
247
|
+
let selectedCard = null
|
|
248
|
+
if (siteConfig.walletMode === '4') {
|
|
249
|
+
selectedCard = cards.find((card) => parseFloat(`${card.charge || 0}`) === 0)
|
|
250
|
+
} else {
|
|
251
|
+
selectedCard = cards[0]
|
|
252
|
+
}
|
|
253
|
+
|
|
247
254
|
return {
|
|
248
255
|
siteConfig,
|
|
249
256
|
paymentDetail,
|
|
250
257
|
cards,
|
|
251
|
-
selectedCard
|
|
252
|
-
currentMethod:
|
|
253
|
-
options:
|
|
258
|
+
selectedCard,
|
|
259
|
+
currentMethod: selectedCard?.method,
|
|
260
|
+
options: selectedCard?.optional,
|
|
254
261
|
}
|
|
255
262
|
}),
|
|
256
263
|
setBonusPreview: assign((context, event) => {
|
|
@@ -328,15 +328,21 @@ export default function (request) {
|
|
|
328
328
|
setInitData: assign((context, event) => {
|
|
329
329
|
const { siteConfig, paymentDetail } = event.data
|
|
330
330
|
const qrcodes = paymentDetail.filter((element) => element.category === context.currentCategory)
|
|
331
|
+
let selectedQrcode = null
|
|
332
|
+
if (siteConfig.walletMode === '4') {
|
|
333
|
+
selectedQrcode = qrcodes.find((qrcode) => parseFloat(`${qrcode.charge || 0}`) === 0)
|
|
334
|
+
} else {
|
|
335
|
+
selectedQrcode = qrcodes[0]
|
|
336
|
+
}
|
|
331
337
|
|
|
332
338
|
return {
|
|
333
339
|
siteConfig,
|
|
334
340
|
paymentDetail,
|
|
335
341
|
qrcodes,
|
|
336
|
-
selectedQrcode
|
|
337
|
-
currentMethod:
|
|
338
|
-
options:
|
|
339
|
-
grandTotalEnable:
|
|
342
|
+
selectedQrcode,
|
|
343
|
+
currentMethod: selectedQrcode?.method,
|
|
344
|
+
options: selectedQrcode?.optional,
|
|
345
|
+
grandTotalEnable: selectedQrcode?.grandTotalEnable,
|
|
340
346
|
}
|
|
341
347
|
}),
|
|
342
348
|
setBonusPreview: assign((context, event) => {
|