@pisell/pisellos 0.0.346 → 0.0.348
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/dist/modules/Product/index.d.ts +1 -1
- package/dist/solution/Checkout/index.js +5 -2
- package/dist/solution/RegisterAndLogin/config.js +2 -1
- package/dist/solution/RegisterAndLogin/types.d.ts +1 -0
- package/lib/modules/Product/index.d.ts +1 -1
- package/lib/solution/Checkout/index.js +1 -1
- package/lib/solution/RegisterAndLogin/config.js +2 -1
- package/lib/solution/RegisterAndLogin/types.d.ts +1 -0
- package/package.json +1 -1
|
@@ -49,5 +49,5 @@ export declare class Product extends BaseModule implements Module {
|
|
|
49
49
|
getCategories(): ProductCategory[];
|
|
50
50
|
setOtherParams(key: string, value: any): void;
|
|
51
51
|
getOtherParams(): any;
|
|
52
|
-
getProductType(): "
|
|
52
|
+
getProductType(): "normal" | "duration" | "session";
|
|
53
53
|
}
|
|
@@ -3191,8 +3191,11 @@ export var CheckoutImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
3191
3191
|
depositPaidAmount = paymentItems.filter(function (item) {
|
|
3192
3192
|
return item.order_payment_type === 'deposit' && item.status !== 'voided';
|
|
3193
3193
|
}).reduce(function (sum, item) {
|
|
3194
|
-
// 如果是 wallet
|
|
3195
|
-
|
|
3194
|
+
// 如果是 wallet,并且还没同步到后端,且此时还没有其他类型的支付项(现金,eftpos,标记支付),不计入已付金额
|
|
3195
|
+
// 如果有其他支付项了,代表此时处于马上要同步的状态,所以计入
|
|
3196
|
+
if (item.voucher_id && !item.isSynced && paymentItems.filter(function (item) {
|
|
3197
|
+
return !item.voucher_id;
|
|
3198
|
+
}).length === 0) {
|
|
3196
3199
|
return sum;
|
|
3197
3200
|
}
|
|
3198
3201
|
var amount = new Decimal(item.amount || '0');
|
|
@@ -49,5 +49,5 @@ export declare class Product extends BaseModule implements Module {
|
|
|
49
49
|
getCategories(): ProductCategory[];
|
|
50
50
|
setOtherParams(key: string, value: any): void;
|
|
51
51
|
getOtherParams(): any;
|
|
52
|
-
getProductType(): "
|
|
52
|
+
getProductType(): "normal" | "duration" | "session";
|
|
53
53
|
}
|
|
@@ -1967,7 +1967,7 @@ var CheckoutImpl = class extends import_BaseModule.BaseModule {
|
|
|
1967
1967
|
const depositPaidAmount = paymentItems.filter(
|
|
1968
1968
|
(item) => item.order_payment_type === "deposit" && item.status !== "voided"
|
|
1969
1969
|
).reduce((sum, item) => {
|
|
1970
|
-
if (item.voucher_id && !item.isSynced) {
|
|
1970
|
+
if (item.voucher_id && !item.isSynced && paymentItems.filter((item2) => !item2.voucher_id).length === 0) {
|
|
1971
1971
|
return sum;
|
|
1972
1972
|
}
|
|
1973
1973
|
const amount = new import_decimal.default(item.amount || "0");
|