@pisell/pisellos 2.1.154 → 2.1.156

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.
Files changed (54) hide show
  1. package/dist/modules/Holder/index.d.ts +48 -0
  2. package/dist/modules/Holder/index.js +639 -0
  3. package/dist/modules/Holder/types.d.ts +123 -0
  4. package/dist/modules/Holder/types.js +1 -0
  5. package/dist/modules/Holder/utils.d.ts +13 -0
  6. package/dist/modules/Holder/utils.js +34 -0
  7. package/dist/modules/Order/index.d.ts +2 -1
  8. package/dist/modules/Order/index.js +18 -1
  9. package/dist/modules/Order/types.d.ts +2 -0
  10. package/dist/modules/Order/utils.d.ts +10 -0
  11. package/dist/modules/Order/utils.js +35 -3
  12. package/dist/modules/Product/types.d.ts +7 -0
  13. package/dist/modules/index.d.ts +1 -0
  14. package/dist/modules/index.js +2 -1
  15. package/dist/plugins/window.d.ts +1 -0
  16. package/dist/solution/BookingByStep/index.d.ts +16 -1
  17. package/dist/solution/BookingByStep/index.js +276 -204
  18. package/dist/solution/BookingByStep/types.d.ts +2 -1
  19. package/dist/solution/BookingByStep/types.js +3 -1
  20. package/dist/solution/ScanOrder/index.d.ts +2 -6
  21. package/dist/solution/ScanOrder/index.js +57 -250
  22. package/dist/solution/ScanOrder/types.d.ts +2 -20
  23. package/dist/solution/VenueBooking/index.d.ts +19 -0
  24. package/dist/solution/VenueBooking/index.js +963 -733
  25. package/dist/solution/VenueBooking/types.d.ts +2 -0
  26. package/dist/types/index.d.ts +1 -0
  27. package/lib/model/strategy/adapter/promotion/index.js +0 -49
  28. package/lib/modules/Holder/index.d.ts +48 -0
  29. package/lib/modules/Holder/index.js +401 -0
  30. package/lib/modules/Holder/types.d.ts +123 -0
  31. package/lib/modules/Holder/types.js +17 -0
  32. package/lib/modules/Holder/utils.d.ts +13 -0
  33. package/lib/modules/Holder/utils.js +71 -0
  34. package/lib/modules/Order/index.d.ts +2 -1
  35. package/lib/modules/Order/index.js +14 -0
  36. package/lib/modules/Order/types.d.ts +2 -0
  37. package/lib/modules/Order/utils.d.ts +10 -0
  38. package/lib/modules/Order/utils.js +36 -5
  39. package/lib/modules/Product/types.d.ts +7 -0
  40. package/lib/modules/index.d.ts +1 -0
  41. package/lib/modules/index.js +3 -1
  42. package/lib/plugins/window.d.ts +1 -0
  43. package/lib/solution/BookingByStep/index.d.ts +16 -1
  44. package/lib/solution/BookingByStep/index.js +39 -0
  45. package/lib/solution/BookingByStep/types.d.ts +2 -1
  46. package/lib/solution/BookingByStep/types.js +5 -0
  47. package/lib/solution/ScanOrder/index.d.ts +2 -6
  48. package/lib/solution/ScanOrder/index.js +47 -212
  49. package/lib/solution/ScanOrder/types.d.ts +2 -20
  50. package/lib/solution/VenueBooking/index.d.ts +19 -0
  51. package/lib/solution/VenueBooking/index.js +134 -16
  52. package/lib/solution/VenueBooking/types.d.ts +2 -0
  53. package/lib/types/index.d.ts +1 -0
  54. package/package.json +1 -1
@@ -7,6 +7,7 @@ import type { OpenDataAvailabilityResult } from '../../modules/OpenData';
7
7
  import type { ProductData } from '../../modules/Product/types';
8
8
  import { type CartItemSummary, type PaxInfo, type QuantityCheckResult, type QuantityLimitResult } from '../../model/strategy/adapter/itemRule';
9
9
  import type { StrategyConfig } from '../../model/strategy/type';
10
+ import type { IAppendFormRecordParams, IRefreshAllFormRecordsParams } from '../../modules/Holder/types';
10
11
  export * from './types';
11
12
  interface VenueBookingItemRuleRuntimeConfig {
12
13
  strategyConfigs?: StrategyConfig[];
@@ -52,6 +53,12 @@ export declare class VenueBookingImpl extends BaseModule implements Module {
52
53
  constructor(name?: string, version?: string);
53
54
  private normalizeCustomerId;
54
55
  private resolveCustomerIdFromLoginPayload;
56
+ private resolveHolderCustomerId;
57
+ /**
58
+ * 按商品 holder_config 预加载表单数据到 holderMap。
59
+ * appointment_booking 在加购时触发;venueBooking 在商品加载后预加载,避免 getHolderFormMap 为空。
60
+ */
61
+ private preloadHolderForms;
55
62
  private clearLoginEffectListeners;
56
63
  private registerLoginEffect;
57
64
  private registerCustomerLoginListeners;
@@ -194,6 +201,18 @@ export declare class VenueBookingImpl extends BaseModule implements Module {
194
201
  getUIState<T = any>(key: string): T | undefined;
195
202
  deleteUIState(key: string): void;
196
203
  setBookingHolder(bookingUid: string, holder: any): void;
204
+ /**
205
+ * 获取 holder 表单 map
206
+ */
207
+ getHolderFormMap(): import("../../modules/Holder").HolderFormMap;
208
+ /**
209
+ * UI 层触发:按当前 holderMap 批量刷新所有表单的 records
210
+ */
211
+ refreshAllHolderFormRecords(params?: Pick<IRefreshAllFormRecordsParams, 'customer_id' | 'useCache' | 'recordsUrl' | 'num' | 'skip'>): Promise<import("../../modules/Holder").HolderFormMap>;
212
+ /**
213
+ * 添加表单记录
214
+ */
215
+ appendFormRecord(params: IAppendFormRecordParams): import("../../modules/Holder").IFormRecord;
197
216
  checkOpenDataAvailability(): Promise<OpenDataAvailabilityResult>;
198
217
  setOtherParams(params: Record<string, any>, { cover }?: {
199
218
  cover?: boolean;