@pisell/pisellos 3.0.76 → 3.0.78

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 (314) hide show
  1. package/dist/core/index.js +1 -2
  2. package/dist/effects/index.d.ts +3 -5
  3. package/dist/effects/index.js +8 -40
  4. package/dist/modules/Account/index.js +3 -2
  5. package/dist/modules/AccountList/index.d.ts +1 -7
  6. package/dist/modules/AccountList/index.js +14 -81
  7. package/dist/modules/AccountList/types.d.ts +0 -28
  8. package/dist/modules/AccountList/types.js +0 -8
  9. package/dist/modules/BaseModule.d.ts +0 -3
  10. package/dist/modules/BaseModule.js +0 -15
  11. package/dist/modules/Cart/index.d.ts +0 -1
  12. package/dist/modules/Cart/index.js +1 -2
  13. package/dist/modules/Date/types.d.ts +3 -1
  14. package/dist/modules/Discount/index.d.ts +0 -1
  15. package/dist/modules/Discount/index.js +1 -1
  16. package/dist/modules/Guests/index.js +9 -9
  17. package/dist/modules/Order/index.d.ts +1 -25
  18. package/dist/modules/Order/index.js +3 -224
  19. package/dist/modules/Order/types.d.ts +0 -45
  20. package/dist/modules/Order/types.js +0 -8
  21. package/dist/modules/Order/utils.js +1 -1
  22. package/dist/modules/Payment/index.d.ts +9 -184
  23. package/dist/modules/Payment/index.js +109 -2084
  24. package/dist/modules/Payment/types.d.ts +30 -772
  25. package/dist/modules/Payment/types.js +12 -236
  26. package/dist/modules/ProductList/index.d.ts +1 -12
  27. package/dist/modules/ProductList/index.js +6 -29
  28. package/dist/modules/Resource/index.js +1 -1
  29. package/dist/modules/Rules/index.d.ts +4 -3
  30. package/dist/modules/Rules/index.js +121 -78
  31. package/dist/modules/Rules/types.d.ts +6 -1
  32. package/dist/modules/Rules/types.js +8 -0
  33. package/dist/modules/Schedule/index.d.ts +0 -9
  34. package/dist/modules/Schedule/index.js +0 -77
  35. package/dist/modules/index.d.ts +0 -1
  36. package/dist/modules/index.js +0 -1
  37. package/dist/plugins/window.d.ts +0 -1
  38. package/dist/solution/BookingByStep/index.d.ts +17 -0
  39. package/dist/solution/BookingByStep/index.js +525 -190
  40. package/dist/solution/BookingByStep/utils/products.d.ts +0 -6
  41. package/dist/solution/BookingByStep/utils/products.js +0 -10
  42. package/dist/solution/BookingByStep/utils/resources.js +4 -0
  43. package/dist/solution/BuyTickets/index.js +8 -7
  44. package/dist/solution/ShopDiscount/index.d.ts +12 -10
  45. package/dist/solution/ShopDiscount/index.js +64 -110
  46. package/dist/solution/ShopDiscount/types.d.ts +0 -8
  47. package/dist/solution/ShopDiscount/utils.js +1 -0
  48. package/dist/solution/index.d.ts +0 -2
  49. package/dist/solution/index.js +1 -3
  50. package/dist/types/index.d.ts +1 -4
  51. package/lib/core/index.js +1 -1
  52. package/lib/effects/index.d.ts +3 -5
  53. package/lib/effects/index.js +1 -17
  54. package/lib/modules/Account/index.js +3 -2
  55. package/lib/modules/AccountList/index.d.ts +1 -7
  56. package/lib/modules/AccountList/index.js +0 -27
  57. package/lib/modules/AccountList/types.d.ts +0 -28
  58. package/lib/modules/BaseModule.d.ts +0 -3
  59. package/lib/modules/BaseModule.js +0 -9
  60. package/lib/modules/Cart/index.d.ts +0 -1
  61. package/lib/modules/Cart/index.js +2 -5
  62. package/lib/modules/Date/types.d.ts +3 -1
  63. package/lib/modules/Discount/index.d.ts +0 -1
  64. package/lib/modules/Discount/index.js +1 -1
  65. package/lib/modules/Guests/index.js +9 -9
  66. package/lib/modules/Order/index.d.ts +1 -25
  67. package/lib/modules/Order/index.js +1 -186
  68. package/lib/modules/Order/types.d.ts +0 -45
  69. package/lib/modules/Order/utils.js +1 -1
  70. package/lib/modules/Payment/index.d.ts +9 -184
  71. package/lib/modules/Payment/index.js +51 -1084
  72. package/lib/modules/Payment/types.d.ts +30 -772
  73. package/lib/modules/Payment/types.js +6 -79
  74. package/lib/modules/ProductList/index.d.ts +1 -12
  75. package/lib/modules/ProductList/index.js +5 -31
  76. package/lib/modules/Resource/index.js +1 -1
  77. package/lib/modules/Rules/index.d.ts +4 -3
  78. package/lib/modules/Rules/index.js +64 -43
  79. package/lib/modules/Rules/types.d.ts +6 -1
  80. package/lib/modules/Rules/types.js +11 -2
  81. package/lib/modules/Schedule/index.d.ts +0 -9
  82. package/lib/modules/Schedule/index.js +0 -60
  83. package/lib/modules/index.d.ts +0 -1
  84. package/lib/modules/index.js +0 -2
  85. package/lib/plugins/window.d.ts +0 -1
  86. package/lib/solution/BookingByStep/index.d.ts +17 -0
  87. package/lib/solution/BookingByStep/index.js +325 -60
  88. package/lib/solution/BookingByStep/utils/products.d.ts +0 -6
  89. package/lib/solution/BookingByStep/utils/products.js +2 -8
  90. package/lib/solution/BookingByStep/utils/resources.js +4 -1
  91. package/lib/solution/BuyTickets/index.js +8 -7
  92. package/lib/solution/ShopDiscount/index.d.ts +12 -10
  93. package/lib/solution/ShopDiscount/index.js +30 -51
  94. package/lib/solution/ShopDiscount/types.d.ts +0 -8
  95. package/lib/solution/index.d.ts +0 -2
  96. package/lib/solution/index.js +1 -5
  97. package/lib/types/index.d.ts +1 -4
  98. package/package.json +1 -3
  99. package/dist/modules/Customer/constants.d.ts +0 -7
  100. package/dist/modules/Customer/constants.js +0 -12
  101. package/dist/modules/Customer/index.d.ts +0 -122
  102. package/dist/modules/Customer/index.js +0 -696
  103. package/dist/modules/Customer/types.d.ts +0 -146
  104. package/dist/modules/Customer/types.js +0 -41
  105. package/dist/modules/Payment/cash.d.ts +0 -19
  106. package/dist/modules/Payment/cash.js +0 -97
  107. package/dist/modules/Payment/cashRecommendationAlgorithm.d.ts +0 -22
  108. package/dist/modules/Payment/cashRecommendationAlgorithm.js +0 -423
  109. package/dist/modules/Payment/eftpos.d.ts +0 -11
  110. package/dist/modules/Payment/eftpos.js +0 -80
  111. package/dist/modules/Payment/mx51.d.ts +0 -0
  112. package/dist/modules/Payment/mx51.js +0 -0
  113. package/dist/modules/Payment/utils.d.ts +0 -17
  114. package/dist/modules/Payment/utils.js +0 -62
  115. package/dist/modules/Payment/walletpass.d.ts +0 -99
  116. package/dist/modules/Payment/walletpass.js +0 -711
  117. package/dist/plugins/app-types/app/app.d.ts +0 -83
  118. package/dist/plugins/app-types/app/const.d.ts +0 -4
  119. package/dist/plugins/app-types/app/index.d.ts +0 -14
  120. package/dist/plugins/app-types/applicationManager/application.d.ts +0 -50
  121. package/dist/plugins/app-types/applicationManager/index.d.ts +0 -13
  122. package/dist/plugins/app-types/config.d.ts +0 -3
  123. package/dist/plugins/app-types/cookie/index.d.ts +0 -13
  124. package/dist/plugins/app-types/data/index.d.ts +0 -8
  125. package/dist/plugins/app-types/history/config.d.ts +0 -24
  126. package/dist/plugins/app-types/history/index.d.ts +0 -20
  127. package/dist/plugins/app-types/history/type.d.ts +0 -2
  128. package/dist/plugins/app-types/hooks/index.d.ts +0 -12
  129. package/dist/plugins/app-types/hooks/useDelayedValue/index.d.ts +0 -2
  130. package/dist/plugins/app-types/hooks/useDispatch/index.d.ts +0 -2
  131. package/dist/plugins/app-types/hooks/useLowCode/index.d.ts +0 -13
  132. package/dist/plugins/app-types/hooks/useStore/index.d.ts +0 -6
  133. package/dist/plugins/app-types/index.d.ts +0 -6
  134. package/dist/plugins/app-types/indexDB/index.d.ts +0 -178
  135. package/dist/plugins/app-types/locales/en.d.ts +0 -3
  136. package/dist/plugins/app-types/locales/index.d.ts +0 -37
  137. package/dist/plugins/app-types/locales/original.d.ts +0 -3
  138. package/dist/plugins/app-types/locales/type.d.ts +0 -19
  139. package/dist/plugins/app-types/locales/zh-CN.d.ts +0 -3
  140. package/dist/plugins/app-types/locales/zh-HK.d.ts +0 -3
  141. package/dist/plugins/app-types/logger/feishu.d.ts +0 -11
  142. package/dist/plugins/app-types/logger/index.d.ts +0 -122
  143. package/dist/plugins/app-types/menuManager/hooks.d.ts +0 -17
  144. package/dist/plugins/app-types/menuManager/index.d.ts +0 -28
  145. package/dist/plugins/app-types/models/global.d.ts +0 -32
  146. package/dist/plugins/app-types/models/index.d.ts +0 -45
  147. package/dist/plugins/app-types/models/type.d.ts +0 -2
  148. package/dist/plugins/app-types/package.json +0 -15
  149. package/dist/plugins/app-types/plugin/index.d.ts +0 -0
  150. package/dist/plugins/app-types/pubsub/example.d.ts +0 -5
  151. package/dist/plugins/app-types/pubsub/index.d.ts +0 -63
  152. package/dist/plugins/app-types/request/cache.d.ts +0 -46
  153. package/dist/plugins/app-types/request/cancelToken.d.ts +0 -38
  154. package/dist/plugins/app-types/request/config.d.ts +0 -3
  155. package/dist/plugins/app-types/request/constants.d.ts +0 -2
  156. package/dist/plugins/app-types/request/index.d.ts +0 -24
  157. package/dist/plugins/app-types/request/pisell2Request.d.ts +0 -6
  158. package/dist/plugins/app-types/request/type.d.ts +0 -41
  159. package/dist/plugins/app-types/request/utils.d.ts +0 -46
  160. package/dist/plugins/app-types/routes/config.d.ts +0 -7
  161. package/dist/plugins/app-types/routes/index.d.ts +0 -28
  162. package/dist/plugins/app-types/socket/components/SocketMonitorPage.d.ts +0 -6
  163. package/dist/plugins/app-types/socket/components/index.d.ts +0 -2
  164. package/dist/plugins/app-types/socket/constants.d.ts +0 -33
  165. package/dist/plugins/app-types/socket/events.d.ts +0 -31
  166. package/dist/plugins/app-types/socket/heartbeat.d.ts +0 -66
  167. package/dist/plugins/app-types/socket/index.d.ts +0 -61
  168. package/dist/plugins/app-types/socket/monitor.d.ts +0 -169
  169. package/dist/plugins/app-types/socket/reconnect.d.ts +0 -61
  170. package/dist/plugins/app-types/socket/socket.d.ts +0 -129
  171. package/dist/plugins/app-types/socket/types.d.ts +0 -85
  172. package/dist/plugins/app-types/storage/index.d.ts +0 -17
  173. package/dist/plugins/app-types/tasks/index.d.ts +0 -77
  174. package/dist/plugins/app-types/tasks/type.d.ts +0 -62
  175. package/dist/plugins/app-types/tasks/useTasks.d.ts +0 -5
  176. package/dist/plugins/app-types/type.d.ts +0 -2
  177. package/dist/plugins/app-types/variables/VariablesProvider.d.ts +0 -7
  178. package/dist/plugins/app-types/variables/config.d.ts +0 -3
  179. package/dist/plugins/app-types/variables/index.d.ts +0 -6
  180. package/dist/plugins/app-types/variables/type.d.ts +0 -2
  181. package/dist/plugins/app-types/website/index.d.ts +0 -6
  182. package/dist/plugins/app.d.ts +0 -8
  183. package/dist/plugins/app.js +0 -1
  184. package/dist/solution/BookingTicket/index.d.ts +0 -184
  185. package/dist/solution/BookingTicket/index.js +0 -698
  186. package/dist/solution/BookingTicket/types.d.ts +0 -68
  187. package/dist/solution/BookingTicket/types.js +0 -43
  188. package/dist/solution/BookingTicket/utils/scan/cloudSearch.d.ts +0 -22
  189. package/dist/solution/BookingTicket/utils/scan/cloudSearch.js +0 -159
  190. package/dist/solution/BookingTicket/utils/scan/handleScan.d.ts +0 -22
  191. package/dist/solution/BookingTicket/utils/scan/handleScan.js +0 -189
  192. package/dist/solution/BookingTicket/utils/scan/index.d.ts +0 -85
  193. package/dist/solution/BookingTicket/utils/scan/index.js +0 -294
  194. package/dist/solution/BookingTicket/utils/scan/scanCache.d.ts +0 -78
  195. package/dist/solution/BookingTicket/utils/scan/scanCache.js +0 -305
  196. package/dist/solution/Checkout/appointmentDemo.json +0 -1
  197. package/dist/solution/Checkout/index.d.ts +0 -432
  198. package/dist/solution/Checkout/index.js +0 -4452
  199. package/dist/solution/Checkout/types.d.ts +0 -727
  200. package/dist/solution/Checkout/types.js +0 -104
  201. package/dist/solution/Checkout/utils/index.d.ts +0 -121
  202. package/dist/solution/Checkout/utils/index.js +0 -511
  203. package/dist/utils/task.d.ts +0 -40
  204. package/dist/utils/task.js +0 -171
  205. package/dist/utils/watch.d.ts +0 -102
  206. package/dist/utils/watch.js +0 -294
  207. package/lib/modules/Customer/constants.d.ts +0 -7
  208. package/lib/modules/Customer/constants.js +0 -39
  209. package/lib/modules/Customer/index.d.ts +0 -122
  210. package/lib/modules/Customer/index.js +0 -439
  211. package/lib/modules/Customer/types.d.ts +0 -146
  212. package/lib/modules/Customer/types.js +0 -37
  213. package/lib/modules/Payment/cash.d.ts +0 -19
  214. package/lib/modules/Payment/cash.js +0 -64
  215. package/lib/modules/Payment/cashRecommendationAlgorithm.d.ts +0 -22
  216. package/lib/modules/Payment/cashRecommendationAlgorithm.js +0 -342
  217. package/lib/modules/Payment/eftpos.d.ts +0 -11
  218. package/lib/modules/Payment/eftpos.js +0 -51
  219. package/lib/modules/Payment/mx51.d.ts +0 -0
  220. package/lib/modules/Payment/mx51.js +0 -0
  221. package/lib/modules/Payment/utils.d.ts +0 -17
  222. package/lib/modules/Payment/utils.js +0 -67
  223. package/lib/modules/Payment/walletpass.d.ts +0 -99
  224. package/lib/modules/Payment/walletpass.js +0 -484
  225. package/lib/plugins/app-types/app/app.d.ts +0 -83
  226. package/lib/plugins/app-types/app/const.d.ts +0 -4
  227. package/lib/plugins/app-types/app/index.d.ts +0 -14
  228. package/lib/plugins/app-types/applicationManager/application.d.ts +0 -50
  229. package/lib/plugins/app-types/applicationManager/index.d.ts +0 -13
  230. package/lib/plugins/app-types/config.d.ts +0 -3
  231. package/lib/plugins/app-types/cookie/index.d.ts +0 -13
  232. package/lib/plugins/app-types/data/index.d.ts +0 -8
  233. package/lib/plugins/app-types/history/config.d.ts +0 -24
  234. package/lib/plugins/app-types/history/index.d.ts +0 -20
  235. package/lib/plugins/app-types/history/type.d.ts +0 -2
  236. package/lib/plugins/app-types/hooks/index.d.ts +0 -12
  237. package/lib/plugins/app-types/hooks/useDelayedValue/index.d.ts +0 -2
  238. package/lib/plugins/app-types/hooks/useDispatch/index.d.ts +0 -2
  239. package/lib/plugins/app-types/hooks/useLowCode/index.d.ts +0 -13
  240. package/lib/plugins/app-types/hooks/useStore/index.d.ts +0 -6
  241. package/lib/plugins/app-types/index.d.ts +0 -6
  242. package/lib/plugins/app-types/indexDB/index.d.ts +0 -178
  243. package/lib/plugins/app-types/locales/en.d.ts +0 -3
  244. package/lib/plugins/app-types/locales/index.d.ts +0 -37
  245. package/lib/plugins/app-types/locales/original.d.ts +0 -3
  246. package/lib/plugins/app-types/locales/type.d.ts +0 -19
  247. package/lib/plugins/app-types/locales/zh-CN.d.ts +0 -3
  248. package/lib/plugins/app-types/locales/zh-HK.d.ts +0 -3
  249. package/lib/plugins/app-types/logger/feishu.d.ts +0 -11
  250. package/lib/plugins/app-types/logger/index.d.ts +0 -122
  251. package/lib/plugins/app-types/menuManager/hooks.d.ts +0 -17
  252. package/lib/plugins/app-types/menuManager/index.d.ts +0 -28
  253. package/lib/plugins/app-types/models/global.d.ts +0 -32
  254. package/lib/plugins/app-types/models/index.d.ts +0 -45
  255. package/lib/plugins/app-types/models/type.d.ts +0 -2
  256. package/lib/plugins/app-types/package.json +0 -15
  257. package/lib/plugins/app-types/plugin/index.d.ts +0 -0
  258. package/lib/plugins/app-types/pubsub/example.d.ts +0 -5
  259. package/lib/plugins/app-types/pubsub/index.d.ts +0 -63
  260. package/lib/plugins/app-types/request/cache.d.ts +0 -46
  261. package/lib/plugins/app-types/request/cancelToken.d.ts +0 -38
  262. package/lib/plugins/app-types/request/config.d.ts +0 -3
  263. package/lib/plugins/app-types/request/constants.d.ts +0 -2
  264. package/lib/plugins/app-types/request/index.d.ts +0 -24
  265. package/lib/plugins/app-types/request/pisell2Request.d.ts +0 -6
  266. package/lib/plugins/app-types/request/type.d.ts +0 -41
  267. package/lib/plugins/app-types/request/utils.d.ts +0 -46
  268. package/lib/plugins/app-types/routes/config.d.ts +0 -7
  269. package/lib/plugins/app-types/routes/index.d.ts +0 -28
  270. package/lib/plugins/app-types/socket/components/SocketMonitorPage.d.ts +0 -6
  271. package/lib/plugins/app-types/socket/components/index.d.ts +0 -2
  272. package/lib/plugins/app-types/socket/constants.d.ts +0 -33
  273. package/lib/plugins/app-types/socket/events.d.ts +0 -31
  274. package/lib/plugins/app-types/socket/heartbeat.d.ts +0 -66
  275. package/lib/plugins/app-types/socket/index.d.ts +0 -61
  276. package/lib/plugins/app-types/socket/monitor.d.ts +0 -169
  277. package/lib/plugins/app-types/socket/reconnect.d.ts +0 -61
  278. package/lib/plugins/app-types/socket/socket.d.ts +0 -129
  279. package/lib/plugins/app-types/socket/types.d.ts +0 -85
  280. package/lib/plugins/app-types/storage/index.d.ts +0 -17
  281. package/lib/plugins/app-types/tasks/index.d.ts +0 -77
  282. package/lib/plugins/app-types/tasks/type.d.ts +0 -62
  283. package/lib/plugins/app-types/tasks/useTasks.d.ts +0 -5
  284. package/lib/plugins/app-types/type.d.ts +0 -2
  285. package/lib/plugins/app-types/variables/VariablesProvider.d.ts +0 -7
  286. package/lib/plugins/app-types/variables/config.d.ts +0 -3
  287. package/lib/plugins/app-types/variables/index.d.ts +0 -6
  288. package/lib/plugins/app-types/variables/type.d.ts +0 -2
  289. package/lib/plugins/app-types/website/index.d.ts +0 -6
  290. package/lib/plugins/app.d.ts +0 -8
  291. package/lib/plugins/app.js +0 -17
  292. package/lib/solution/BookingTicket/index.d.ts +0 -184
  293. package/lib/solution/BookingTicket/index.js +0 -426
  294. package/lib/solution/BookingTicket/types.d.ts +0 -68
  295. package/lib/solution/BookingTicket/types.js +0 -72
  296. package/lib/solution/BookingTicket/utils/scan/cloudSearch.d.ts +0 -22
  297. package/lib/solution/BookingTicket/utils/scan/cloudSearch.js +0 -117
  298. package/lib/solution/BookingTicket/utils/scan/handleScan.d.ts +0 -22
  299. package/lib/solution/BookingTicket/utils/scan/handleScan.js +0 -132
  300. package/lib/solution/BookingTicket/utils/scan/index.d.ts +0 -85
  301. package/lib/solution/BookingTicket/utils/scan/index.js +0 -216
  302. package/lib/solution/BookingTicket/utils/scan/scanCache.d.ts +0 -78
  303. package/lib/solution/BookingTicket/utils/scan/scanCache.js +0 -231
  304. package/lib/solution/Checkout/appointmentDemo.json +0 -1
  305. package/lib/solution/Checkout/index.d.ts +0 -432
  306. package/lib/solution/Checkout/index.js +0 -2776
  307. package/lib/solution/Checkout/types.d.ts +0 -727
  308. package/lib/solution/Checkout/types.js +0 -63
  309. package/lib/solution/Checkout/utils/index.d.ts +0 -121
  310. package/lib/solution/Checkout/utils/index.js +0 -362
  311. package/lib/utils/task.d.ts +0 -40
  312. package/lib/utils/task.js +0 -109
  313. package/lib/utils/watch.d.ts +0 -102
  314. package/lib/utils/watch.js +0 -217
