@pisell/private-materials 3.3.10 → 3.3.13

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 (419) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/meta.js +1 -1
  5. package/build/lowcode/render/default/view.js +3 -3
  6. package/build/lowcode/view.js +3 -3
  7. package/es/components/appointmentBooking/components/Cart/ContinueButton/index.d.ts +1 -2
  8. package/es/components/appointmentBooking/components/Cart/ContinueButton/index.js +42 -242
  9. package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -1
  10. package/es/components/appointmentBooking/components/Cart/Item/index.js +13 -5
  11. package/es/components/appointmentBooking/components/Cart/index.d.ts +1 -1
  12. package/es/components/appointmentBooking/components/Cart/index.js +5 -2
  13. package/es/components/appointmentBooking/components/Cart/utils.d.ts +0 -41
  14. package/es/components/appointmentBooking/components/Cart/utils.js +4 -308
  15. package/es/components/appointmentBooking/components/ConfirmInformation/index.d.ts +2 -1
  16. package/es/components/appointmentBooking/components/ConfirmInformation/index.js +145 -4
  17. package/es/components/appointmentBooking/components/Content/index.js +35 -28
  18. package/es/components/appointmentBooking/components/Date/index.d.ts +3 -2
  19. package/es/components/appointmentBooking/components/Date/index.js +67 -34
  20. package/es/components/appointmentBooking/components/Footer/index.d.ts +1 -1
  21. package/es/components/appointmentBooking/components/Footer/index.js +12 -10
  22. package/es/components/appointmentBooking/components/Form/index.js +40 -13
  23. package/es/components/appointmentBooking/components/Guest/index.d.ts +2 -1
  24. package/es/components/appointmentBooking/components/Guest/index.js +10 -3
  25. package/es/components/appointmentBooking/components/Header/index.js +31 -23
  26. package/es/components/appointmentBooking/components/Resource/index.d.ts +5 -1
  27. package/es/components/appointmentBooking/components/Resource/index.js +138 -47
  28. package/es/components/appointmentBooking/components/Resource/utils.d.ts +5 -0
  29. package/es/components/appointmentBooking/components/Resource/utils.js +16 -0
  30. package/es/components/appointmentBooking/components/Services/index.d.ts +2 -1
  31. package/es/components/appointmentBooking/components/Services/index.js +17 -72
  32. package/es/components/appointmentBooking/components/TimeSlicing/index.d.ts +3 -2
  33. package/es/components/appointmentBooking/components/TimeSlicing/index.js +17 -4
  34. package/es/components/appointmentBooking/context.js +13 -2
  35. package/es/components/appointmentBooking/deposit/components/PolicyModal/index.js +12 -9
  36. package/es/components/appointmentBooking/hooks.d.ts +2 -1
  37. package/es/components/appointmentBooking/hooks.js +71 -22
  38. package/es/components/appointmentBooking/utils.d.ts +23 -60
  39. package/es/components/appointmentBooking/utils.js +157 -175
  40. package/es/components/booking/forms/sendModal/useSendModal.d.ts +1 -1
  41. package/es/components/booking/info/utils.js +1 -1
  42. package/es/components/ticketBooking/components/ticketBooking/index.js +4 -2
  43. package/lib/components/appointmentBooking/components/Cart/ContinueButton/index.d.ts +1 -2
  44. package/lib/components/appointmentBooking/components/Cart/ContinueButton/index.js +10 -123
  45. package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -1
  46. package/lib/components/appointmentBooking/components/Cart/Item/index.js +4 -5
  47. package/lib/components/appointmentBooking/components/Cart/index.d.ts +1 -1
  48. package/lib/components/appointmentBooking/components/Cart/index.js +2 -2
  49. package/lib/components/appointmentBooking/components/Cart/utils.d.ts +0 -41
  50. package/lib/components/appointmentBooking/components/Cart/utils.js +6 -184
  51. package/lib/components/appointmentBooking/components/ConfirmInformation/index.d.ts +2 -1
  52. package/lib/components/appointmentBooking/components/ConfirmInformation/index.js +65 -3
  53. package/lib/components/appointmentBooking/components/Content/index.js +36 -22
  54. package/lib/components/appointmentBooking/components/Date/index.d.ts +3 -2
  55. package/lib/components/appointmentBooking/components/Date/index.js +13 -3
  56. package/lib/components/appointmentBooking/components/Footer/index.d.ts +1 -1
  57. package/lib/components/appointmentBooking/components/Footer/index.js +16 -12
  58. package/lib/components/appointmentBooking/components/Form/index.js +17 -11
  59. package/lib/components/appointmentBooking/components/Guest/index.d.ts +2 -1
  60. package/lib/components/appointmentBooking/components/Guest/index.js +7 -2
  61. package/lib/components/appointmentBooking/components/Header/index.js +10 -10
  62. package/lib/components/appointmentBooking/components/Resource/index.d.ts +5 -1
  63. package/lib/components/appointmentBooking/components/Resource/index.js +83 -30
  64. package/lib/components/appointmentBooking/components/Resource/utils.d.ts +5 -0
  65. package/lib/components/appointmentBooking/components/Resource/utils.js +36 -0
  66. package/lib/components/appointmentBooking/components/Services/index.d.ts +2 -1
  67. package/lib/components/appointmentBooking/components/Services/index.js +7 -6
  68. package/lib/components/appointmentBooking/components/TimeSlicing/index.d.ts +3 -2
  69. package/lib/components/appointmentBooking/components/TimeSlicing/index.js +14 -3
  70. package/lib/components/appointmentBooking/context.js +7 -2
  71. package/lib/components/appointmentBooking/deposit/components/PolicyModal/index.js +3 -1
  72. package/lib/components/appointmentBooking/hooks.d.ts +2 -1
  73. package/lib/components/appointmentBooking/hooks.js +29 -8
  74. package/lib/components/appointmentBooking/utils.d.ts +23 -60
  75. package/lib/components/appointmentBooking/utils.js +84 -82
  76. package/lib/components/booking/forms/sendModal/useSendModal.d.ts +1 -1
  77. package/lib/components/booking/info/utils.js +1 -1
  78. package/lib/components/ticketBooking/components/ticketBooking/index.js +4 -2
  79. package/package.json +3 -3
  80. package/es/businessModel/SalesModel/Sales/index.d.ts +0 -24
  81. package/es/businessModel/SalesModel/hooks/index.d.ts +0 -1
  82. package/es/businessModel/SalesModel/index.d.ts +0 -3
  83. package/es/businessModel/index.d.ts +0 -0
  84. package/es/components/Sales/Cart/index.d.ts +0 -53
  85. package/es/components/Sales/Cart/serve.d.ts +0 -2
  86. package/es/components/Sales/Cart/types.d.ts +0 -19
  87. package/es/components/Sales/Checkout/index.d.ts +0 -33
  88. package/es/components/Sales/Checkout/serve.d.ts +0 -2
  89. package/es/components/Sales/Checkout/utils.d.ts +0 -27
  90. package/es/components/Sales/Customer/index.d.ts +0 -24
  91. package/es/components/Sales/Event/Detail.d.ts +0 -27
  92. package/es/components/Sales/Event/index.d.ts +0 -30
  93. package/es/components/Sales/Event/serve.d.ts +0 -26
  94. package/es/components/Sales/Holder/index.d.ts +0 -33
  95. package/es/components/Sales/Holder/serve.d.ts +0 -8
  96. package/es/components/Sales/Init/index.d.ts +0 -24
  97. package/es/components/Sales/Init/serve.d.ts +0 -3
  98. package/es/components/Sales/Resource/index.d.ts +0 -26
  99. package/es/components/Sales/Resource/serve.d.ts +0 -5
  100. package/es/components/Sales/Step/index.d.ts +0 -37
  101. package/es/components/Sales/Summary/index.d.ts +0 -25
  102. package/es/components/Sales/Summary/serve.d.ts +0 -0
  103. package/es/components/Sales/Summary/utils.d.ts +0 -36
  104. package/es/components/Sales/hooks/index.d.ts +0 -1
  105. package/es/components/Sales/index.d.ts +0 -20
  106. package/es/components/Sales/utils/index.d.ts +0 -1
  107. package/es/components/appointmentBooking/components/Date/state.d.ts +0 -62
  108. package/es/components/appointmentBooking/locales.d.ts +0 -345
  109. package/es/components/appointmentBooking/mock.d.ts +0 -627
  110. package/es/components/appointmentBooking/status.d.ts +0 -21
  111. package/es/components/appointmentBooking/type.d.ts +0 -17
  112. package/es/components/booking/addons/index.d.ts +0 -17
  113. package/es/components/booking/components/customSelect/index.d.ts +0 -38
  114. package/es/components/booking/components/footer/amount.d.ts +0 -23
  115. package/es/components/booking/components/footer/index.d.ts +0 -11
  116. package/es/components/booking/components/footer/serve.d.ts +0 -3
  117. package/es/components/booking/components/footer/utils.d.ts +0 -30
  118. package/es/components/booking/forms/index.d.ts +0 -9
  119. package/es/components/booking/forms/serve.d.ts +0 -18
  120. package/es/components/booking/hooks/useCreateBookingPageHeader.d.ts +0 -6
  121. package/es/components/booking/hooks/useIsBooking4Shop.d.ts +0 -1
  122. package/es/components/booking/info/Provider.d.ts +0 -0
  123. package/es/components/booking/info/addServiceVariant/index.d.ts +0 -6
  124. package/es/components/booking/info/clientVariant/vertical/SelectDrawer.d.ts +0 -25
  125. package/es/components/booking/info/clientVariant/vertical/index.d.ts +0 -8
  126. package/es/components/booking/info/hooks/useAddHolder.d.ts +0 -2
  127. package/es/components/booking/info/hooks/useHolderConfig.d.ts +0 -9
  128. package/es/components/booking/info/hooks/useInfoHolder.d.ts +0 -9
  129. package/es/components/booking/info/index.d.ts +0 -3
  130. package/es/components/booking/info/main.d.ts +0 -12
  131. package/es/components/booking/info/model.d.ts +0 -14
  132. package/es/components/booking/info/pet/index.d.ts +0 -14
  133. package/es/components/booking/info/service/Lists.d.ts +0 -2
  134. package/es/components/booking/info/service/addService/index.d.ts +0 -11
  135. package/es/components/booking/info/service/addService/utils.d.ts +0 -71
  136. package/es/components/booking/info/service/editService/EditTabs/index.d.ts +0 -3
  137. package/es/components/booking/info/service/index.d.ts +0 -4
  138. package/es/components/booking/info/service/serve.d.ts +0 -11
  139. package/es/components/booking/info/service/serviceList/index.d.ts +0 -5
  140. package/es/components/booking/info/service/serviceManager/distributeDiscount.d.ts +0 -11
  141. package/es/components/booking/info/service/serviceManager/index.d.ts +0 -20
  142. package/es/components/booking/info/service/serviceManager/utils.d.ts +0 -0
  143. package/es/components/booking/info/service2/Group/utils.d.ts +0 -14
  144. package/es/components/booking/info/service2/Lists.d.ts +0 -2
  145. package/es/components/booking/info/service2/hooks/useSelectPet.d.ts +0 -6
  146. package/es/components/booking/info/service2/index.d.ts +0 -6
  147. package/es/components/booking/info/service2/status.d.ts +0 -31
  148. package/es/components/booking/info/service2/utils.d.ts +0 -241
  149. package/es/components/booking/info2/index.d.ts +0 -12
  150. package/es/components/booking/info2/serve.d.ts +0 -6
  151. package/es/components/booking/info2/service/addService/index.d.ts +0 -11
  152. package/es/components/booking/info2/service/addService/utils.d.ts +0 -88
  153. package/es/components/booking/info2/service/addTimeModal/index.d.ts +0 -3
  154. package/es/components/booking/info2/service/editService/Resources/MaxLengthSelect/index.d.ts +0 -7
  155. package/es/components/booking/info2/service/editService/Resources/index.d.ts +0 -4
  156. package/es/components/booking/info2/service/editService/utils.d.ts +0 -13
  157. package/es/components/booking/info2/service/index.d.ts +0 -4
  158. package/es/components/booking/info2/utils.d.ts +0 -4
  159. package/es/components/booking/info2/utilsByBooking.d.ts +0 -34
  160. package/es/components/booking/locales.d.ts +0 -786
  161. package/es/components/booking/materiels/contacts/index.d.ts +0 -15
  162. package/es/components/booking/materiels/holder/index.d.ts +0 -6
  163. package/es/components/booking/model.d.ts +0 -115
  164. package/es/components/booking/notes/addNote/index.d.ts +0 -3
  165. package/es/components/booking/payments/index.d.ts +0 -9
  166. package/es/components/booking/utils.d.ts +0 -172
  167. package/es/components/eftpos/index.d.ts +0 -46
  168. package/es/components/eftposPay/index.d.ts +0 -4
  169. package/es/components/eftposPay/windcave/windcave.d.ts +0 -6
  170. package/es/components/eventBooking/components/Provider/Content/index.d.ts +0 -3
  171. package/es/components/eventBooking/components/Provider/Header/index.d.ts +0 -3
  172. package/es/components/eventBooking/components/Provider/SelectHolderModal.d.ts +0 -2
  173. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -3
  174. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -3
  175. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -4
  176. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -3
  177. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/state.d.ts +0 -63
  178. package/es/components/eventBooking/components/bookingAvailabilityCalendar/index.d.ts +0 -14
  179. package/es/components/eventBooking/components/bookingAvailabilityCalendar/utils.d.ts +0 -34
  180. package/es/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +0 -2
  181. package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +0 -2
  182. package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +0 -9
  183. package/es/components/eventBooking/components/scheduleCalendar/index.d.ts +0 -13
  184. package/es/components/eventBooking/index.d.ts +0 -3
  185. package/es/components/eventBooking/locales.d.ts +0 -216
  186. package/es/components/eventBooking/mock.d.ts +0 -627
  187. package/es/components/eventBooking/status.d.ts +0 -21
  188. package/es/components/eventBooking/type.d.ts +0 -17
  189. package/es/components/eventBooking/utils.d.ts +0 -45
  190. package/es/components/index.d.ts +0 -18
  191. package/es/components/login/index.d.ts +0 -8
  192. package/es/components/login/locales.d.ts +0 -24
  193. package/es/components/pay/toC/PaymentList/serve.d.ts +0 -28
  194. package/es/components/pay/toC/serve.d.ts +0 -34
  195. package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -2
  196. package/es/components/productExtension/index.d.ts +0 -7
  197. package/es/components/productSelect/hooks/useToken.d.ts +0 -18
  198. package/es/components/productSelect/locales.d.ts +0 -18
  199. package/es/components/productSelect/mock.d.ts +0 -134
  200. package/es/components/productSelect/theme/token.d.ts +0 -17
  201. package/es/components/ruleSetting/index.d.ts +0 -9
  202. package/es/components/schedules/index.d.ts +0 -3
  203. package/es/components/shoppingCart/Provider.d.ts +0 -3
  204. package/es/components/shoppingCart/components/Empty/index.d.ts +0 -3
  205. package/es/components/shoppingCart/components/Render/index.d.ts +0 -3
  206. package/es/components/shoppingCart/hooks/useContext.d.ts +0 -1
  207. package/es/components/shoppingCart/index.d.ts +0 -3
  208. package/es/components/shoppingCart/locales.d.ts +0 -33
  209. package/es/components/shoppingCart/mock.d.ts +0 -40
  210. package/es/components/shoppingCart/status.d.ts +0 -2
  211. package/es/components/shoppingCart/type.d.ts +0 -48
  212. package/es/components/shoppingCart/utils.d.ts +0 -63
  213. package/es/components/subTotal/locales.d.ts +0 -42
  214. package/es/components/taxSelect/index.d.ts +0 -11
  215. package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -6
  216. package/es/components/ticketBooking/components/menuBar/index.d.ts +0 -3
  217. package/es/components/ticketBooking/data.d.ts +0 -58
  218. package/es/components/ticketBooking/hooks/useNetworkStatus.d.ts +0 -11
  219. package/es/components/ticketBooking/index.d.ts +0 -3
  220. package/es/components/ticketBooking/locales.d.ts +0 -144
  221. package/es/components/ticketBooking/miniRedux.d.ts +0 -22
  222. package/es/components/ticketBooking/serve.d.ts +0 -282
  223. package/es/components/ticketBooking/utils/index.d.ts +0 -14
  224. package/es/components/wallet/Detail/locales.d.ts +0 -96
  225. package/es/components/wallet/Detail/model.d.ts +0 -13
  226. package/es/components/wallet/Detail/serve.d.ts +0 -39
  227. package/es/components/wallet/DetailContext.d.ts +0 -25
  228. package/es/components/wallet/DiscountCard/model.d.ts +0 -14
  229. package/es/components/wallet/PointCard/model.d.ts +0 -13
  230. package/es/components/wallet/RechargeableCard/model.d.ts +0 -29
  231. package/es/components/wallet/RechargeableCard/serve.d.ts +0 -23
  232. package/es/components/wallet/Voucher/locales.d.ts +0 -21
  233. package/es/components/wallet/Voucher/model.d.ts +0 -13
  234. package/es/components/wallet/components/FooterButtons/index.d.ts +0 -18
  235. package/es/components/wallet/components/index.d.ts +0 -2
  236. package/es/components/wallet/hooks/useWalletCard.d.ts +0 -33
  237. package/es/components/wallet/locales.d.ts +0 -132
  238. package/es/components/wallet/model.d.ts +0 -37
  239. package/es/components/wallet/serve.d.ts +0 -143
  240. package/es/components/wallet/utils/formatUtils.d.ts +0 -36
  241. package/es/components/walletList/model.d.ts +0 -6
  242. package/es/components/walletList/serve.d.ts +0 -12
  243. package/es/components/walletList/types/index.d.ts +0 -194
  244. package/es/components/workSpaceList/components/WorkspaceItem/index.d.ts +0 -22
  245. package/es/hooks/useEngineContext.d.ts +0 -10
  246. package/es/index.d.ts +0 -45
  247. package/es/utils/locales.d.ts +0 -1
  248. package/es/utils/tasks/index.d.ts +0 -16
  249. package/es/utils/tasks/type.d.ts +0 -4
  250. package/lib/businessModel/SalesModel/Sales/index.d.ts +0 -24
  251. package/lib/businessModel/SalesModel/hooks/index.d.ts +0 -1
  252. package/lib/businessModel/SalesModel/index.d.ts +0 -3
  253. package/lib/businessModel/index.d.ts +0 -0
  254. package/lib/components/Sales/Cart/index.d.ts +0 -53
  255. package/lib/components/Sales/Cart/serve.d.ts +0 -2
  256. package/lib/components/Sales/Cart/types.d.ts +0 -19
  257. package/lib/components/Sales/Checkout/index.d.ts +0 -33
  258. package/lib/components/Sales/Checkout/serve.d.ts +0 -2
  259. package/lib/components/Sales/Checkout/utils.d.ts +0 -27
  260. package/lib/components/Sales/Customer/index.d.ts +0 -24
  261. package/lib/components/Sales/Event/Detail.d.ts +0 -27
  262. package/lib/components/Sales/Event/index.d.ts +0 -30
  263. package/lib/components/Sales/Event/serve.d.ts +0 -26
  264. package/lib/components/Sales/Holder/index.d.ts +0 -33
  265. package/lib/components/Sales/Holder/serve.d.ts +0 -8
  266. package/lib/components/Sales/Init/index.d.ts +0 -24
  267. package/lib/components/Sales/Init/serve.d.ts +0 -3
  268. package/lib/components/Sales/Resource/index.d.ts +0 -26
  269. package/lib/components/Sales/Resource/serve.d.ts +0 -5
  270. package/lib/components/Sales/Step/index.d.ts +0 -37
  271. package/lib/components/Sales/Summary/index.d.ts +0 -25
  272. package/lib/components/Sales/Summary/serve.d.ts +0 -0
  273. package/lib/components/Sales/Summary/utils.d.ts +0 -36
  274. package/lib/components/Sales/hooks/index.d.ts +0 -1
  275. package/lib/components/Sales/index.d.ts +0 -20
  276. package/lib/components/Sales/utils/index.d.ts +0 -1
  277. package/lib/components/appointmentBooking/components/Date/state.d.ts +0 -62
  278. package/lib/components/appointmentBooking/locales.d.ts +0 -345
  279. package/lib/components/appointmentBooking/mock.d.ts +0 -627
  280. package/lib/components/appointmentBooking/status.d.ts +0 -21
  281. package/lib/components/appointmentBooking/type.d.ts +0 -17
  282. package/lib/components/booking/addons/index.d.ts +0 -17
  283. package/lib/components/booking/components/customSelect/index.d.ts +0 -38
  284. package/lib/components/booking/components/footer/amount.d.ts +0 -23
  285. package/lib/components/booking/components/footer/index.d.ts +0 -11
  286. package/lib/components/booking/components/footer/serve.d.ts +0 -3
  287. package/lib/components/booking/components/footer/utils.d.ts +0 -30
  288. package/lib/components/booking/forms/index.d.ts +0 -9
  289. package/lib/components/booking/forms/serve.d.ts +0 -18
  290. package/lib/components/booking/hooks/useCreateBookingPageHeader.d.ts +0 -6
  291. package/lib/components/booking/hooks/useIsBooking4Shop.d.ts +0 -1
  292. package/lib/components/booking/info/Provider.d.ts +0 -0
  293. package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -6
  294. package/lib/components/booking/info/clientVariant/vertical/SelectDrawer.d.ts +0 -25
  295. package/lib/components/booking/info/clientVariant/vertical/index.d.ts +0 -8
  296. package/lib/components/booking/info/hooks/useAddHolder.d.ts +0 -2
  297. package/lib/components/booking/info/hooks/useHolderConfig.d.ts +0 -9
  298. package/lib/components/booking/info/hooks/useInfoHolder.d.ts +0 -9
  299. package/lib/components/booking/info/index.d.ts +0 -3
  300. package/lib/components/booking/info/main.d.ts +0 -12
  301. package/lib/components/booking/info/model.d.ts +0 -14
  302. package/lib/components/booking/info/pet/index.d.ts +0 -14
  303. package/lib/components/booking/info/service/Lists.d.ts +0 -2
  304. package/lib/components/booking/info/service/addService/index.d.ts +0 -11
  305. package/lib/components/booking/info/service/addService/utils.d.ts +0 -71
  306. package/lib/components/booking/info/service/editService/EditTabs/index.d.ts +0 -3
  307. package/lib/components/booking/info/service/index.d.ts +0 -4
  308. package/lib/components/booking/info/service/serve.d.ts +0 -11
  309. package/lib/components/booking/info/service/serviceList/index.d.ts +0 -5
  310. package/lib/components/booking/info/service/serviceManager/distributeDiscount.d.ts +0 -11
  311. package/lib/components/booking/info/service/serviceManager/index.d.ts +0 -20
  312. package/lib/components/booking/info/service/serviceManager/utils.d.ts +0 -0
  313. package/lib/components/booking/info/service2/Group/utils.d.ts +0 -14
  314. package/lib/components/booking/info/service2/Lists.d.ts +0 -2
  315. package/lib/components/booking/info/service2/hooks/useSelectPet.d.ts +0 -6
  316. package/lib/components/booking/info/service2/index.d.ts +0 -6
  317. package/lib/components/booking/info/service2/status.d.ts +0 -31
  318. package/lib/components/booking/info/service2/utils.d.ts +0 -241
  319. package/lib/components/booking/info2/index.d.ts +0 -12
  320. package/lib/components/booking/info2/serve.d.ts +0 -6
  321. package/lib/components/booking/info2/service/addService/index.d.ts +0 -11
  322. package/lib/components/booking/info2/service/addService/utils.d.ts +0 -88
  323. package/lib/components/booking/info2/service/addTimeModal/index.d.ts +0 -3
  324. package/lib/components/booking/info2/service/editService/Resources/MaxLengthSelect/index.d.ts +0 -7
  325. package/lib/components/booking/info2/service/editService/Resources/index.d.ts +0 -4
  326. package/lib/components/booking/info2/service/editService/utils.d.ts +0 -13
  327. package/lib/components/booking/info2/service/index.d.ts +0 -4
  328. package/lib/components/booking/info2/utils.d.ts +0 -4
  329. package/lib/components/booking/info2/utilsByBooking.d.ts +0 -34
  330. package/lib/components/booking/locales.d.ts +0 -786
  331. package/lib/components/booking/materiels/contacts/index.d.ts +0 -15
  332. package/lib/components/booking/materiels/holder/index.d.ts +0 -6
  333. package/lib/components/booking/model.d.ts +0 -115
  334. package/lib/components/booking/notes/addNote/index.d.ts +0 -3
  335. package/lib/components/booking/payments/index.d.ts +0 -9
  336. package/lib/components/booking/utils.d.ts +0 -172
  337. package/lib/components/eftpos/index.d.ts +0 -46
  338. package/lib/components/eftposPay/index.d.ts +0 -4
  339. package/lib/components/eftposPay/windcave/windcave.d.ts +0 -6
  340. package/lib/components/eventBooking/components/Provider/Content/index.d.ts +0 -3
  341. package/lib/components/eventBooking/components/Provider/Header/index.d.ts +0 -3
  342. package/lib/components/eventBooking/components/Provider/SelectHolderModal.d.ts +0 -2
  343. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -3
  344. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -3
  345. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -4
  346. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -3
  347. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/state.d.ts +0 -63
  348. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/index.d.ts +0 -14
  349. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/utils.d.ts +0 -34
  350. package/lib/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +0 -2
  351. package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +0 -2
  352. package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +0 -9
  353. package/lib/components/eventBooking/components/scheduleCalendar/index.d.ts +0 -13
  354. package/lib/components/eventBooking/index.d.ts +0 -3
  355. package/lib/components/eventBooking/locales.d.ts +0 -216
  356. package/lib/components/eventBooking/mock.d.ts +0 -627
  357. package/lib/components/eventBooking/status.d.ts +0 -21
  358. package/lib/components/eventBooking/type.d.ts +0 -17
  359. package/lib/components/eventBooking/utils.d.ts +0 -45
  360. package/lib/components/index.d.ts +0 -18
  361. package/lib/components/login/index.d.ts +0 -8
  362. package/lib/components/login/locales.d.ts +0 -24
  363. package/lib/components/pay/toC/PaymentList/serve.d.ts +0 -28
  364. package/lib/components/pay/toC/serve.d.ts +0 -34
  365. package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -2
  366. package/lib/components/productExtension/index.d.ts +0 -7
  367. package/lib/components/productSelect/hooks/useToken.d.ts +0 -18
  368. package/lib/components/productSelect/locales.d.ts +0 -18
  369. package/lib/components/productSelect/mock.d.ts +0 -134
  370. package/lib/components/productSelect/theme/token.d.ts +0 -17
  371. package/lib/components/ruleSetting/index.d.ts +0 -9
  372. package/lib/components/schedules/index.d.ts +0 -3
  373. package/lib/components/shoppingCart/Provider.d.ts +0 -3
  374. package/lib/components/shoppingCart/components/Empty/index.d.ts +0 -3
  375. package/lib/components/shoppingCart/components/Render/index.d.ts +0 -3
  376. package/lib/components/shoppingCart/hooks/useContext.d.ts +0 -1
  377. package/lib/components/shoppingCart/index.d.ts +0 -3
  378. package/lib/components/shoppingCart/locales.d.ts +0 -33
  379. package/lib/components/shoppingCart/mock.d.ts +0 -40
  380. package/lib/components/shoppingCart/status.d.ts +0 -2
  381. package/lib/components/shoppingCart/type.d.ts +0 -48
  382. package/lib/components/shoppingCart/utils.d.ts +0 -63
  383. package/lib/components/subTotal/locales.d.ts +0 -42
  384. package/lib/components/taxSelect/index.d.ts +0 -11
  385. package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -6
  386. package/lib/components/ticketBooking/components/menuBar/index.d.ts +0 -3
  387. package/lib/components/ticketBooking/data.d.ts +0 -58
  388. package/lib/components/ticketBooking/hooks/useNetworkStatus.d.ts +0 -11
  389. package/lib/components/ticketBooking/index.d.ts +0 -3
  390. package/lib/components/ticketBooking/locales.d.ts +0 -144
  391. package/lib/components/ticketBooking/miniRedux.d.ts +0 -22
  392. package/lib/components/ticketBooking/serve.d.ts +0 -282
  393. package/lib/components/ticketBooking/utils/index.d.ts +0 -14
  394. package/lib/components/wallet/Detail/locales.d.ts +0 -96
  395. package/lib/components/wallet/Detail/model.d.ts +0 -13
  396. package/lib/components/wallet/Detail/serve.d.ts +0 -39
  397. package/lib/components/wallet/DetailContext.d.ts +0 -25
  398. package/lib/components/wallet/DiscountCard/model.d.ts +0 -14
  399. package/lib/components/wallet/PointCard/model.d.ts +0 -13
  400. package/lib/components/wallet/RechargeableCard/model.d.ts +0 -29
  401. package/lib/components/wallet/RechargeableCard/serve.d.ts +0 -23
  402. package/lib/components/wallet/Voucher/locales.d.ts +0 -21
  403. package/lib/components/wallet/Voucher/model.d.ts +0 -13
  404. package/lib/components/wallet/components/FooterButtons/index.d.ts +0 -18
  405. package/lib/components/wallet/components/index.d.ts +0 -2
  406. package/lib/components/wallet/hooks/useWalletCard.d.ts +0 -33
  407. package/lib/components/wallet/locales.d.ts +0 -132
  408. package/lib/components/wallet/model.d.ts +0 -37
  409. package/lib/components/wallet/serve.d.ts +0 -143
  410. package/lib/components/wallet/utils/formatUtils.d.ts +0 -36
  411. package/lib/components/walletList/model.d.ts +0 -6
  412. package/lib/components/walletList/serve.d.ts +0 -12
  413. package/lib/components/walletList/types/index.d.ts +0 -194
  414. package/lib/components/workSpaceList/components/WorkspaceItem/index.d.ts +0 -22
  415. package/lib/hooks/useEngineContext.d.ts +0 -10
  416. package/lib/index.d.ts +0 -45
  417. package/lib/utils/locales.d.ts +0 -1
  418. package/lib/utils/tasks/index.d.ts +0 -16
  419. package/lib/utils/tasks/type.d.ts +0 -4
