@pisell/pisellos 2.3.40 → 2.3.41

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 (230) hide show
  1. package/dist/core/index.d.ts +2 -0
  2. package/dist/core/index.js +7 -0
  3. package/dist/model/strategy/adapter/promotion/adapter.d.ts +4 -0
  4. package/dist/model/strategy/adapter/promotion/adapter.js +23 -0
  5. package/dist/model/strategy/adapter/promotion/evaluator.d.ts +17 -0
  6. package/dist/model/strategy/adapter/promotion/evaluator.js +279 -6
  7. package/dist/model/strategy/adapter/promotion/examples.d.ts +86 -0
  8. package/dist/model/strategy/adapter/promotion/examples.js +99 -0
  9. package/dist/model/strategy/adapter/promotion/index.d.ts +1 -1
  10. package/dist/model/strategy/adapter/promotion/index.js +9 -0
  11. package/dist/model/strategy/adapter/promotion/type.d.ts +90 -2
  12. package/dist/model/strategy/adapter/promotion/type.js +45 -0
  13. package/dist/modules/BookingContext/utils/buildCacheItemFromOrderLine.js +5 -3
  14. package/dist/modules/BookingContext/utils/buildNormalProductCacheItemFromOrderLine.js +6 -3
  15. package/dist/modules/Discount/index.d.ts +0 -1
  16. package/dist/modules/Discount/index.js +11 -40
  17. package/dist/modules/Discount/types.d.ts +0 -1
  18. package/dist/modules/OpenData/index.d.ts +2 -0
  19. package/dist/modules/OpenData/index.js +10 -2
  20. package/dist/modules/Order/index.d.ts +29 -12
  21. package/dist/modules/Order/index.js +750 -509
  22. package/dist/modules/Order/payment-utils.d.ts +26 -0
  23. package/dist/modules/Order/payment-utils.js +225 -0
  24. package/dist/modules/Order/types.d.ts +33 -10
  25. package/dist/modules/Order/utils/orderCollectionIdentity.js +7 -2
  26. package/dist/modules/Order/utils.d.ts +0 -10
  27. package/dist/modules/Order/utils.js +13 -41
  28. package/dist/modules/Payment/index.d.ts +2 -0
  29. package/dist/modules/Payment/index.js +79 -50
  30. package/dist/modules/Payment/types.d.ts +99 -28
  31. package/dist/modules/Payment/types.js +20 -3
  32. package/dist/modules/Payment/walletpass.d.ts +25 -1
  33. package/dist/modules/Payment/walletpass.js +707 -157
  34. package/dist/modules/Product/types.d.ts +0 -1
  35. package/dist/modules/ProductList/index.js +14 -33
  36. package/dist/modules/Quotation/index.d.ts +1 -1
  37. package/dist/modules/Quotation/index.js +2 -2
  38. package/dist/modules/Rules/index.d.ts +1 -0
  39. package/dist/modules/Rules/index.js +89 -96
  40. package/dist/modules/SalesSummary/index.js +13 -12
  41. package/dist/modules/ScanOrderLogger/index.d.ts +0 -2
  42. package/dist/modules/ScanOrderLogger/index.js +2 -15
  43. package/dist/modules/ScanOrderLogger/providers/feishu.js +27 -45
  44. package/dist/modules/ScanOrderLogger/types.d.ts +0 -1
  45. package/dist/modules/Schedule/index.d.ts +1 -3
  46. package/dist/modules/Schedule/index.js +16 -21
  47. package/dist/modules/Summary/utils.js +13 -38
  48. package/dist/modules/index.d.ts +0 -2
  49. package/dist/modules/index.js +1 -3
  50. package/dist/plugins/window.d.ts +0 -1
  51. package/dist/server/index.d.ts +16 -14
  52. package/dist/server/index.js +1925 -1143
  53. package/dist/server/modules/order/index.d.ts +54 -4
  54. package/dist/server/modules/order/index.js +1600 -700
  55. package/dist/server/modules/order/types.d.ts +11 -3
  56. package/dist/server/modules/order/types.js +1 -1
  57. package/dist/solution/BaseSales/index.d.ts +109 -20
  58. package/dist/solution/BaseSales/index.js +1800 -480
  59. package/dist/solution/BaseSales/types.d.ts +52 -0
  60. package/dist/solution/BaseSales/types.js +2 -1
  61. package/dist/solution/BaseSales/utils/cartPromotion.d.ts +3 -1
  62. package/dist/solution/BaseSales/utils/cartPromotion.js +90 -31
  63. package/dist/solution/BaseSales/utils/parseSalesResponse.d.ts +6 -1
  64. package/dist/solution/BookingByStep/index.d.ts +2 -17
  65. package/dist/solution/BookingByStep/index.js +215 -294
  66. package/dist/solution/BookingByStep/types.d.ts +1 -2
  67. package/dist/solution/BookingByStep/types.js +1 -3
  68. package/dist/solution/BookingByStep/utils/capacity.js +1 -17
  69. package/dist/solution/BookingByStep/utils/timeslots.d.ts +1 -3
  70. package/dist/solution/BookingByStep/utils/timeslots.js +12 -19
  71. package/dist/solution/BookingTicket/index.d.ts +8 -4
  72. package/dist/solution/BookingTicket/index.js +134 -51
  73. package/dist/solution/BookingTicket/utils/addProductDecision.js +6 -0
  74. package/dist/solution/BookingTicket/utils/scan/applyGlobalScan.d.ts +8 -0
  75. package/dist/solution/BookingTicket/utils/scan/applyGlobalScan.js +172 -82
  76. package/dist/solution/BookingTicket/utils/scan/handleScan.d.ts +1 -3
  77. package/dist/solution/BookingTicket/utils/scan/handleScan.js +2 -10
  78. package/dist/solution/BookingTicket/utils/weighingProductSku.d.ts +5 -0
  79. package/dist/solution/BookingTicket/utils/weighingProductSku.js +45 -0
  80. package/dist/solution/Sales/index.d.ts +1 -0
  81. package/dist/solution/Sales/index.js +10 -2
  82. package/dist/solution/ScanOrder/index.d.ts +14 -26
  83. package/dist/solution/ScanOrder/index.js +756 -1148
  84. package/dist/solution/ScanOrder/types.d.ts +1 -21
  85. package/dist/solution/ScanOrder/utils.d.ts +0 -8
  86. package/dist/solution/ScanOrder/utils.js +25 -66
  87. package/dist/solution/ShopDiscount/index.d.ts +0 -1
  88. package/dist/solution/ShopDiscount/index.js +87 -125
  89. package/dist/solution/VenueBooking/index.d.ts +11 -39
  90. package/dist/solution/VenueBooking/index.js +860 -1176
  91. package/dist/solution/VenueBooking/types.d.ts +0 -3
  92. package/dist/solution/VenueBooking/utils/resource.js +0 -1
  93. package/dist/solution/VenueBooking/utils/slotMerge.d.ts +4 -4
  94. package/dist/solution/VenueBooking/utils/slotMerge.js +5 -10
  95. package/dist/solution/index.d.ts +0 -1
  96. package/dist/solution/index.js +1 -2
  97. package/dist/types/index.d.ts +1 -1
  98. package/dist/utils/payment-number.d.ts +9 -0
  99. package/dist/utils/payment-number.js +69 -0
  100. package/lib/core/index.d.ts +2 -0
  101. package/lib/core/index.js +4 -0
  102. package/lib/model/strategy/adapter/promotion/adapter.d.ts +4 -0
  103. package/lib/model/strategy/adapter/promotion/adapter.js +20 -0
  104. package/lib/model/strategy/adapter/promotion/evaluator.d.ts +17 -0
  105. package/lib/model/strategy/adapter/promotion/evaluator.js +235 -0
  106. package/lib/model/strategy/adapter/promotion/examples.d.ts +86 -0
  107. package/lib/model/strategy/adapter/promotion/examples.js +91 -0
  108. package/lib/model/strategy/adapter/promotion/index.d.ts +1 -1
  109. package/lib/model/strategy/adapter/promotion/index.js +2 -0
  110. package/lib/model/strategy/adapter/promotion/type.d.ts +90 -2
  111. package/lib/model/strategy/adapter/promotion/type.js +2 -0
  112. package/lib/modules/BookingContext/utils/buildCacheItemFromOrderLine.js +2 -1
  113. package/lib/modules/BookingContext/utils/buildNormalProductCacheItemFromOrderLine.js +2 -1
  114. package/lib/modules/Discount/index.d.ts +0 -1
  115. package/lib/modules/Discount/index.js +0 -9
  116. package/lib/modules/Discount/types.d.ts +0 -1
  117. package/lib/modules/OpenData/index.d.ts +2 -0
  118. package/lib/modules/OpenData/index.js +6 -1
  119. package/lib/modules/Order/index.d.ts +29 -12
  120. package/lib/modules/Order/index.js +196 -86
  121. package/lib/modules/Order/payment-utils.d.ts +26 -0
  122. package/lib/modules/Order/payment-utils.js +224 -0
  123. package/lib/modules/Order/types.d.ts +33 -10
  124. package/lib/modules/Order/utils/orderCollectionIdentity.js +3 -0
  125. package/lib/modules/Order/utils.d.ts +0 -10
  126. package/lib/modules/Order/utils.js +16 -40
  127. package/lib/modules/Payment/index.d.ts +2 -0
  128. package/lib/modules/Payment/index.js +34 -13
  129. package/lib/modules/Payment/types.d.ts +99 -28
  130. package/lib/modules/Payment/types.js +4 -3
  131. package/lib/modules/Payment/walletpass.d.ts +25 -1
  132. package/lib/modules/Payment/walletpass.js +470 -21
  133. package/lib/modules/Product/types.d.ts +0 -1
  134. package/lib/modules/ProductList/index.js +31 -40
  135. package/lib/modules/Quotation/index.d.ts +1 -1
  136. package/lib/modules/Quotation/index.js +2 -2
  137. package/lib/modules/Rules/index.d.ts +1 -0
  138. package/lib/modules/Rules/index.js +47 -40
  139. package/lib/modules/SalesSummary/index.js +7 -6
  140. package/lib/modules/ScanOrderLogger/index.d.ts +0 -2
  141. package/lib/modules/ScanOrderLogger/index.js +1 -13
  142. package/lib/modules/ScanOrderLogger/providers/feishu.js +6 -15
  143. package/lib/modules/ScanOrderLogger/types.d.ts +0 -1
  144. package/lib/modules/Schedule/index.d.ts +1 -3
  145. package/lib/modules/Schedule/index.js +8 -10
  146. package/lib/modules/Summary/utils.js +1 -21
  147. package/lib/modules/index.d.ts +0 -2
  148. package/lib/modules/index.js +1 -5
  149. package/lib/plugins/window.d.ts +0 -1
  150. package/lib/server/index.d.ts +16 -14
  151. package/lib/server/index.js +675 -83
  152. package/lib/server/modules/order/index.d.ts +54 -4
  153. package/lib/server/modules/order/index.js +679 -66
  154. package/lib/server/modules/order/types.d.ts +11 -3
  155. package/lib/solution/BaseSales/index.d.ts +109 -20
  156. package/lib/solution/BaseSales/index.js +883 -70
  157. package/lib/solution/BaseSales/types.d.ts +52 -0
  158. package/lib/solution/BaseSales/types.js +2 -1
  159. package/lib/solution/BaseSales/utils/cartPromotion.d.ts +3 -1
  160. package/lib/solution/BaseSales/utils/cartPromotion.js +63 -12
  161. package/lib/solution/BaseSales/utils/parseSalesResponse.d.ts +6 -1
  162. package/lib/solution/BookingByStep/index.d.ts +2 -17
  163. package/lib/solution/BookingByStep/index.js +18 -60
  164. package/lib/solution/BookingByStep/types.d.ts +1 -2
  165. package/lib/solution/BookingByStep/types.js +0 -5
  166. package/lib/solution/BookingByStep/utils/capacity.js +1 -20
  167. package/lib/solution/BookingByStep/utils/timeslots.d.ts +1 -3
  168. package/lib/solution/BookingByStep/utils/timeslots.js +11 -19
  169. package/lib/solution/BookingTicket/index.d.ts +8 -4
  170. package/lib/solution/BookingTicket/index.js +64 -19
  171. package/lib/solution/BookingTicket/utils/addProductDecision.js +4 -0
  172. package/lib/solution/BookingTicket/utils/scan/applyGlobalScan.d.ts +8 -0
  173. package/lib/solution/BookingTicket/utils/scan/applyGlobalScan.js +36 -4
  174. package/lib/solution/BookingTicket/utils/scan/handleScan.d.ts +1 -3
  175. package/lib/solution/BookingTicket/utils/scan/handleScan.js +2 -2
  176. package/lib/solution/BookingTicket/utils/weighingProductSku.d.ts +5 -0
  177. package/lib/solution/BookingTicket/utils/weighingProductSku.js +63 -0
  178. package/lib/solution/Sales/index.d.ts +1 -0
  179. package/lib/solution/Sales/index.js +5 -3
  180. package/lib/solution/ScanOrder/index.d.ts +14 -26
  181. package/lib/solution/ScanOrder/index.js +190 -449
  182. package/lib/solution/ScanOrder/types.d.ts +1 -21
  183. package/lib/solution/ScanOrder/utils.d.ts +0 -8
  184. package/lib/solution/ScanOrder/utils.js +0 -31
  185. package/lib/solution/ShopDiscount/index.d.ts +0 -1
  186. package/lib/solution/ShopDiscount/index.js +0 -14
  187. package/lib/solution/VenueBooking/index.d.ts +11 -39
  188. package/lib/solution/VenueBooking/index.js +123 -328
  189. package/lib/solution/VenueBooking/types.d.ts +0 -3
  190. package/lib/solution/VenueBooking/utils/resource.js +0 -1
  191. package/lib/solution/VenueBooking/utils/slotMerge.d.ts +4 -4
  192. package/lib/solution/VenueBooking/utils/slotMerge.js +4 -6
  193. package/lib/solution/index.d.ts +0 -1
  194. package/lib/solution/index.js +1 -3
  195. package/lib/types/index.d.ts +1 -1
  196. package/lib/utils/payment-number.d.ts +9 -0
  197. package/lib/utils/payment-number.js +64 -0
  198. package/package.json +1 -1
  199. package/dist/modules/Holder/index.d.ts +0 -48
  200. package/dist/modules/Holder/index.js +0 -640
  201. package/dist/modules/Holder/types.d.ts +0 -123
  202. package/dist/modules/Holder/types.js +0 -1
  203. package/dist/modules/Holder/utils.d.ts +0 -13
  204. package/dist/modules/Holder/utils.js +0 -34
  205. package/dist/modules/ResourcePlanner/index.d.ts +0 -24
  206. package/dist/modules/ResourcePlanner/index.js +0 -181
  207. package/dist/modules/ResourcePlanner/planner.d.ts +0 -14
  208. package/dist/modules/ResourcePlanner/planner.js +0 -1069
  209. package/dist/modules/ResourcePlanner/types.d.ts +0 -227
  210. package/dist/modules/ResourcePlanner/types.js +0 -1
  211. package/dist/solution/UnifiedBookingSales/index.d.ts +0 -183
  212. package/dist/solution/UnifiedBookingSales/index.js +0 -1871
  213. package/dist/solution/UnifiedBookingSales/types.d.ts +0 -143
  214. package/dist/solution/UnifiedBookingSales/types.js +0 -11
  215. package/lib/modules/Holder/index.d.ts +0 -48
  216. package/lib/modules/Holder/index.js +0 -402
  217. package/lib/modules/Holder/types.d.ts +0 -123
  218. package/lib/modules/Holder/types.js +0 -17
  219. package/lib/modules/Holder/utils.d.ts +0 -13
  220. package/lib/modules/Holder/utils.js +0 -71
  221. package/lib/modules/ResourcePlanner/index.d.ts +0 -24
  222. package/lib/modules/ResourcePlanner/index.js +0 -148
  223. package/lib/modules/ResourcePlanner/planner.d.ts +0 -14
  224. package/lib/modules/ResourcePlanner/planner.js +0 -933
  225. package/lib/modules/ResourcePlanner/types.d.ts +0 -227
  226. package/lib/modules/ResourcePlanner/types.js +0 -17
  227. package/lib/solution/UnifiedBookingSales/index.d.ts +0 -183
  228. package/lib/solution/UnifiedBookingSales/index.js +0 -1076
  229. package/lib/solution/UnifiedBookingSales/types.d.ts +0 -143
  230. package/lib/solution/UnifiedBookingSales/types.js +0 -33