@@ -1,257 +1,33 @@
1
- /**
2
- * 支付相关类型定义
3
- */
4
-
5
- /**
6
- * 支付方式枚举
7
- */
8
- export var PaymentMethodType = /*#__PURE__*/function (PaymentMethodType) {
9
- PaymentMethodType["Cash"] = "CASHMANUAL";
10
- PaymentMethodType["Eftpos"] = "EFTPOS";
11
- PaymentMethodType["Wallet"] = "WALLET";
12
- return PaymentMethodType;
13
- }({});
14
-
15
- /**
16
- * 支付状态枚举
17
- */
18
- export var PaymentStatus = /*#__PURE__*/function (PaymentStatus) {
19
- PaymentStatus["Processing"] = "payment_processing";
20
- PaymentStatus["Sync"] = "sync";
21
- PaymentStatus["PartiallyPaid"] = "partially_paid";
22
- PaymentStatus["Finished"] = "finish";
23
- return PaymentStatus;
24
- }({});
25
-
26
- /**
27
- * 任务状态枚举
28
- */
29
- export var TaskRunStatus = /*#__PURE__*/function (TaskRunStatus) {
30
- TaskRunStatus["Pending"] = "pending";
31
- TaskRunStatus["Running"] = "running";
32
- TaskRunStatus["Success"] = "success";
33
- TaskRunStatus["Failed"] = "failed";
34
- return TaskRunStatus;
35
- }({});
36
-
37
- /**
38
- * 舍入规则枚举
39
- */
40
- export var RoundingRule = /*#__PURE__*/function (RoundingRule) {
41
- RoundingRule["Standard"] = "standard_rounding";
42
- RoundingRule["StandardDown"] = "standard_down";
43
- RoundingRule["AlwaysUp"] = "always_up";
44
- RoundingRule["AlwaysDown"] = "always_down";
45
- return RoundingRule;
46
- }({});
47
-
48
- /**
49
- * 舍入结果
50
- */
51
-
52
- /**
53
- * 舍入间隔枚举
54
- */
55
- export var RoundingInterval = /*#__PURE__*/function (RoundingInterval) {
56
- RoundingInterval[RoundingInterval["Interval005"] = 0.05] = "Interval005";
57
- RoundingInterval[RoundingInterval["Interval01"] = 0.1] = "Interval01";
58
- RoundingInterval[RoundingInterval["Interval05"] = 0.5] = "Interval05";
59
- RoundingInterval[RoundingInterval["Interval1"] = 1] = "Interval1";
60
- return RoundingInterval;
61
- }({});
62
-
63
- /**
64
- * 支付方式信息
65
- */
66
-
67
- /**
68
- * 支付项
69
- */
70
-
71
- /**
72
- * 订单信息
73
- */
74
-
75
- /**
76
- * 支付订单(简化版,仅保留支付相关信息)
77
- */
78
-
79
- /**
80
- * 支付状态
81
- */
82
-
83
- /**
84
- * 推送订单参数(简化版)
85
- */
86
-
87
- /**
88
- * 更新订单参数
89
- */
90
-
91
- /**
92
- * 支付项输入类型(允许 amount 为数字)
93
- */
94
-
95
- /**
96
- * 推送支付项参数
97
- */
98
-
99
- /**
100
- * 更新支付项参数中的字段类型(允许 amount 为数字)
101
- */
102
-
103
- /**
104
- * 更新支付项参数
105
- */
106
-
107
- /**
108
- * 删除支付项参数
109
- */
110
-
111
- /**
112
- * 现金支付接口
113
- */
1
+ // import { Order } from '../Order/types'
114
2
 