@@ -1,117 +1,27 @@
1
1
  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); }
2
2
  function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
3
3
  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."); }
4
+ 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); }
4
5
  function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
5
6
  function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
6
- 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; } } }; }
7
- 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); }
8
7
  function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
9
8
  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; }
10
9
  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; }
11
10
  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; }
12
11
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
13
12
  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); }
14
- import dayjs from 'dayjs';
15
13
  import { getUniqueId, locales } from "@pisell/utils";
16
14
  import { PisellToast } from '@pisell/materials';
17
15
  import useEngineContext from "../../hooks/useEngineContext";
18
16
 
19
17
  /**
20
- * @title: 获取背景色
21
- * @description:
22
- * @param {string} colors
23
- * @return {*}
24
- * @Author: WangHan
25
- * @Date: 2025-01-11 22:44
26
- */
27
- export var formatBackgroundColors = function formatBackgroundColors(colors) {
28
- var _colors = Array.from(new Set(colors.map(function (color) {
29
- return color === null || color === void 0 ? void 0 : color.toLocaleLowerCase();
30
- }) || [])).filter(function (d) {
31
- return !!d;
32
- });
33
- var colorStr = _colors.map(function (color, index) {
34
- return "".concat(color, " ").concat(index * 100 / _colors.length, "% ").concat((index + 1) * 100 / _colors.length, "%");
35
- }).join(", ");
36
- if (colorStr) {
37
- return "conic-gradient(".concat(colorStr, ")");
38
- }
39
- return '';
40
- };
41
-
42
- /**
43
- * @title: 获取可用的 schedule
44
- * @description:
45
- * @param {any} schedule
46
- * @return {*}
47
- * @Author: zhiwei.Wang
48
- * @Date: 2024-03-05 18:05
49
- */
50
- export var getUsableSchedules = function getUsableSchedules(schedule) {
51
- if (!schedule) {
52
- return true;
53
- }
54
- if (!schedule.minTime || !schedule.maxTime) {
55
- return false;
56
- }
57
- var currentDate = dayjs();
58
- // 如果最大时间在当前时间之前, 代表没有可用的日程
59
- if (currentDate.isAfter(schedule.maxTime)) {
60
- return false;
61
- }
62
- return true;
63
- };
64
-
65
- /**
66
- * @title: 获取 schedules 的所有颜色
67
- * @description:
68
- * @param {any} schedules
69
- * @return {*}
70
- * @Author: zhiwei.Wang
71
- * @Date: 2024-03-05 18:02
72
- */
73
- export var getScheduleColors = function getScheduleColors(schedules) {
74
- return formatBackgroundColors(schedules.map(function (d) {
75
- return d.color;
76
- }));
77
- };
78
-
79
- /**
80
- * @title: 格式化日期头部日期显示
81
- * @description:
82
- * @param {string} dateString
83
- * @return {*}
84
- * @Author: WangHan
85
- * @Date: 2025-01-12 11:55
86
- */
87
- export var formatMonthDisplay = function formatMonthDisplay(dateString) {
88
- var _utils$storage;
89
- var context = useEngineContext();
90
- var utils = context.appHelper.utils || {};
91
- var locale = (utils === null || utils === void 0 || (_utils$storage = utils.storage) === null || _utils$storage === void 0 ? void 0 : _utils$storage.get('umi_locale')) || 'en-US';
92
- var date = new Date(dateString + '-01');
93
- return date.toLocaleString(locale, {
94
- month: 'long',
95
- year: 'numeric'
96
- });
97
- };
98
-
99
- /**
100
- * @title: 资源名称
18
+ * @title: 格式化holder表数据
101
19
  * @description:
102
20
  * @param {any} data
103
21
  * @return {*}
104
22
  * @Author: WangHan
105
- * @Date: 2025-02-11 13:39
23
+ * @Date: 2025-05-07 21:22
106
24
  */