@@ -3,6 +3,7 @@ import { OrderModule, ProductList, QuotationModule, SalesSummaryModule, ScanOrde
3
3
  import type { ScanOrderLogInput as BaseSalesLogInput, ScanOrderLoggerProviderConfig as BaseSalesLoggerProviderConfig, ScanOrderLoggerProviderType as BaseSalesLoggerProviderType } from '../../modules/ScanOrderLogger/types';
4
4
  import type { QuantityCheckResult, QuantityLimitResult } from '../../model/strategy/adapter/itemRule';
5
5
  import type { QuotationCustomerScopeInfo } from '../../modules/Quotation/types';
6
+ import type { PaymentMethod } from '../../modules/Payment/types';
6
7
  /**
7
8
  * BaseSales 流程 hook 后缀。
8
9
  * 完整事件名应由当前模块名动态拼接,避免多个实例共享固定事件 key。
@@ -16,11 +17,62 @@ export declare const BaseSalesHookNames: {
16
17
  readonly onPaymentSyncStart: "onPaymentSyncStart";
17
18
  readonly onPaymentSyncEnd: "onPaymentSyncEnd";
18
19
  readonly onDepositPaymentSyncEnd: "onDepositPaymentSyncEnd";
20
+ readonly onWalletAssetsStateChanged: "onWalletAssetsStateChanged";
19
21
  };
20
22
  export type BaseSalesHookName = typeof BaseSalesHookNames[keyof typeof BaseSalesHookNames];
21
23
  export declare function createBaseSalesHook(moduleName: string, hookName: BaseSalesHookName): string;
22
24
  export type BaseSalesStatus = 'idle' | 'initializing' | 'ready' | 'error';
23
25
  export type BaseSalesPaymentStatus = 'paid' | 'partially_paid' | 'unpaid' | 'payment_processing' | string;
26
+ export interface BaseSalesCashPaymentConfig {
27
+ available: boolean;
28
+ paymentMethod?: PaymentMethod;
29
+ amountDue: number;
30
+ recommendedAmounts: number[];
31
+ }
32
+ export interface BaseSalesPayCashParams {
33
+ /** 实际计入订单的现金支付金额(部分支付时小于待付金额)。 */
34
+ amount: number;
35
+ /** 顾客实际交付现金;可大于 amount。 */
36
+ actualPaidAmount?: number;
37
+ changeAmount?: number;
38
+ roundingAmount?: number;
39
+ }
40
+ export interface BaseSalesPayCashResult {
41
+ payment: Record<string, any>;
42
+ payments: Record<string, any>[];
43
+ syncResult: Record<string, any>;
44
+ isOrderFullyPaid: boolean;
45
+ }
46
+ export interface BaseSalesCommitPaymentMethodParams {
47
+ /** 支付方式 id;与 paymentMethodCode 至少传一个。 */
48
+ paymentMethodId?: number | string;
49
+ /** 支付方式 code,大小写不敏感。 */
50
+ paymentMethodCode?: string;
51
+ /** 本次计入订单的支付金额。 */
52
+ amount: number;
53
+ /** 支付设备返回的原始金额;缺省时与 amount 相同。 */
54
+ originAmount?: number;
55
+ /** 支付设备返回的实际手续费配置。 */
56
+ serviceCharge?: {
57
+ amount?: string | number;
58
+ percentage?: string | number;
59
+ } | null;
60
+ /** 支付设备返回的唯一流水号等扩展信息。 */
61
+ metadata?: Record<string, any>;
62
+ /** 少数支付方式需要透传的额外 payment 字段。 */
63
+ paymentData?: Record<string, any>;
64
+ }
65
+ export interface BaseSalesCommitPaymentMethodResult {
66
+ payment: Record<string, any>;
67
+ payments: Record<string, any>[];
68
+ syncResult: Record<string, any>;
69
+ isOrderFullyPaid: boolean;
70
+ }
71
+ export interface BaseSalesConfirmWalletPaymentResult<T = Record<string, any>> {
72
+ submitResult: T;
73
+ payments: Record<string, any>[];
74
+ isOrderFullyPaid: boolean;
75
+ }
24
76
  export interface BaseSalesEntryContext {
25
77
  biz: string;
26
78
  mode: 'scan' | 'append';
@@ -10,7 +10,8 @@ export var BaseSalesHookNames = {
10
10
  onCartValidationChanged: 'onCartValidationChanged',
11
11
  onPaymentSyncStart: 'onPaymentSyncStart',
12
12
  onPaymentSyncEnd: 'onPaymentSyncEnd',
13
- onDepositPaymentSyncEnd: 'onDepositPaymentSyncEnd'
13
+ onDepositPaymentSyncEnd: 'onDepositPaymentSyncEnd',
14
+ onWalletAssetsStateChanged: 'onWalletAssetsStateChanged'
14
15
  };
15
16
  export function createBaseSalesHook(moduleName, hookName) {
16
17
  return "".concat(moduleName, ":").concat(hookName);
@@ -78,6 +78,7 @@ export interface CartPromotionEvaluator {
78
78
  }>;
79
79
  hasApplicableStrategy: boolean;
80
80
  }>;
81
+ getStrategyConfigs?: () => unknown[];
81
82
  }