115
- /**
116
- * Eftpos支付接口
117
- */
118
-
119
- /**
120
- * 钱包支付接口
121
- */
122
-
123
- /**
124
- * 支付模块API接口
125
- */
126
-
127
- /**
128
- * 订单变化事件数据
129
- */
130
-
131
- /**
132
- * 支付方式变化事件数据
133
- */
134
-
135
- /**
136
- * 支付同步错误事件数据
137
- */
138
-
139
- /**
140
- * 支付同步成功事件数据
141
- */
142
-
143
- /**
144
- * 钱包推荐列表更新事件数据
145
- */
146
-
147
- /**
148
- * 用户识别码列表更新事件数据
149
- */
150
-
151
- /**
152
- * 钱包缓存清除事件数据
153
- */
154
-
155
- /**
156
- * 搜索识别码完成事件数据
157
- */
158
-
159
- /**
160
- * 钱包初始化开始事件数据
161
- */
162
-
163
- /**
164
- * 钱包初始化完成事件数据
165
- */
166
-
167
- /**
168
- * 钱包初始化失败事件数据
169
- */
170
-
171
- /**
172
- * 钱包支付事件枚举
173
- */
174
- export var WalletPassHooks = /*#__PURE__*/function (WalletPassHooks) {
175
- WalletPassHooks["OnWalletRecommendListUpdated"] = "wallet:onWalletRecommendListUpdated";
176
- WalletPassHooks["OnWalletRecommendListCleared"] = "wallet:onWalletRecommendListCleared";
177
- WalletPassHooks["OnUserIdentificationCodesUpdated"] = "wallet:onUserIdentificationCodesUpdated";
178
- WalletPassHooks["OnUserIdentificationCodesCleared"] = "wallet:onUserIdentificationCodesCleared";
179
- WalletPassHooks["OnWalletCacheCleared"] = "wallet:onWalletCacheCleared";
180
- WalletPassHooks["OnSearchIdentificationCodeCompleted"] = "wallet:onSearchIdentificationCodeCompleted";
181
- WalletPassHooks["OnWalletInitializationStarted"] = "wallet:onWalletInitializationStarted";
182
- WalletPassHooks["OnWalletInitializationCompleted"] = "wallet:onWalletInitializationCompleted";
183
- WalletPassHooks["OnWalletInitializationFailed"] = "wallet:onWalletInitializationFailed";
184
- return WalletPassHooks;
185
- }({});
186
-
187
- /**
188
- * 支付钩子事件(统一接口)
189
- */
190
3
  export var PaymentHooks = /*#__PURE__*/function (PaymentHooks) {
191
- PaymentHooks["OnPaymentMethodsLoaded"] = "payment:onPaymentMethodsLoaded";
192
- PaymentHooks["OnPaymentMethodsChanged"] = "payment:onPaymentMethodsChanged";
193
- PaymentHooks["OnOrderChanged"] = "payment:onOrderChanged";
194
- PaymentHooks["OnOrderAdded"] = "payment:onOrderAdded";
195
- PaymentHooks["OnOrderUpdated"] = "payment:onOrderUpdated";
196
- PaymentHooks["OnOrderDeleted"] = "payment:onOrderDeleted";
197
- PaymentHooks["OnPaymentAdded"] = "payment:onPaymentAdded";
198
- PaymentHooks["OnPaymentUpdated"] = "payment:onPaymentUpdated";
199
- PaymentHooks["OnPaymentDeleted"] = "payment:onPaymentDeleted";
200
- PaymentHooks["OnPaymentSubmitted"] = "payment:onPaymentSubmitted";
201
- PaymentHooks["OnOrderAmountChanged"] = "payment:onOrderAmountChanged";
202
- PaymentHooks["OnPaymentSyncError"] = "payment:onPaymentSyncError";
203
- PaymentHooks["OnPaymentSyncSuccess"] = "payment:onPaymentSyncSuccess";
204
- PaymentHooks["OnWalletRecommendListUpdated"] = "wallet:onWalletRecommendListUpdated";
205
- PaymentHooks["OnWalletRecommendListCleared"] = "wallet:onWalletRecommendListCleared";
206
- PaymentHooks["OnUserIdentificationCodesUpdated"] = "wallet:onUserIdentificationCodesUpdated";
207
- PaymentHooks["OnUserIdentificationCodesCleared"] = "wallet:onUserIdentificationCodesCleared";
208
- PaymentHooks["OnWalletCacheCleared"] = "wallet:onWalletCacheCleared";
209
- PaymentHooks["OnSearchIdentificationCodeCompleted"] = "wallet:onSearchIdentificationCodeCompleted";
4
+ PaymentHooks["OnPaymentInit"] = "payment:onPaymentInit";
5
+ PaymentHooks["OnPaymentSuccess"] = "payment:onPaymentSuccess";
6
+ PaymentHooks["OnPaymentFailure"] = "payment:onPaymentFailure";
7
+ PaymentHooks["OnPaymentRefund"] = "payment:onPaymentRefund";
210
8
  return PaymentHooks;
211
9
  }({});