107
- export var resourceTitle = function resourceTitle(data) {
108
- var _data$initData, _form$setting, _context$appHelper, _translation;
109
- var context = useEngineContext();
110
- var form = data === null || data === void 0 || (_data$initData = data.initData) === null || _data$initData === void 0 || (_data$initData = _data$initData.boardSetting) === null || _data$initData === void 0 || (_data$initData = _data$initData.event_v2_form) === null || _data$initData === void 0 ? void 0 : _data$initData.form;
111
- var title = (form === null || form === void 0 || (_form$setting = form.setting) === null || _form$setting === void 0 ? void 0 : _form$setting.title) || (form === null || form === void 0 ? void 0 : form.title);
112
- var translation = context === null || context === void 0 || (_context$appHelper = context.appHelper) === null || _context$appHelper === void 0 || (_context$appHelper = _context$appHelper.utils) === null || _context$appHelper === void 0 ? void 0 : _context$appHelper.translation;
113
- return (_translation = translation(title)) === null || _translation === void 0 ? void 0 : _translation.toLowerCase();
114
- };
115
25
  export var formatHolder = function formatHolder(data) {
116
26
  return data === null || data === void 0 ? void 0 : data.map(function (d) {
117
27
  return _objectSpread(_objectSpread({}, d), {}, {
@@ -137,20 +47,69 @@ export var formatGuest = function formatGuest(data, products) {
137
47
  });
138
48
  });
139
49
  };
50
+
51
+ /**
52
+ * @title: 格式化购物车中资源上挂接的表单数据
53
+ * @description:
54
+ * @param {any} data
55
+ * @param {any} resources
56
+ * @return {*}
57
+ * @Author: WangHan
58
+ * @Date: 2025-05-06 22:22
59
+ */
60
+ export var formatCartsResources = function formatCartsResources(carts, resources) {
61
+ try {
62
+ var newCarts = carts === null || carts === void 0 ? void 0 : carts.map(function (d) {
63
+ var _currentResource$reso;
64
+ var currentResource = resources === null || resources === void 0 ? void 0 : resources.find(function (r) {
65
+ return (d === null || d === void 0 ? void 0 : d._id) === (r === null || r === void 0 ? void 0 : r._id);
66
+ });
67
+ var currentResources = currentResource === null || currentResource === void 0 || (_currentResource$reso = currentResource.resources) === null || _currentResource$reso === void 0 || (_currentResource$reso = _currentResource$reso[0]) === null || _currentResource$reso === void 0 ? void 0 : _currentResource$reso.renderList;
68
+
69
+ // 当前购物车选择的资源id
70
+ var resourceId = d === null || d === void 0 ? void 0 : d.resource_id;
71
+
72
+ // 从资源列表中找到对应的资源数据
73
+ var foundResource = currentResources === null || currentResources === void 0 ? void 0 : currentResources.find(function (resource) {
74
+ return resource.id === resourceId;
75
+ });
76
+ if (foundResource !== null && foundResource !== void 0 && foundResource.resource_form_id) {
77
+ return _objectSpread(_objectSpread({}, d), {}, {
78
+ resource_form_id: foundResource === null || foundResource === void 0 ? void 0 : foundResource.resource_form_id
79
+ });
80
+ }
81
+ return false;
82
+ }).filter(Boolean);
83
+ return newCarts || [];
84
+ } catch (error) {
85
+ console.log(error, 'formatCarts');
86
+ return [];
87
+ }
88
+ };
89
+
90
+ /**
91
+ * @title: 格式化购物车数据
92
+ * @description:
93
+ * @param {any} data
94
+ * @param {any} resources
95
+ * @param {any} accountLists
96
+ * @return {*}
97
+ * @Author: WangHan
98
+ * @Date: 2025-05-07 21:22
99
+ */
140
100
  export var formatCarts = function formatCarts(data, resources, accountLists) {
141
101
  try {
142
- var _utils$storage2;
102
+ var _utils$storage;
143
103
  var context = useEngineContext();
144
104
  var utils = context.appHelper.utils || {};
145
- var locale = (utils === null || utils === void 0 || (_utils$storage2 = utils.storage) === null || _utils$storage2 === void 0 ? void 0 : _utils$storage2.get('umi_locale')) || 'en-US';
105
+ var locale = (utils === null || utils === void 0 || (_utils$storage = utils.storage) === null || _utils$storage === void 0 ? void 0 : _utils$storage.get('umi_locale')) || 'en-US';
146
106
  var symbol = (utils === null || utils === void 0 ? void 0 : utils.getSymbolic()) || '$';
147
- console.log(data, resources, 'wh9786876');
148
- return data === null || data === void 0 ? void 0 : data.map(function (d) {
149
- var _currentResource$reso, _currentResources, _d$duration;
107
+ var newCarts = data === null || data === void 0 ? void 0 : data.map(function (d) {
108
+ var _currentResource$reso2, _currentResources, _d$duration;
150
109
  var currentResource = resources === null || resources === void 0 ? void 0 : resources.find(function (r) {
151
110
  return (d === null || d === void 0 ? void 0 : d._id) === (r === null || r === void 0 ? void 0 : r._id);
152
111
  });
153
- var currentResources = currentResource === null || currentResource === void 0 || (_currentResource$reso = currentResource.resources) === null || _currentResource$reso === void 0 || (_currentResource$reso = _currentResource$reso[0]) === null || _currentResource$reso === void 0 ? void 0 : _currentResource$reso.renderList;
112
+ var currentResources = currentResource === null || currentResource === void 0 || (_currentResource$reso2 = currentResource.resources) === null || _currentResource$reso2 === void 0 || (_currentResource$reso2 = _currentResource$reso2[0]) === null || _currentResource$reso2 === void 0 ? void 0 : _currentResource$reso2.renderList;
154
113
  currentResources = (_currentResources = currentResources) === null || _currentResources === void 0 ? void 0 : _currentResources.map(function (d) {
155
114
  return _objectSpread(_objectSpread({}, d), {}, {
156
115
  label: (d === null || d === void 0 ? void 0 : d.main_field) || (d === null || d === void 0 ? void 0 : d.id)
@@ -169,6 +128,7 @@ export var formatCarts = function formatCarts(data, resources, accountLists) {
169
128
  allowClearResource: true
170
129
  });
171
130
  });
131
+ return newCarts || [];
172
132
  } catch (error) {
173
133
  console.log(error, 'formatCarts');
174
134
  return [];
@@ -207,7 +167,6 @@ export var sortResources = function sortResources(resources, resourceSort) {
207
167
  renderList: renderList
208
168
  });
209
169
  });
210
- console.log(sortedResources, 'sortedResources');
211
170
  return sortedResources || [];
212
171
  } catch (error) {
213
172
  console.log(error, 'wh2222');
@@ -241,63 +200,6 @@ export var formatCurrentUser = function formatCurrentUser() {
241
200
  return customer;
242
201
  };
243
202
 
244
- /**
245
- * @title: 检查是否有空的账户
246
- * @description:
247
- * @param {any} carts
248
- * @param {any} accounts
249
- * @return {*}
250
- * @Author: WangHan
251
- * @Date: 2025-04-15 17:05
252
- */
253
- export var isEmptyGuest = function isEmptyGuest(carts, accounts) {
254
- // 遍历账户列表
255
- var _iterator = _createForOfIteratorHelper(accounts),
256
- _step;
257
- try {
258
- var _loop = function _loop() {
259
- var item = _step.value;
260
- // 检查商品数据是否有匹配的holder_id
261
- var hasMatch = carts.some(function (firstItem) {
262
- return firstItem.holder_id === item.id;
263
- });
264
- // 如果没有找到匹配的,直接返回true
265
- if (!hasMatch) {
266
- return {
267
- v: true
268
- };
269
- }
270
- },
271
- _ret;
272
- for (_iterator.s(); !(_step = _iterator.n()).done;) {
273
- _ret = _loop();
274
- if (_ret) return _ret.v;
275
- }
276
- // 所有元素都找到了匹配,返回false
277
- } catch (err) {
278
- _iterator.e(err);
279
- } finally {
280
- _iterator.f();
281
- }
282
- return false;
283
- };
284
-
285
- /**
286
- * @title: 购物车中是否有空的资源数据
287
- * @description:
288
- * @param {any} carts
289
- * @return {*}
290
- * @Author: WangHan
291
- * @Date: 2025-04-15 21:51
292
- */
293
- export var isEmptyCartsResourceId = function isEmptyCartsResourceId(carts) {
294
- var isEmptyResourceId = carts === null || carts === void 0 ? void 0 : carts.some(function (d) {
295
- return !(d !== null && d !== void 0 && d.resource_id);
296
- });
297
- console.log(isEmptyResourceId, 'isEmptyResourceId');
298
- return isEmptyResourceId;
299
- };
300
-
301
203
  /**
302
204
  * @title: 定金合并的标点符号
303
205
  * @description:
@@ -342,9 +244,9 @@ export var hasResourceFormId = function hasResourceFormId(array) {
342
244
  var foundResource = item === null || item === void 0 || (_item$resources = item.resources) === null || _item$resources === void 0 ? void 0 : _item$resources.find(function (resource) {
343
245
  return resource.id === resourceId;
344
246
  });
345
- console.log(foundResource, item, 'foundResource');
247
+
346
248
  // 如果找到匹配项并且其 resource_form_id 存在且有值
347
- return foundResource && foundResource.resource_form_id;
249
+ return foundResource === null || foundResource === void 0 ? void 0 : foundResource.resource_form_id;
348
250
  });
349
251
  } catch (error) {
350
252
  console.log(error, 'hasResourceFormId');
@@ -426,22 +328,6 @@ export function updateLists(list, key, value, newData) {
426
328
  }
427
329
  }
428
330
 
429
- /**
430
- * @title: 检查表单是否有未完成或错误
431
- * @description:
432
- * @param {any} formStatus
433
- * @param {any} formLists
434
- * @return {*}
435
- * @Author: WangHan
436
- * @Date: 2025-04-26 18:52
437
- */
438
- export function hasFormError(formStatus, formLists) {
439
- if (formStatus.length !== formLists.length) return true;
440
- return formStatus.some(function (item) {
441
- return item.status === 'error';
442
- });
443
- }
444
-
445
331
  /**
446
332
  * @title: 更新表单存储
447
333
  * @description:
@@ -473,4 +359,100 @@ export var Toast = function Toast(text) {
473
359
  var _window;
474
360
  (_window = window) === null || _window === void 0 || _window.alert(text);
475
361
  }
362
+ };
363
+
364
+ /**
365
+ * @title: 添加或移除表单步骤
366
+ * @description:
367
+ * @param {any} param1
368
+ * @return {*}
369
+ * @Author: WangHan
370
+ * @Date: 2025-05-06 21:51
371
+ */
372
+ export var checkHasFormStep = function checkHasFormStep(_ref2) {
373
+ var _appointmentBooking$s, _appointmentBooking$s2;
374
+ var isSkip = _ref2.isSkip,
375
+ checkHolder = _ref2.checkHolder,
376
+ checkAccount = _ref2.checkAccount,
377
+ carts = _ref2.carts,
378
+ setCarts = _ref2.setCarts,
379
+ hasResourceFormId = _ref2.hasResourceFormId,
380
+ currentStep = _ref2.currentStep,
381
+ stepList = _ref2.stepList,
382
+ appointmentBooking = _ref2.appointmentBooking,
383
+ locales = _ref2.locales,
384
+ isLogin = _ref2.isLogin,
385
+ openLoginModal = _ref2.openLoginModal,
386
+ isFormSubject = _ref2.isFormSubject,
387
+ utils = _ref2.utils,
388
+ accountLists = _ref2.accountLists,
389
+ getHolders = _ref2.getHolders;
390
+ // 验证资源是否挂接了表单
391
+ if (hasResourceFormId) {
392
+ var index = (currentStep === null || currentStep === void 0 ? void 0 : currentStep.index) + 1;
393
+ var description = locales.getText('pisell2.appointment.fill-form');
394
+
395
+ // 判断是否已经存在选择时间步骤
396
+ var isExist = stepList === null || stepList === void 0 ? void 0 : stepList.some(function (item) {
397
+ return (item === null || item === void 0 ? void 0 : item.key) === 'select-time';
398
+ });
399
+ appointmentBooking.addStep({
400
+ index: index,
401
+ key: 'fill-form',
402
+ description: description
403
+ }, isExist ? 'select-time' : undefined);
404
+ } else {
405
+ appointmentBooking.removeStep('fill-form');
406
+ }
407
+ var stepLists = appointmentBooking === null || appointmentBooking === void 0 || (_appointmentBooking$s = appointmentBooking.store) === null || _appointmentBooking$s === void 0 || (_appointmentBooking$s = _appointmentBooking$s.step) === null || _appointmentBooking$s === void 0 || (_appointmentBooking$s = _appointmentBooking$s.store) === null || _appointmentBooking$s === void 0 ? void 0 : _appointmentBooking$s.stepList;
408
+
409
+ // 如果当前是倒数第二步,则进行检测登录和账户信息
410
+ if ((currentStep === null || currentStep === void 0 ? void 0 : currentStep.index) + 2 === (stepLists === null || stepLists === void 0 ? void 0 : stepLists.length)) {
411
+ if (!isLogin) {
412
+ utils.action({
413
+ type: 'pisell1.login',
414
+ data: {
415
+ type: 'plugin'
416
+ },
417
+ callback: function callback(status) {
418
+ if (status === 'success') {
419
+ if (!isFormSubject) {
420
+ var _utils$storage2;
421
+ var user = JSON.parse((utils === null || utils === void 0 || (_utils$storage2 = utils.storage) === null || _utils$storage2 === void 0 ? void 0 : _utils$storage2.get('customer')) || '{}');
422
+ var currentUser = formatCustomer(user);
423
+ var meAccount = accountLists === null || accountLists === void 0 ? void 0 : accountLists.find(function (d) {
424
+ return !(d !== null && d !== void 0 && d.isGuest);
425
+ });
426
+ appointmentBooking.setLoginAccount(meAccount === null || meAccount === void 0 ? void 0 : meAccount.id, currentUser);
427
+ } else {
428
+ getHolders();
429
+ }
430
+
431
+ // 如果只有一个资源执行跳过
432
+ if (isSkip) {
433
+ appointmentBooking.next();
434
+ }
435
+ }
436
+ }
437
+ });
438
+ return true;
439
+ } else {
440
+ appointmentBooking.next();
441
+ }
442
+ var result = checkHolder({
443
+ isFormSubject: isFormSubject,
444
+ checkAccount: checkAccount,
445
+ carts: carts
446
+ });
447
+ if (result) {
448
+ setCarts(result);
449
+ }
450
+ if (!!result) return true;
451
+ } else {
452
+ // 如果只有一个资源执行跳过
453
+ if (isSkip) {
454
+ appointmentBooking.next();
455
+ }
456
+ }
457
+ console.log(appointmentBooking, appointmentBooking === null || appointmentBooking === void 0 || (_appointmentBooking$s2 = appointmentBooking.store) === null || _appointmentBooking$s2 === void 0 || (_appointmentBooking$s2 = _appointmentBooking$s2.step) === null || _appointmentBooking$s2 === void 0 || (_appointmentBooking$s2 = _appointmentBooking$s2.store) === null || _appointmentBooking$s2 === void 0 ? void 0 : _appointmentBooking$s2.stepList, currentStep, 'appointmentBooking444');
476
458
  };
@@ -4,6 +4,6 @@ declare const useSendModal: (bookingId?: number) => {
4
4
  setOpen: import("react").Dispatch<import("react").SetStateAction<boolean>>;
5
5
  handleOpen: () => void;
6
6
  handleValuesChange: (val: any) => void;
7
- handleOk: (values: SendModalValues) => Promise<boolean | undefined>;
7
+ handleOk: (values: SendModalValues) => Promise<any>;
8
8
  };
9
9
  export default useSendModal;
@@ -95,7 +95,7 @@ export var isBooking4Shop = function isBooking4Shop(shopId, renderType) {
95
95
  if (renderType === 'eventBooking') {
96
96
  return false;
97
97
  }
98
- var booking4Shops = [1350, 1401, 3013, 7154, 7572, 7007, 8119, 7320, 7362, 6497, 6087, 6303, 6726, 8191, 6812, 6813, 6814, 7651, 8586, 8581, 9, 2155, 8030, 1749, 8194];
98
+ var booking4Shops = [1350, 1401, 3013, 7154, 7572, 7007, 8119, 7320, 7362, 6497, 6087, 6303, 6726, 8191, 6812, 6813, 6814, 7651, 8586, 8581, 9, 2155, 8030, 1749, 8194, 2327];
99
99
  return booking4Shops.includes(shopId);
100
100
  };
101
101
  function generateDateRange(start, end) {
@@ -461,7 +461,8 @@ var TicketBooking = function TicketBooking() {
461
461
  persistent: state.persistent,
462
462
  list: state.list,
463
463
  intervalSetTime: state.intervalSetTime,
464
- createCount: state.createCount
464
+ createCount: state.createCount,
465
+ bookingFunctions: state.bookingFunctions
465
466
  });
466
467
 
467
468
  // 格式化
@@ -682,7 +683,8 @@ var TicketBooking = function TicketBooking() {
682
683
  disableEventBookingEdit: state.disableEventBookingEdit,
683
684
  list: state.list,
684
685
  intervalSetTime: state.intervalSetTime,
685
- createCount: state.createCount
686
+ createCount: state.createCount,
687
+ bookingFunctions: state.bookingFunctions
686
688
  })), {}, {
687
689
  loading: false,
688
690
  open: open !== null && open !== void 0 ? open : false,
@@ -1,8 +1,7 @@
1
1
  import React from 'react';
2
2
  import './index.less';
3
3
  interface ContinueButtonProps {
4
- onContinue?: () => void;
5
- onIsErrorResource?: (isError: boolean) => void;
4
+ onNext?: () => void;
6
5
  }
7
6
  declare const ContinueButton: React.FC<ContinueButtonProps>;
8
7
  export default ContinueButton;
@@ -38,17 +38,12 @@ var import_materials = require("@pisell/materials");
38
38
  var import_useEngineContext = __toESM(require("../../../../../hooks/useEngineContext"));
39
39
  var import_hooks = require("../../../hooks");
40
40
  var import_context = require("../../../context");
41
- var import_utils2 = require("../../../utils");
42
- var import_utils3 = require("../utils");
41
+ var import_utils2 = require("../utils");
43
42
  var import_index = require("./index.less");
44
- var ContinueButton = ({
45
- onContinue,
46
- onIsErrorResource
47
- }) => {
43
+ var ContinueButton = ({ onNext }) => {
48
44
  var _a, _b, _c;
49
45
  const context = (0, import_useEngineContext.default)();
50
46
  const utils = context.appHelper.utils || {};
51
- const [loading, setLoading] = (0, import_react.useState)(false);
52
47
  const { isLogin, openLoginModal } = (0, import_hooks.useAppointmentBookingLogin)();
53
48
  const { accountLists, getHolders, checkAccount } = (0, import_hooks.useAppointmentBookingAccount)();
54
49
  const shopDiscount = (0, import_hooks.useShopDiscount)();
@@ -56,19 +51,11 @@ var ContinueButton = ({
56
51
  currentStep,
57
52
  carts,
58
53
  appointmentBooking,
59
- resourceOtherParams,
60
- summary,
61
- isAgreeDepositPolicy,
62
- resources,
63
- setResourceOtherParams,
64
- stepParams,
65
- setCarts
54
+ setCarts,
55
+ loading,
56
+ setIsErrorHolder
66
57
  } = (0, import_context.useAppointmentBookingContext)();
67
- const { getResourceTimeSlot } = (0, import_hooks.useAppointmentBookingResource)();
68
- const { removeStep, addStep } = (0, import_hooks.useAppointmentBookingStep)();
69
- const { isFormSubject, formName } = (0, import_hooks.useAppointmentBookingSetting)();
70
- const appointmentBooking2 = (0, import_hooks.useAppointmentBooking)();
71
- const newCarts = (0, import_utils2.formatCarts)(carts, resources);
58
+ const { isFormSubject } = (0, import_hooks.useAppointmentBookingSetting)();
72
59
  const stepList = (0, import_react.useMemo)(() => {
73
60
  var _a2, _b2, _c2;
74
61
  return (_c2 = (_b2 = (_a2 = appointmentBooking == null ? void 0 : appointmentBooking.store) == null ? void 0 : _a2.step) == null ? void 0 : _b2.store) == null ? void 0 : _c2.stepList;
@@ -78,17 +65,8 @@ var ContinueButton = ({
78
65
  appointmentBooking.destroy();
79
66
  (_a2 = shopDiscount == null ? void 0 : shopDiscount.destroy) == null ? void 0 : _a2.call(shopDiscount);
80
67
  };
81
- const goPaymentFinish = (order_id, amount) => {
82
- var _a2;
83
- const url = `/payment-finish/success?order_id=${order_id}&amount=${Number(
84
- amount
85
- )}`;
86
- (_a2 = utils == null ? void 0 : utils.history) == null ? void 0 : _a2.replace(url);
87
- clearData();
88
- setLoading(false);
89
- };
90
68
  const handleCheckAccount = () => {
91
- const result = (0, import_utils3.checkHolder)({
69
+ const result = (0, import_utils2.checkHolder)({
92
70
  isFormSubject,
93
71
  checkAccount,
94
72
  carts
@@ -96,78 +74,11 @@ var ContinueButton = ({
96
74
  if (result) {
97
75
  setCarts(result);
98
76
  }
77
+ setIsErrorHolder(!!result);
99
78
  return !!result;
100
79
  };
101
- const handleCheckResource = () => {
102
- const result = (0, import_utils3.checkResource)({ carts, resources });
103
- if (result) {
104
- setCarts(result);
105
- }
106
- return !!result;
107
- };
108
- const handleNextStep = async () => {
109
- var _a2, _b2;
110
- console.log(
111
- currentStep,
112
- stepList,
113
- appointmentBooking == null ? void 0 : appointmentBooking.getCurrentStep(),
114
- appointmentBooking2 == null ? void 0 : appointmentBooking2.getCurrentStep(),
115
- (currentStep == null ? void 0 : currentStep.index) + 2 === (stepList == null ? void 0 : stepList.length),
116
- "whcurrentStepcurrentStep"
117
- );
118
- if ((currentStep == null ? void 0 : currentStep.index) + 2 === (stepList == null ? void 0 : stepList.length)) {
119
- const loginOk = await handleLoginCheck();
120
- if (!loginOk) return;
121
- if (handleCheckAccount()) return;
122
- }
123
- if ((currentStep == null ? void 0 : currentStep.index) + 1 >= (stepList == null ? void 0 : stepList.length)) {
124
- if (((_a2 = summary == null ? void 0 : summary.deposit) == null ? void 0 : _a2.hasDeposit) && !isAgreeDepositPolicy) {
125
- return (0, import_utils2.Toast)(
126
- import_utils.locales.getText("pisell2.appointment.deposit.agree.policy")
127
- );
128
- }
129
- const { deposit } = summary;
130
- setLoading(true);
131
- try {
132
- const { data } = await appointmentBooking.submitOrder();
133
- const { is_deposit, deposit_amount, total_amount, order_id } = data || {};
134
- const _total = is_deposit ? deposit_amount : total_amount;
135
- if (_total > 0) {
136
- utils.action({
137
- type: "pisell1.payment",
138
- data: { ...data, total_amount: _total }
139
- });
140
- setTimeout(() => {
141
- clearData();
142
- setLoading(false);
143
- }, 200);
144
- } else {
145
- if (deposit == null ? void 0 : deposit.hasDeposit) {
146
- goPaymentFinish(order_id, _total);
147
- return;
148
- }
149
- const freeResult = await appointmentBooking.getFreeProduct(order_id);
150
- console.log(freeResult, "freeResult");
151
- if (freeResult == null ? void 0 : freeResult.status) {
152
- goPaymentFinish(order_id, total_amount);
153
- } else {
154
- (0, import_utils2.Toast)(freeResult == null ? void 0 : freeResult.message);
155
- }
156
- }
157
- } catch (error) {
158
- setTimeout(() => {
159
- setLoading(false);
160
- }, 50);
161
- }
162
- return;
163
- }
164
- if (((_b2 = currentStep == null ? void 0 : currentStep.step) == null ? void 0 : _b2.key) === "select-resource") {
165
- getResourceTimeSlot();
166
- }
167
- return appointmentBooking.next();
168
- };
169
80
  const handleLoginCheck = async () => {
170
- return await (0, import_utils3.checkLogin)({
81
+ return await (0, import_utils2.checkLogin)({
171
82
  isLogin,
172
83
  openLoginModal,
173
84
  isFormSubject,
@@ -178,37 +89,13 @@ var ContinueButton = ({
178
89
  });
179
90
  };
180
91
  const handleContinue = async () => {
181
- var _a2;
182
92
  try {
183
- const key = (_a2 = currentStep == null ? void 0 : currentStep.step) == null ? void 0 : _a2.key;
184
- const index = (currentStep == null ? void 0 : currentStep.index) + 1;
185
93
  if ((currentStep == null ? void 0 : currentStep.index) + 2 === (stepList == null ? void 0 : stepList.length)) {
186
94
  const loginOk = await handleLoginCheck();
187
95
  if (!loginOk) return;
188
96
  if (handleCheckAccount()) return;
189
97
  }
190
- const selected = await appointmentBooking.getDateRange();
191
- (0, import_utils3.handleContinueStep)(key, {
192
- handleCheckResource,
193
- currentStep,
194
- hasResourceFormId: import_utils2.hasResourceFormId,
195
- addStep,
196
- removeStep,
197
- resourceOtherParams,
198
- setResourceOtherParams,
199
- newCarts,
200
- getResourceTimeSlot,
201
- appointmentBooking,
202
- summary,
203
- isAgreeDepositPolicy,
204
- setLoading,
205
- utils,
206
- clearData,
207
- goPaymentFinish,
208
- onContinue,
209
- onIsErrorResource,
210
- stepList
211
- });
98
+ return onNext && onNext();
212
99
  } catch (error) {
213
100
  console.log(error, "handleContinue_error");
214
101
  }
@@ -1,3 +1,3 @@
1
1
  import './index.less';
2
- declare const CartItem: ({ onContinue }: any) => JSX.Element;
2
+ declare const CartItem: ({ onNext }: any) => JSX.Element;
3
3
  export default CartItem;