82
83
  /** 单个赠品减量项 */
83
84
  export interface GiftReduceItem {
@@ -267,7 +268,8 @@ export declare function appendPromotionTags<T extends Record<string, any>>(produ
267
268
  * 处理购物车的促销计算与赠品差异化。
268
269
  *
269
270
  * 流程:
270
- * 1. 分离 main / gift / edit-product 三类(带 `booking_id` 的编辑态商品不参与促销)
271
+ * 1. 分离 main / gift / edit-product 三类(普通促销下带 `booking_id` 的编辑态商品不参与;
272
+ * 配置 ITEM_REWARD 时,编辑态商品也参与商品奖励重算)
271
273
  * 2. 转 PromotionProduct 喂评估器 → 拿到 `evaluateCartWithPricing` 与 `getProductsApplicableStrategies`
272
274
  * 3. 把 PricedProduct 映射回 OrderProduct 形态:
273
275
  * - 参与促销的,写 `metadata._promotion` + 调整 `selling_price` / `main_product_selling_price`
@@ -1,17 +1,17 @@
1
1
  var _excluded = ["_promotionTags"];
2
2
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
3
3
  function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
4
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
7
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
8
- function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
9
4
  function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
10
5
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
11
6
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
12
7
  function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
13
8
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
14
9
  function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
10
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
11
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
12
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
13
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
14
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
15
15
  function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
16
16
  function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
17
17
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
@@ -116,24 +116,50 @@ export function getOrderProductOriginalPriceForPromotion(product) {
116
116
  }
117
117
  return getOrderProductBasePrice(product);
118
118
  }
119
+ var X_ITEMS_FOR_Y_PRICE = 'X_ITEMS_FOR_Y_PRICE';
120
+ var BUY_X_GET_Y_FREE = 'BUY_X_GET_Y_FREE';
121
+ var ITEM_REWARD = 'ITEM_REWARD';
122
+ function isItemRewardPromotionDiscountItem(item) {
123
+ var _item$metadata, _item$metadata2;
124
+ return (item === null || item === void 0 ? void 0 : item.type) === 'product' && (item === null || item === void 0 || (_item$metadata = item.metadata) === null || _item$metadata === void 0 ? void 0 : _item$metadata.source) === 'promotion' && (item === null || item === void 0 || (_item$metadata2 = item.metadata) === null || _item$metadata2 === void 0 ? void 0 : _item$metadata2.actionType) === ITEM_REWARD;
125
+ }
126
+ function isManagedPromotionDiscountItem(item) {
127
+ if ((item === null || item === void 0 ? void 0 : item.type) === 'promotion') return true;
128
+ return isItemRewardPromotionDiscountItem(item);
129
+ }
130
+
131
+ /**
132
+ * 判断商品行在本轮评估前是否已享受促销。
133
+ *
134
+ * `_promotion` 仅存在于当前运行时;订单保存后会被裁剪,因此编辑态需通过
135
+ * ITEM_REWARD 写入的受管商品折扣恢复上一轮状态。
136
+ */
137
+ function wasInPromotionBeforeEvaluation(item) {
138
+ var _item$metadata3;
139
+ if ((item === null || item === void 0 || (_item$metadata3 = item.metadata) === null || _item$metadata3 === void 0 || (_item$metadata3 = _item$metadata3._promotion) === null || _item$metadata3 === void 0 ? void 0 : _item$metadata3.inPromotion) === true) return true;
140
+ return Array.isArray(item === null || item === void 0 ? void 0 : item.discount_list) && item.discount_list.some(isItemRewardPromotionDiscountItem);
141
+ }
119
142
 
120
143
  /**
121
- * 写入/清除促销 discount_list(type=promotion)。
144
+ * 写入/清除促销 discount_list
122
145
  *
123
146
  * applyDiscount → applyProductDiscountPrices 会从 source_product_price 减去 discount_list 合计
124
147
  * 重算 main_product_selling_price;保留券前 source 时必须同步写入促销差额,否则会还原成原价。
125
148
  *
149
+ * ITEM_REWARD 使用 type=product,复用商品级折扣排他规则,避免客户折扣继续叠加到奖励商品行。
150
+ *
126
151
  * @example
127
152
  * updatePromotionDiscountList(line, { title: '2 items for $10', amount: '17.00', original_amount: '22.00', fixed_amount: '17.00' });
128
153
  */
129
- function updatePromotionDiscountList(item, promotionDiscount) {
154
+ function updatePromotionDiscountList(item, promotionDiscount, options) {
130
155
  var discountList = Array.isArray(item.discount_list) ? _toConsumableArray(item.discount_list) : [];
131
156
  discountList = discountList.filter(function (d) {
132
- return (d === null || d === void 0 ? void 0 : d.type) !== 'promotion';
157
+ return !isManagedPromotionDiscountItem(d);
133
158
  });
134
159
  if (promotionDiscount) {
135
- discountList.push({
136
- type: 'promotion',
160
+ var discountType = (options === null || options === void 0 ? void 0 : options.discountType) || 'promotion';
161
+ discountList.push(_objectSpread({
162
+ type: discountType,
137
163
  amount: promotionDiscount.amount,
138
164
  discount: {
139
165
  original_amount: promotionDiscount.original_amount,
@@ -141,7 +167,12 @@ function updatePromotionDiscountList(item, promotionDiscount) {
141
167
  title: promotionDiscount.title,
142
168
  resource_id: ''
143
169
  }
144
- });
170
+ }, discountType === 'product' ? {
171
+ metadata: {
172
+ source: 'promotion',
173
+ actionType: (options === null || options === void 0 ? void 0 : options.actionType) || ITEM_REWARD
174
+ }
175
+ } : {}));
145
176
  }
146
177
  if (discountList.length > 0) {
147
178
  item.discount_list = discountList;
@@ -149,11 +180,19 @@ function updatePromotionDiscountList(item, promotionDiscount) {
149
180
  delete item.discount_list;
150
181
  }
151
182
  }
152
- var X_ITEMS_FOR_Y_PRICE = 'X_ITEMS_FOR_Y_PRICE';
153
- var BUY_X_GET_Y_FREE = 'BUY_X_GET_Y_FREE';
183
+ function evaluatorHasActionType(evaluator, actionType) {
184
+ var _evaluator$getStrateg;
185
+ var configs = evaluator === null || evaluator === void 0 || (_evaluator$getStrateg = evaluator.getStrategyConfigs) === null || _evaluator$getStrateg === void 0 ? void 0 : _evaluator$getStrateg.call(evaluator);
186
+ if (!Array.isArray(configs)) return false;
187
+ return configs.some(function (config) {
188
+ return ((config === null || config === void 0 ? void 0 : config.actions) || []).some(function (action) {
189
+ return (action === null || action === void 0 ? void 0 : action.type) === actionType;
190
+ });
191
+ });
192
+ }
154
193
 
155
194
  /**
156
- * 将促销单价写入 OrderProduct(含 metadata 三字段 + promotion discount_list)。
195
+ * 将促销单价写入 OrderProduct(含 metadata 三字段 + 行内折扣)。
157
196
  *
158
197
  * @example
159
198
  * applyPromoUnitPriceToLine(newItem, { promoUnitPrice: '5.00', originalBasePrice: 1, strategyTitle: '2 for 10' });
@@ -184,6 +223,9 @@ function applyPromoUnitPriceToLine(item, input) {
184
223
  amount: discountAmount,
185
224
  original_amount: catalogSource,
186
225
  fixed_amount: discountAmount
226
+ }, {
227
+ actionType: input.actionType,
228
+ discountType: input.actionType === ITEM_REWARD ? 'product' : 'promotion'
187
229
  });
188
230
  } else {
189
231
  updatePromotionDiscountList(item, null);
@@ -471,11 +513,11 @@ function getProductBundleForEvaluator(product) {
471
513
  * // => 单行 num=4,清除 _promotion 后重新评估
472
514
  */
473
515
  export function buildConsolidateKeyForPromotion(item) {
474
- var _item$booking_uid, _item$metadata, _item$order_detail_id, _item$product_variant3;
516
+ var _item$booking_uid, _item$metadata4, _item$order_detail_id, _item$product_variant3;
475
517
  var fingerprint = buildProductLineFingerprint(getProductSkuOptions(item), item.product_bundle);
476
518
  var noteSignature = getProductLineNoteSignature(item);
477
519
  var lineMergeBoundary = getPromotionLineMergeBoundary(item);
478
- var bookingUid = (_item$booking_uid = item === null || item === void 0 ? void 0 : item.booking_uid) !== null && _item$booking_uid !== void 0 ? _item$booking_uid : item === null || item === void 0 || (_item$metadata = item.metadata) === null || _item$metadata === void 0 ? void 0 : _item$metadata.booking_uid;
520
+ var bookingUid = (_item$booking_uid = item === null || item === void 0 ? void 0 : item.booking_uid) !== null && _item$booking_uid !== void 0 ? _item$booking_uid : item === null || item === void 0 || (_item$metadata4 = item.metadata) === null || _item$metadata4 === void 0 ? void 0 : _item$metadata4.booking_uid;
479
521
  var orderDetailId = (_item$order_detail_id = item === null || item === void 0 ? void 0 : item.order_detail_id) !== null && _item$order_detail_id !== void 0 ? _item$order_detail_id : item === null || item === void 0 ? void 0 : item.orderDetailId;
480
522
  if (orderDetailId !== undefined && orderDetailId !== null && orderDetailId !== '') {
481
523
  var _item$product_variant;
@@ -496,12 +538,11 @@ function consolidateMainProductsForPromotion(entries) {
496
538
  _step5;
497
539
  try {
498
540
  for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
499
- var _item$metadata2;
500
541
  var _step5$value = _step5.value,
501
542
  item = _step5$value.item,
502
543
  originalListIndex = _step5$value.originalListIndex;
503
544
  var key = buildConsolidateKeyForPromotion(item);
504
- var wasInPromotion = (item === null || item === void 0 || (_item$metadata2 = item.metadata) === null || _item$metadata2 === void 0 || (_item$metadata2 = _item$metadata2._promotion) === null || _item$metadata2 === void 0 ? void 0 : _item$metadata2.inPromotion) === true;
545
+ var wasInPromotion = wasInPromotionBeforeEvaluation(item);
505
546
  var existing = groups.get(key);
506
547
  if (!existing) {
507
548
  var mergedItem = cloneDeep(item);
@@ -598,6 +639,9 @@ function splitXItemsPromoLinesByGroup(lines, strategyActionMap) {
598
639
  function generateNumericId() {
599
640
  return Math.floor(Math.random() * 1000000000) + Date.now();
600
641
  }
642
+ function isBookingEditProductLine(product) {
643
+ return (product === null || product === void 0 ? void 0 : product.booking_id) !== undefined && (product === null || product === void 0 ? void 0 : product.booking_id) !== null && product.booking_id !== 0 && product.booking_id !== '0';
644
+ }
601
645
 
602
646
  /**
603
647
  * 把 OrderProduct 转成 evaluator 的 PromotionProduct(仅评估期使用)。
@@ -618,6 +662,7 @@ function convertToPromotionProduct(product, index) {
618
662
  price: getOrderProductOriginalPriceForPromotion(product),
619
663
  quantity: Number((_product$num = product === null || product === void 0 ? void 0 : product.num) !== null && _product$num !== void 0 ? _product$num : 1) || 1,
620
664
  bundle: getProductBundleForEvaluator(product),
665
+ _promotionOnlyForItemReward: isBookingEditProductLine(product),
621
666
  _originalItem: originalItem,
622
667
  _originalId: getOrderProductUid(product),
623
668
  _originalIndex: index
@@ -825,6 +870,9 @@ export function resolveStrategyRequiredQuantity(matched) {
825
870
  if (matched.actionType === 'BUY_X_GET_Y_FREE') {
826
871
  return Number(detail.buyQuantity) || 1;
827
872
  }
873
+ if (matched.actionType === 'ITEM_REWARD') {
874
+ return Number(detail.triggerQuantity) || 1;
875
+ }
828
876
  return 1;
829
877
  }
830
878
 
@@ -984,7 +1032,8 @@ export function appendPromotionTags(products, evaluator) {
984
1032
  * 处理购物车的促销计算与赠品差异化。
985
1033
  *
986
1034
  * 流程:
987
- * 1. 分离 main / gift / edit-product 三类(带 `booking_id` 的编辑态商品不参与促销)
1035
+ * 1. 分离 main / gift / edit-product 三类(普通促销下带 `booking_id` 的编辑态商品不参与;
1036
+ * 配置 ITEM_REWARD 时,编辑态商品也参与商品奖励重算)
988
1037
  * 2. 转 PromotionProduct 喂评估器 → 拿到 `evaluateCartWithPricing` 与 `getProductsApplicableStrategies`
989
1038
  * 3. 把 PricedProduct 映射回 OrderProduct 形态:
990
1039
  * - 参与促销的,写 `metadata._promotion` + 调整 `selling_price` / `main_product_selling_price`
@@ -1014,6 +1063,7 @@ export function processCartPromotion(list, evaluator, options) {
1014
1063
  if (!list || list.length === 0 || !evaluator) return empty;
1015
1064
 
1016
1065
  // 0. 分类
1066
+ var shouldIncludeEditProductsForItemReward = evaluatorHasActionType(evaluator, ITEM_REWARD);
1017
1067
  var mainProductsWithIndex = [];
1018
1068
  var existingGiftsWithIndex = [];
1019
1069
  var editProductsWithIndex = [];
@@ -1030,11 +1080,18 @@ export function processCartPromotion(list, evaluator, options) {
1030
1080
  item: item,
1031
1081
  originalListIndex: i
1032
1082
  });
1033
- } else if ((item === null || item === void 0 ? void 0 : item.booking_id) !== undefined && (item === null || item === void 0 ? void 0 : item.booking_id) !== null && item.booking_id !== 0 && item.booking_id !== '0') {
1034
- editProductsWithIndex.push({
1035
- item: item,
1036
- originalListIndex: i
1037
- });
1083
+ } else if (isBookingEditProductLine(item)) {
1084
+ if (shouldIncludeEditProductsForItemReward) {
1085
+ mainProductsWithIndex.push({
1086
+ item: item,
1087
+ originalListIndex: i
1088
+ });
1089
+ } else {
1090
+ editProductsWithIndex.push({
1091
+ item: item,
1092
+ originalListIndex: i
1093
+ });
1094
+ }
1038
1095
  } else {
1039
1096
  mainProductsWithIndex.push({
1040
1097
  item: item,
@@ -1089,16 +1146,17 @@ export function processCartPromotion(list, evaluator, options) {
1089
1146
  var promotionProducts = [];
1090
1147
  var originalItemMap = new Map();
1091
1148
  var productsForStrategies = consolidatedMainProductsWithIndex.map(function (_ref16, i) {
1092
- var _item$product_id, _item$product_variant5, _item$metadata3, _item$num;
1149
+ var _item$product_id, _item$product_variant5, _item$metadata5, _item$num;
1093
1150
  var item = _ref16.item;
1094
1151
  return {
1095
1152
  id: i,
1096
1153
  product_id: Number((_item$product_id = item === null || item === void 0 ? void 0 : item.product_id) !== null && _item$product_id !== void 0 ? _item$product_id : 0) || 0,
1097
1154
  product_variant_id: Number((_item$product_variant5 = item === null || item === void 0 ? void 0 : item.product_variant_id) !== null && _item$product_variant5 !== void 0 ? _item$product_variant5 : 0) || 0,
1098
- name: (item === null || item === void 0 || (_item$metadata3 = item.metadata) === null || _item$metadata3 === void 0 ? void 0 : _item$metadata3.product_name) || (item === null || item === void 0 ? void 0 : item.title) || '',
1155
+ name: (item === null || item === void 0 || (_item$metadata5 = item.metadata) === null || _item$metadata5 === void 0 ? void 0 : _item$metadata5.product_name) || (item === null || item === void 0 ? void 0 : item.title) || '',
1099
1156
  price: getOrderProductBasePrice(item),
1100
1157
  quantity: Number((_item$num = item === null || item === void 0 ? void 0 : item.num) !== null && _item$num !== void 0 ? _item$num : 1) || 1,
1101
- bundle: getProductBundleForEvaluator(item)
1158
+ bundle: getProductBundleForEvaluator(item),
1159
+ _promotionOnlyForItemReward: isBookingEditProductLine(item)
1102
1160
  };
1103
1161
  });
1104
1162
  for (var _i = 0; _i < consolidatedMainProductsWithIndex.length; _i++) {
@@ -1206,7 +1264,7 @@ export function processCartPromotion(list, evaluator, options) {
1206
1264
  _step20;
1207
1265
  try {
1208
1266
  for (_iterator20.s(); !(_step20 = _iterator20.n()).done;) {
1209
- var _priced$originalId2, _priced$product_id, _originalItem$product, _metadata$_promotion2;
1267
+ var _priced$originalId2, _priced$product_id, _originalItem$product;
1210
1268
  var _priced = _step20.value;
1211
1269
  var rawSourceId = (_priced$originalId2 = _priced.originalId) !== null && _priced$originalId2 !== void 0 ? _priced$originalId2 : _priced.id;
1212
1270
  var _sourceId = Number(rawSourceId);
@@ -1225,7 +1283,7 @@ export function processCartPromotion(list, evaluator, options) {
1225
1283
  newItem._sourceCartNum = sourceCartNum;
1226
1284
 
1227
1285
  // 清掉历史促销字段
1228
- var wasInPromotion = ((_metadata$_promotion2 = metadata._promotion) === null || _metadata$_promotion2 === void 0 ? void 0 : _metadata$_promotion2.inPromotion) === true || originalItem._wasInPromotionBeforeConsolidate === true;
1286
+ var wasInPromotion = wasInPromotionBeforeEvaluation(originalItem) || originalItem._wasInPromotionBeforeConsolidate === true;
1229
1287
  delete metadata._promotion;
1230
1288
  if (Array.isArray(newItem.product_bundle)) {
1231
1289
  var _iterator23 = _createForOfIteratorHelper(newItem.product_bundle),
@@ -1246,12 +1304,13 @@ export function processCartPromotion(list, evaluator, options) {
1246
1304
  var priceUnchangedPromo = _priced.inPromotion && Number(_priced.finalPrice) === Number(originalBasePrice);
1247
1305
  if (shouldModifyPrice) {
1248
1306
  if (_priced.inPromotion && !priceUnchangedPromo) {
1249
- var _priced$strategyMetad;
1307
+ var _priced$strategyMetad, _strategyActionMap$ge;
1250
1308
  var promoUnitPrice = new Decimal(_priced.finalPrice).toDecimalPlaces(2).toFixed(2);
1251
1309
  applyPromoUnitPriceToLine(newItem, {
1252
1310
  promoUnitPrice: promoUnitPrice,
1253
1311
  originalBasePrice: originalBasePrice,
1254
- strategyTitle: (_priced$strategyMetad = _priced.strategyMetadata) === null || _priced$strategyMetad === void 0 ? void 0 : _priced$strategyMetad.name
1312
+ strategyTitle: (_priced$strategyMetad = _priced.strategyMetadata) === null || _priced$strategyMetad === void 0 ? void 0 : _priced$strategyMetad.name,
1313
+ actionType: _priced.strategyId ? (_strategyActionMap$ge = strategyActionMap.get(_priced.strategyId)) === null || _strategyActionMap$ge === void 0 ? void 0 : _strategyActionMap$ge.actionType : undefined
1255
1314
  });
1256
1315
  } else {
1257
1316
  // 撤销上一轮促销:还原 selling_price 到 main_product_original_price 派生值
@@ -82,8 +82,13 @@ export interface ISalesBooking {
82
82
  metadata?: Record<string, any> | null;
83
83
  [key: string]: any;
84
84
  }
85
+ export interface ISalesPaymentMetadata extends Record<string, any> {
86
+ /** 刷卡机设备快照;OS 不解析内部字段 */
87
+ card_reader_snapshot?: Record<string, unknown>;
88
+ }
85
89
  export interface ISalesPayment {
86
90
  order_payment_id?: number | null;
91
+ payment_number?: string;
87
92
  custom_payment_id?: number;
88
93
  code?: string;
89
94
  name?: string;
@@ -95,7 +100,7 @@ export interface ISalesPayment {
95
100
  status?: string;
96
101
  payment_time?: string | null;
97
102
  service_charge?: Record<string, any> | null;
98
- metadata?: Record<string, any> | null;
103
+ metadata?: ISalesPaymentMetadata | null;
99
104
  [key: string]: any;
100
105
  }
101
106
  export interface ISalesSurcharge {
@@ -10,7 +10,6 @@ import { ITime } from '../../modules/Date/types';
10
10
  import dayjs from 'dayjs';
11
11
  import { LoadScheduleAvailableDateParams } from '../../modules/Schedule/types';
12
12
  import { IHolder, IFetchHolderAccountsParams } from '../../modules/AccountList/types';
13
- import { IAppendFormRecordParams } from '../../modules/Holder/types';
14
13
  export declare class BookingByStepImpl extends BaseModule implements Module {
15
14
  protected defaultName: string;
16
15
  protected defaultVersion: string;
@@ -127,20 +126,6 @@ export declare class BookingByStepImpl extends BaseModule implements Module {
127
126
  * @param params
128
127
  */
129
128
  fetchHolderAccountsAsync(params: IFetchHolderAccountsParams): Promise<void>;
130
- /**
131
- * 获取 holder 表单 map
132
- */
133
- getHolderFormMap(): import("../../modules").HolderFormMap;
134
- /**
135
- * 登录后或外部触发时,按当前 holderMap 批量刷新所有表单的 records
136
- */
137
- refreshAllHolderFormRecords(params?: {
138
- customer_id?: number;
139
- }): Promise<import("../../modules").HolderFormMap>;
140
- /**
141
- * 添加表单记录
142
- */
143
- appendFormRecord(params: IAppendFormRecordParams): import("../../modules").IFormRecord;
144
129
  setDateRange(dateRange: ITime[]): Promise<void>;
145
130
  clearDateRange(): void;
146
131
  getDateRange(): Promise<ITime[]>;
@@ -317,7 +302,7 @@ export declare class BookingByStepImpl extends BaseModule implements Module {
317
302
  autoSelectAllProductResources(resources_code: string, timeSlots?: TimeSliceItem): {
318
303
  errorList: any[];
319
304
  };
320
- getTimeSlotByAllResources(resources_code: string, split?: number): any[];
305
+ getTimeSlotByAllResources(resources_code: string): any[];
321
306
  getTimeSlotByAllResourcesForDate({ resources_code, startDate, endDate }: {
322
307
  resources_code: string;
323
308
  startDate: string;
@@ -326,7 +311,7 @@ export declare class BookingByStepImpl extends BaseModule implements Module {
326
311
  date: string;
327
312
  status: string;
328
313
  week: string;
329
- weekNum: 0 | 1 | 5 | 2 | 4 | 3 | 6;
314
+ weekNum: 0 | 2 | 1 | 3 | 4 | 5 | 6;
330
315
  }[]>;
331
316
  submitTimeSlot(timeSlots: TimeSliceItem): void;
332
317
  private getScheduleDataByIds;