212
10
 
213
11
  /**
214
- * 钱包推荐扣款请求参数
215
- */
216
-
217
- /**
218
- * 钱包初始化业务数据接口
219
- * 用于生成钱包API参数的必要业务信息
220
- */
221
-
222
- /**
223
- * 查询用户识别码列表请求参数
224
- */
225
-
226
- /**
227
- * 钱包推荐扣款响应数据
12
+ * 支付方式
228
13
  */
229
14
 
230
- /**
231
- * 用户识别码列表响应数据
232
- */
233
-
234
- /**
235
- * 用户识别码项目
236
- */
15
+ // 银行转账
237
16
 
238
17
  /**
239
- * 搜索识别码请求参数
240
- * 基于 WalletDeductionRecommendParams 并增加 code 字段
18
+ * 支付状态
241
19
  */
242
20
 
243
- /**
244
- * 搜索识别码响应数据
245
- */
21
+ // 已退款
246
22
 
247
23
  /**
248
- * 搜索识别码结果类型
24
+ * 支付信息
249
25
  */
250
26
 
251
27
  /**
252
- * 搜索识别码项目
28
+ * 支付模块状态
253
29
  */
254
30
 
255
31
  /**
256
- * 钱包推荐项目
32
+ * 支付模块 API
257
33
  */
