@pisell/pisellos 2.2.256 → 2.2.258
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/model/strategy/adapter/promotion/index.js +9 -0
- package/dist/modules/BookingContext/utils/buildCacheItemFromOrderLine.js +17 -13
- package/dist/modules/Order/index.d.ts +29 -1
- package/dist/modules/Order/index.js +508 -241
- package/dist/modules/Order/types.d.ts +20 -2
- package/dist/modules/Order/utils/bundleDiscountHydration.d.ts +5 -0
- package/dist/modules/Order/utils/bundleDiscountHydration.js +144 -0
- package/dist/modules/Order/utils.d.ts +4 -0
- package/dist/modules/Order/utils.js +114 -28
- package/dist/modules/Product/index.d.ts +1 -1
- package/dist/modules/Product/types.d.ts +6 -0
- package/dist/modules/Rules/index.d.ts +3 -3
- package/dist/modules/Rules/index.js +8 -3
- package/dist/modules/Rules/types.d.ts +2 -1
- package/dist/server/index.d.ts +12 -2
- package/dist/server/index.js +1227 -923
- package/dist/server/modules/order/index.d.ts +22 -3
- package/dist/server/modules/order/index.js +397 -314
- package/dist/solution/BaseSales/index.d.ts +16 -2
- package/dist/solution/BaseSales/index.js +484 -314
- package/dist/solution/BaseSales/types.d.ts +1 -0
- package/dist/solution/BaseSales/types.js +2 -1
- package/dist/solution/BaseSales/utils/transformBaseProductToOrderProduct.js +4 -2
- package/dist/solution/BookingByStep/index.d.ts +1 -1
- package/dist/solution/BookingTicket/index.d.ts +9 -1
- package/dist/solution/BookingTicket/index.js +162 -6
- package/lib/modules/BookingContext/utils/buildCacheItemFromOrderLine.js +11 -1
- package/lib/modules/Order/index.d.ts +29 -1
- package/lib/modules/Order/index.js +340 -57
- package/lib/modules/Order/types.d.ts +20 -2
- package/lib/modules/Order/utils/bundleDiscountHydration.d.ts +5 -0
- package/lib/modules/Order/utils/bundleDiscountHydration.js +139 -0
- package/lib/modules/Order/utils.d.ts +4 -0
- package/lib/modules/Order/utils.js +84 -2
- package/lib/modules/Product/index.d.ts +1 -1
- package/lib/modules/Product/types.d.ts +6 -0
- package/lib/modules/Rules/index.d.ts +3 -3
- package/lib/modules/Rules/index.js +4 -3
- package/lib/modules/Rules/types.d.ts +2 -1
- package/lib/server/index.d.ts +12 -2
- package/lib/server/index.js +218 -12
- package/lib/server/modules/order/index.d.ts +22 -3
- package/lib/server/modules/order/index.js +102 -51
- package/lib/solution/BaseSales/index.d.ts +16 -2
- package/lib/solution/BaseSales/index.js +143 -31
- package/lib/solution/BaseSales/types.d.ts +1 -0
- package/lib/solution/BaseSales/types.js +2 -1
- package/lib/solution/BaseSales/utils/transformBaseProductToOrderProduct.js +4 -5
- package/lib/solution/BookingByStep/index.d.ts +1 -1
- package/lib/solution/BookingTicket/index.d.ts +9 -1
- package/lib/solution/BookingTicket/index.js +112 -0
- package/package.json +1 -1
|
@@ -30,7 +30,7 @@ export declare class BaseSalesImpl extends BaseModule implements Module {
|
|
|
30
30
|
protected defaultVersion: string;
|
|
31
31
|
isSolution: boolean;
|
|
32
32
|
protected initializeOptions: ModuleOptions;
|
|
33
|
-
|
|
33
|
+
protected logger: any;
|
|
34
34
|
protected appPlugin: AppPlugin;
|
|
35
35
|
protected store: BaseSalesState;
|
|
36
36
|
protected otherParams: Record<string, any>;
|
|
@@ -46,6 +46,9 @@ export declare class BaseSalesImpl extends BaseModule implements Module {
|
|
|
46
46
|
protected hasManualDiscountSelection: boolean;
|
|
47
47
|
private readonly reusedSharedSubModuleNames;
|
|
48
48
|
private paymentMethodsCache;
|
|
49
|
+
private queuedAutoPaymentSync;
|
|
50
|
+
private autoPaymentSyncFlushing;
|
|
51
|
+
private autoPaymentSyncTimer;
|
|
49
52
|
constructor(name?: string, version?: string);
|
|
50
53
|
/**
|
|
51
54
|
* 子类可覆盖此方法以追加/收敛要注册的子模块。
|
|
@@ -195,6 +198,7 @@ export declare class BaseSalesImpl extends BaseModule implements Module {
|
|
|
195
198
|
payments?: OrderPaymentSource[];
|
|
196
199
|
paymentStatus?: BaseSalesPaymentStatus;
|
|
197
200
|
smallTicketDataFlag?: number;
|
|
201
|
+
confirmPendingVoucherPayments?: boolean;
|
|
198
202
|
enhancePayload?: SubmitPayloadEnhancer;
|
|
199
203
|
}): Promise<T>;
|
|
200
204
|
/**
|
|
@@ -207,12 +211,14 @@ export declare class BaseSalesImpl extends BaseModule implements Module {
|
|
|
207
211
|
payments?: OrderPaymentSource[];
|
|
208
212
|
paymentStatus?: BaseSalesPaymentStatus;
|
|
209
213
|
smallTicketDataFlag?: number;
|
|
214
|
+
confirmPendingVoucherPayments?: boolean;
|
|
210
215
|
enhancePayload?: SubmitPayloadEnhancer;
|
|
211
216
|
}): Promise<T>;
|
|
212
217
|
submitTempOrderAsync<T = any>(params?: {
|
|
213
218
|
payments?: OrderPaymentSource[];
|
|
214
219
|
paymentStatus?: BaseSalesPaymentStatus;
|
|
215
220
|
smallTicketDataFlag?: number;
|
|
221
|
+
confirmPendingVoucherPayments?: boolean;
|
|
216
222
|
enhancePayload?: SubmitPayloadEnhancer;
|
|
217
223
|
}): Promise<T>;
|
|
218
224
|
printLocalOrderReceipt<T = any>(lookup?: BaseSalesPrintLocalOrderReceiptParams): Promise<T>;
|
|
@@ -222,6 +228,10 @@ export declare class BaseSalesImpl extends BaseModule implements Module {
|
|
|
222
228
|
getOrderPayments(): OrderPaymentData[];
|
|
223
229
|
/** 覆盖当前订单支付项,内部由 OrderModule 清洗为 Sales 协议字段。 */
|
|
224
230
|
setOrderPayments(payments: OrderPaymentSource[]): OrderPaymentData[];
|
|
231
|
+
private getPaymentStatusForSync;
|
|
232
|
+
private queueLatestAutoPaymentSync;
|
|
233
|
+
private scheduleQueuedAutoPaymentSyncFlush;
|
|
234
|
+
private flushQueuedAutoPaymentSync;
|
|
225
235
|
/** 追加单个支付项到当前订单。 */
|
|
226
236
|
addOrderPayment(payment: OrderPaymentSource): OrderPaymentData[];
|
|
227
237
|
/** 更新当前订单中的指定支付项。 */
|
|
@@ -229,7 +239,11 @@ export declare class BaseSalesImpl extends BaseModule implements Module {
|
|
|
229
239
|
/** 删除当前订单中的指定支付项。 */
|
|
230
240
|
deleteOrderPayment(paymentIdentity: string | number): OrderPaymentData[];
|
|
231
241
|
/** 覆盖 wallet pass 支付项,同时保留普通支付项。 */
|
|
232
|
-
updateVoucherOrderPayments(payments: OrderPaymentSource[]
|
|
242
|
+
updateVoucherOrderPayments(payments: OrderPaymentSource[], options?: {
|
|
243
|
+
status?: 'paid' | 'payment_pending';
|
|
244
|
+
}): OrderPaymentData[];
|
|
245
|
+
confirmPendingVoucherPayments(): OrderPaymentData[];
|
|
246
|
+
discardPendingVoucherPayments(): OrderPaymentData[];
|
|
233
247
|
private getWalletProductList;
|
|
234
248
|
initWalletData(params?: {
|
|
235
249
|
order_wait_pay_amount?: number;
|