@@ -11,17 +11,12 @@ export declare class ProductList extends BaseModule implements Module {
11
11
  constructor(name?: string, version?: string);
12
12
  initialize(core: PisellCore, options: any): Promise<void>;
13
13
  storeChange(path?: string, value?: any): Promise<void>;
14
- loadProducts({ category_ids, product_ids, collection, menu_list_ids, customer_id: paramsCustomerId, with_count, schedule_datetime, schedule_date, cacheId, with_schedule, }: {
14
+ loadProducts({ category_ids, product_ids, collection, schedule_date, cacheId }: {
15
15
  category_ids?: number[];
16
16
  product_ids?: number[];
17
17
  collection?: number | string[];
18
18
  schedule_date?: string;
19
19
  cacheId?: string;
20
- customer_id?: number;
21
- menu_list_ids?: number[];
22
- schedule_datetime?: string;
23
- with_count?: string[];
24
- with_schedule?: number;
25
20
  }): Promise<any>;
26
21
  loadProductsPrice({ ids, customer_id, schedule_date, channel, }: {
27
22
  ids?: number[];
@@ -33,10 +28,4 @@ export declare class ProductList extends BaseModule implements Module {
33
28
  getProduct(id: number): Promise<ProductData | undefined>;
34
29
  addProduct(products: ProductData[]): Promise<void>;
35
30
  selectProducts(products: ProductData[]): Promise<void>;
36
- /**
37
- * 根据商品编码或条码搜索商品
38
- * @param code 商品编码或条码
39
- * @returns 匹配的商品列表,如果没有匹配则返回空数组
40
- */
41
- findProductsByCodeOrBarcode(code: string): ProductData[];
42
31
  }
@@ -16,6 +16,7 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
16
16
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
17
17
  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); }
18
18
  import { BaseModule } from "../BaseModule";
19
+ import { ProductListHooks } from "./types";
19
20
  import { cloneDeep } from 'lodash-es';
20
21
  export * from "./types";
21
22
  export var ProductList = /*#__PURE__*/function (_BaseModule) {
@@ -86,11 +87,11 @@ export var ProductList = /*#__PURE__*/function (_BaseModule) {
86
87
  value: function () {
87
88
  var _loadProducts = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(_ref) {
88
89
  var _this$otherParams;
89
- var _ref$category_ids, category_ids, _ref$product_ids, product_ids, _ref$collection, collection, _ref$menu_list_ids, menu_list_ids, paramsCustomerId, _ref$with_count, with_count, schedule_datetime, schedule_date, cacheId, with_schedule, userPlugin, customer_id, _userPlugin$get, productsData, sortedList;
90
+ var _ref$category_ids, category_ids, _ref$product_ids, product_ids, _ref$collection, collection, schedule_date, cacheId, userPlugin, customer_id, _userPlugin$get, productsData, sortedList;
90
91
  return _regeneratorRuntime().wrap(function _callee3$(_context3) {
91
92
  while (1) switch (_context3.prev = _context3.next) {
92
93
  case 0:
93
- _ref$category_ids = _ref.category_ids, category_ids = _ref$category_ids === void 0 ? [] : _ref$category_ids, _ref$product_ids = _ref.product_ids, product_ids = _ref$product_ids === void 0 ? [] : _ref$product_ids, _ref$collection = _ref.collection, collection = _ref$collection === void 0 ? [] : _ref$collection, _ref$menu_list_ids = _ref.menu_list_ids, menu_list_ids = _ref$menu_list_ids === void 0 ? [] : _ref$menu_list_ids, paramsCustomerId = _ref.customer_id, _ref$with_count = _ref.with_count, with_count = _ref$with_count === void 0 ? [] : _ref$with_count, schedule_datetime = _ref.schedule_datetime, schedule_date = _ref.schedule_date, cacheId = _ref.cacheId, with_schedule = _ref.with_schedule;
94
+ _ref$category_ids = _ref.category_ids, category_ids = _ref$category_ids === void 0 ? [] : _ref$category_ids, _ref$product_ids = _ref.product_ids, product_ids = _ref$product_ids === void 0 ? [] : _ref$product_ids, _ref$collection = _ref.collection, collection = _ref$collection === void 0 ? [] : _ref$collection, schedule_date = _ref.schedule_date, cacheId = _ref.cacheId;
94
95
  // // 如果 schedule_ids 为空,则需要尝试从 schedule 模块里获取
95
96
  // if (!schedule_ids?.length) {
96
97
  // const schedule_ids_data = this.store.schedule
@@ -106,7 +107,7 @@ export var ProductList = /*#__PURE__*/function (_BaseModule) {
106
107
  userPlugin = this.core.getPlugin('user');
107
108
  customer_id = undefined;
108
109
  try {
109
- customer_id = paramsCustomerId || (userPlugin === null || userPlugin === void 0 || (_userPlugin$get = userPlugin.get()) === null || _userPlugin$get === void 0 ? void 0 : _userPlugin$get.id);
110
+ customer_id = userPlugin === null || userPlugin === void 0 || (_userPlugin$get = userPlugin.get()) === null || _userPlugin$get === void 0 ? void 0 : _userPlugin$get.id;
110
111
  } catch (error) {
111
112
  console.error(error);
112
113
  }
@@ -125,13 +126,9 @@ export var ProductList = /*#__PURE__*/function (_BaseModule) {
125
126
  ids: product_ids,
126
127
  collection: collection,
127
128
  front_end_cache_id: cacheId,
128
- menu_list_ids: menu_list_ids,
129
- with_count: with_count,
130
129
  // client_schedule_ids: schedule_ids,
131
130
  schedule_date: schedule_date,
132
131
  application_code: (_this$otherParams = this.otherParams) === null || _this$otherParams === void 0 ? void 0 : _this$otherParams.channel,
133
- with_schedule: with_schedule,
134
- schedule_datetime: schedule_datetime,
135
132
  is_eject: 1
136
133
  }, {
137
134
  useCache: true
@@ -200,7 +197,7 @@ export var ProductList = /*#__PURE__*/function (_BaseModule) {
200
197
  while (1) switch (_context5.prev = _context5.next) {
201
198
  case 0:
202
199
  _context5.next = 2;
203
- return this.core.effects.emit("".concat(this.name, ":onGetProducts"), this.store.list);
200
+ return this.core.effects.emit(ProductListHooks.onGetProducts, this.store.list);
204
201
  case 2:
205
202
  return _context5.abrupt("return", cloneDeep(this.store.list));
206
203
  case 3:
@@ -223,7 +220,7 @@ export var ProductList = /*#__PURE__*/function (_BaseModule) {
223
220
  while (1) switch (_context6.prev = _context6.next) {
224
221
  case 0:
225
222
  _context6.next = 2;
226
- return this.core.effects.emit("".concat(this.name, ":onGetProduct"), this.store.list);
223
+ return this.core.effects.emit(ProductListHooks.onGetProduct, this.store.list);
227
224
  case 2:
228
225
  product = this.store.list.find(function (product) {
229
226
  return product.id === id;
@@ -297,26 +294,6 @@ export var ProductList = /*#__PURE__*/function (_BaseModule) {
297
294
  }
298
295
  return selectProducts;
299
296
  }()
300
- /**
301
- * 根据商品编码或条码搜索商品
302
- * @param code 商品编码或条码
303
- * @returns 匹配的商品列表,如果没有匹配则返回空数组
304
- */
305
- }, {
306
- key: "findProductsByCodeOrBarcode",
307
- value: function findProductsByCodeOrBarcode(code) {
308
- if (!code || typeof code !== 'string') {
309
- return [];
310
- }
311
- var trimmedCode = code.trim();
312
- if (!trimmedCode) {
313
- return [];
314
- }
315
- var matchingProducts = this.store.list.filter(function (product) {
316
- return product.code && product.code.trim() === trimmedCode || product.barcode && product.barcode.trim() === trimmedCode;
317
- });
318
- return cloneDeep(matchingProducts);
319
- }
320
297
  }]);
321
298
  return ProductList;
322
299
  }(BaseModule);
@@ -89,7 +89,7 @@ export var ResourceListModule = /*#__PURE__*/function (_BaseModule) {
89
89
  case 3:
90
90
  this.store.selectedResource = resource;
91
91
  _context3.next = 6;
92
- return this.core.effects.emit("".concat(this.name, ":onResourceSelect"), resource);
92
+ return this.core.effects.emit(ResourceHooks.OnResourceSelect, resource);
93
93
  case 6:
94
94
  case "end":
95
95
  return _context3.stop();
@@ -1,8 +1,7 @@
1
1
  import { Module, PisellCore, ModuleOptions } from '../../types';
2
2
  import { BaseModule } from '../BaseModule';
3
- import { Rules, RulesModuleAPI, DiscountResult } from './types';
3
+ import { Rules, RulesModuleAPI, DiscountResult, UnavailableReason } from './types';
4
4
  import { Discount } from "../Discount/types";
5
- import { SetDiscountSelectedParams } from '../../solution/ShopDiscount/types';
6
5
  export declare class RulesModule extends BaseModule implements Module, RulesModuleAPI {
7
6
  protected defaultName: string;
8
7
  protected defaultVersion: string;
@@ -25,7 +24,9 @@ export declare class RulesModule extends BaseModule implements Module, RulesModu
25
24
  isAvailable: boolean;
26
25
  discountList: Discount[];
27
26
  productList: any[];
27
+ unavailableReason?: UnavailableReason;
28
28
  };
29
+ private getUnavailableReason;
29
30
  calcDiscount({ discountList, productList, holders, isFormSubject, }: {
30
31
  discountList: Discount[];
31
32
  productList: any[];
@@ -36,7 +37,7 @@ export declare class RulesModule extends BaseModule implements Module, RulesModu
36
37
  }, options?: {
37
38
  isSelected?: boolean;
38
39
  discountId?: number;
39
- selectedList?: SetDiscountSelectedParams[];
40
+ selectedList?: any[];
40
41
  scan?: boolean;
41
42
  }): DiscountResult;
42
43
  /**