@pisell/private-materials 3.3.88 → 3.3.90

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 (371) 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/index.js +1 -1
  5. package/build/lowcode/meta.js +1 -1
  6. package/build/lowcode/preview.js +8 -8
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +11 -11
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +11 -11
  11. package/es/businessModel/SalesModel/Sales/index.js +37 -4
  12. package/es/businessModel/SalesModel/index.d.ts +1 -0
  13. package/es/components/Sales/Cart/index.js +5 -1
  14. package/es/components/Sales/Cart/utils.d.ts +40 -0
  15. package/es/components/Sales/Cart/utils.js +167 -0
  16. package/es/components/Sales/Checkout/index.d.ts +4 -0
  17. package/es/components/Sales/Checkout/index.js +52 -8
  18. package/es/components/Sales/Checkout/serve.d.ts +13 -0
  19. package/es/components/Sales/Checkout/serve.js +16 -2
  20. package/es/components/Sales/Checkout/utils.js +7 -1
  21. package/es/components/Sales/Resource/index.js +2 -2
  22. package/es/components/Sales/Resource/serve.d.ts +7 -0
  23. package/es/components/Sales/Resource/serve.js +10 -0
  24. package/es/components/Sales/Summary/index.d.ts +10 -0
  25. package/es/components/Sales/Summary/index.js +17 -2
  26. package/es/components/Sales/Summary/serve.d.ts +1 -0
  27. package/es/components/Sales/Summary/serve.js +6 -0
  28. package/es/components/Sales/Summary/utils.d.ts +15 -0
  29. package/es/components/Sales/Summary/utils.js +43 -1
  30. package/es/components/appointmentBooking/components/Cart/Item/index.less +3 -3
  31. package/es/components/appointmentBooking/components/Content/index.less +1 -1
  32. package/es/components/appointmentBooking/components/Deposit/index.d.ts +6 -0
  33. package/es/components/appointmentBooking/components/Deposit/index.js +27 -7
  34. package/es/components/appointmentBooking/components/Footer/index.d.ts +1 -0
  35. package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +1 -0
  36. package/es/components/appointmentBooking/components/Services/index.js +23 -27
  37. package/es/components/appointmentBooking/deposit/components/PolicyModal/index.js +25 -20
  38. package/es/components/appointmentBooking/deposit/index.js +4 -2
  39. package/es/components/appointmentBooking/index.js +14 -0
  40. package/es/components/appointmentBooking/index.less +1 -1
  41. package/es/components/booking/components/TabProduct/index.d.ts +1 -0
  42. package/es/components/booking/components/footer/utils.d.ts +1 -0
  43. package/es/components/booking/components/footer/utils.js +1 -1
  44. package/es/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
  45. package/es/components/booking/components/voucher/index.js +2 -2
  46. package/es/components/booking/editBookingModal/index.d.ts +5 -0
  47. package/es/components/booking/editBookingModal/index.js +386 -0
  48. package/es/components/booking/editBookingModal/index.less +8 -0
  49. package/es/components/booking/editBookingModal/locales.d.ts +21 -0
  50. package/es/components/booking/editBookingModal/locales.js +20 -0
  51. package/es/components/booking/editBookingModal/mock.d.ts +807 -0
  52. package/es/components/booking/editBookingModal/mock.js +2993 -0
  53. package/es/components/booking/editBookingModal/serve.d.ts +51 -0
  54. package/es/components/booking/editBookingModal/serve.js +288 -0
  55. package/es/components/booking/editBookingModal/type.d.ts +12 -0
  56. package/es/components/booking/editBookingModal/type.js +1 -0
  57. package/es/components/booking/editBookingModal/utils.d.ts +12 -0
  58. package/es/components/booking/editBookingModal/utils.js +157 -0
  59. package/es/components/booking/forms/table/index.d.ts +1 -0
  60. package/es/components/booking/info/addServiceVariant/index.d.ts +1 -0
  61. package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
  62. package/es/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
  63. package/es/components/booking/info/index.d.ts +1 -0
  64. package/es/components/booking/info/service/like/index.d.ts +1 -0
  65. package/es/components/booking/info/service2/utils.js +3 -2
  66. package/es/components/booking/info2/service/addService/utils.d.ts +10 -0
  67. package/es/components/booking/info2/service/addService/utils.js +48 -14
  68. package/es/components/booking/info2/service/editService/Resources/index.js +22 -8
  69. package/es/components/booking/info2/service/editService/Resources/index.less +6 -0
  70. package/es/components/booking/info2/service/editService/ResourcesV2/MaxLengthSelect/index.d.ts +7 -0
  71. package/es/components/booking/info2/service/editService/ResourcesV2/MaxLengthSelect/index.js +26 -0
  72. package/es/components/booking/info2/service/editService/ResourcesV2/index.d.ts +10 -0
  73. package/es/components/booking/info2/service/editService/ResourcesV2/index.js +308 -0
  74. package/es/components/booking/info2/service/editService/ResourcesV2/index.less +44 -0
  75. package/es/components/booking/info2/utilsByBooking.js +9 -0
  76. package/es/components/booking/locales.d.ts +3 -0
  77. package/es/components/booking/locales.js +3 -0
  78. package/es/components/booking/materiels/holder/index.d.ts +1 -0
  79. package/es/components/eftpos/deviceList/index.d.ts +1 -0
  80. package/es/components/eftpos/form/index.d.ts +1 -0
  81. package/es/components/eftpos/group/index.d.ts +1 -0
  82. package/es/components/eftpos/hooks.d.ts +1 -0
  83. package/es/components/eftpos/icon/apiKey.d.ts +1 -0
  84. package/es/components/eftpos/icon/device.d.ts +1 -0
  85. package/es/components/eftpos/receipt/index.d.ts +1 -0
  86. package/es/components/eftpos/surcharge/index.d.ts +1 -0
  87. package/es/components/eftposPay/component/alert/warn.d.ts +1 -0
  88. package/es/components/eftposPay/component/header/titlebar.d.ts +1 -0
  89. package/es/components/eftposPay/component/step/index.d.ts +1 -0
  90. package/es/components/eftposPay/component/step/step.d.ts +1 -0
  91. package/es/components/eftposPay/const.d.ts +4 -1
  92. package/es/components/eftposPay/const.js +3 -1
  93. package/es/components/eftposPay/hooks.d.ts +1 -1
  94. package/es/components/eftposPay/hooks.js +3 -1
  95. package/es/components/eftposPay/index.js +1 -1
  96. package/es/components/eftposPay/linkly/const.d.ts +23 -0
  97. package/es/components/eftposPay/linkly/const.js +82 -0
  98. package/es/components/eftposPay/linkly/hooks/index.d.ts +2 -0
  99. package/es/components/eftposPay/linkly/hooks/index.js +2 -0
  100. package/es/components/eftposPay/linkly/hooks/normal.d.ts +30 -0
  101. package/es/components/eftposPay/linkly/hooks/normal.js +318 -0
  102. package/es/components/eftposPay/linkly/hooks/useTimeQuery.d.ts +4 -0
  103. package/es/components/eftposPay/linkly/hooks/useTimeQuery.js +273 -0
  104. package/es/components/eftposPay/linkly/index.d.ts +2 -0
  105. package/es/components/eftposPay/linkly/index.js +197 -0
  106. package/es/components/eftposPay/linkly/service.d.ts +32 -0
  107. package/es/components/eftposPay/linkly/service.js +73 -0
  108. package/es/components/eftposPay/manufacturer.d.ts +1 -0
  109. package/es/components/eftposPay/manufacturer.js +4 -0
  110. package/es/components/eftposPay/pay.d.ts +1 -1
  111. package/es/components/eftposPay/pay.js +6 -2
  112. package/es/components/eftposPay/store/index.d.ts +1 -1
  113. package/es/components/eftposPay/tyro/hooks.d.ts +1 -0
  114. package/es/components/eftposPay/windcave/windcave.js +12 -2
  115. package/es/components/eventBooking/components/ErrorTip/index.d.ts +1 -0
  116. package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +29 -17
  117. package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +3 -0
  118. package/es/components/eventBooking/components/Provider/Cart/Deposit/index.js +17 -0
  119. package/es/components/eventBooking/components/Provider/Cart/Item/Total.js +10 -6
  120. package/es/components/eventBooking/components/Provider/Cart/Item/index.js +4 -2
  121. package/es/components/eventBooking/components/Provider/Event/index.js +13 -4
  122. package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +1 -0
  123. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
  124. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +1 -0
  125. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +1 -0
  126. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +1 -0
  127. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
  128. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
  129. package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
  130. package/es/components/eventBooking/components/bookingDetailModal/index.js +22 -4
  131. package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +1 -0
  132. package/es/components/eventBooking/index.js +21 -7
  133. package/es/components/eventBooking/locales.d.ts +24 -0
  134. package/es/components/eventBooking/locales.js +30 -6
  135. package/es/components/index.d.ts +3 -1
  136. package/es/components/index.js +3 -1
  137. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +1 -0
  138. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +1 -0
  139. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
  140. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +1 -0
  141. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +1 -0
  142. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +1 -0
  143. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
  144. package/es/components/pay/toC/PaymentMethods/index.js +5 -4
  145. package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +1 -0
  146. package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +1 -0
  147. package/es/components/productExtension/fields/Actor/index.d.ts +1 -0
  148. package/es/components/productExtension/fields/Forms/index.d.ts +1 -0
  149. package/es/components/schedules/calendar/calendarItem.d.ts +1 -0
  150. package/es/components/schedules/components/CurrentDay/index.d.ts +1 -0
  151. package/es/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +1 -0
  152. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
  153. package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
  154. package/es/components/schedules/products/index.d.ts +1 -0
  155. package/es/components/schedules/resources/relationProduct/index.d.ts +1 -0
  156. package/es/components/shoppingCart/components/Empty/index.d.ts +1 -0
  157. package/es/components/shoppingCart/components/Render/index.d.ts +1 -0
  158. package/es/components/stepController/components/Content/index.d.ts +7 -0
  159. package/es/components/stepController/components/Content/index.js +9 -0
  160. package/es/components/stepController/components/Content/index.less +8 -0
  161. package/es/components/stepController/components/Footer/index.d.ts +8 -0
  162. package/es/components/stepController/components/Footer/index.js +15 -0
  163. package/es/components/stepController/components/Footer/index.less +39 -0
  164. package/es/components/stepController/components/Header/index.d.ts +20 -0
  165. package/es/components/stepController/components/Header/index.js +97 -0
  166. package/es/components/stepController/components/Header/index.less +21 -0
  167. package/es/components/stepController/index.d.ts +5 -0
  168. package/es/components/stepController/index.js +64 -0
  169. package/es/components/stepController/index.less +11 -0
  170. package/es/components/stepController/locales.d.ts +27 -0
  171. package/es/components/stepController/locales.js +32 -0
  172. package/es/components/stepController/types.d.ts +23 -0
  173. package/es/components/stepController/types.js +1 -0
  174. package/es/components/ticketBooking/components/addServiceVariant/addService.js +1 -1
  175. package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +1 -0
  176. package/es/components/ticketBooking/components/menuBar/index.d.ts +1 -0
  177. package/es/components/ticketBooking/components/ticketBooking/index.d.ts +1 -0
  178. package/es/components/ticketBooking/components/ticketBooking/index.js +257 -138
  179. package/es/components/ticketBooking/locales.d.ts +164 -146
  180. package/es/components/ticketBooking/locales.js +195 -147
  181. package/es/components/ticketBooking/utils/formatProductMessage.d.ts +2 -0
  182. package/es/components/ticketBooking/utils/formatProductMessage.js +62 -0
  183. package/es/components/ticketBooking/utils/formatTime.d.ts +31 -0
  184. package/es/components/ticketBooking/utils/formatTime.js +144 -0
  185. package/es/components/workSpaceList/components/Modal/index.d.ts +1 -0
  186. package/es/hooks/useWindowSize.d.ts +5 -0
  187. package/es/hooks/useWindowSize.js +26 -0
  188. package/es/index.d.ts +2 -0
  189. package/es/index.js +3 -1
  190. package/lib/businessModel/SalesModel/Sales/index.js +22 -8
  191. package/lib/businessModel/SalesModel/index.d.ts +1 -0
  192. package/lib/components/Sales/Cart/index.js +1 -0
  193. package/lib/components/Sales/Cart/utils.d.ts +40 -0
  194. package/lib/components/Sales/Cart/utils.js +117 -0
  195. package/lib/components/Sales/Checkout/index.d.ts +4 -0
  196. package/lib/components/Sales/Checkout/index.js +39 -7
  197. package/lib/components/Sales/Checkout/serve.d.ts +13 -0
  198. package/lib/components/Sales/Checkout/serve.js +7 -2
  199. package/lib/components/Sales/Checkout/utils.js +2 -0
  200. package/lib/components/Sales/Resource/index.js +1 -1
  201. package/lib/components/Sales/Resource/serve.d.ts +7 -0
  202. package/lib/components/Sales/Resource/serve.js +9 -2
  203. package/lib/components/Sales/Summary/index.d.ts +10 -0
  204. package/lib/components/Sales/Summary/index.js +7 -1
  205. package/lib/components/Sales/Summary/serve.d.ts +1 -0
  206. package/lib/components/Sales/Summary/serve.js +32 -0
  207. package/lib/components/Sales/Summary/utils.d.ts +15 -0
  208. package/lib/components/Sales/Summary/utils.js +30 -1
  209. package/lib/components/appointmentBooking/components/Cart/Item/index.less +3 -3
  210. package/lib/components/appointmentBooking/components/Content/index.less +1 -1
  211. package/lib/components/appointmentBooking/components/Deposit/index.d.ts +6 -0
  212. package/lib/components/appointmentBooking/components/Deposit/index.js +36 -4
  213. package/lib/components/appointmentBooking/components/Footer/index.d.ts +1 -0
  214. package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +1 -0
  215. package/lib/components/appointmentBooking/components/Services/index.js +6 -11
  216. package/lib/components/appointmentBooking/deposit/components/PolicyModal/index.js +8 -4
  217. package/lib/components/appointmentBooking/deposit/index.js +4 -2
  218. package/lib/components/appointmentBooking/index.js +11 -0
  219. package/lib/components/appointmentBooking/index.less +1 -1
  220. package/lib/components/booking/components/TabProduct/index.d.ts +1 -0
  221. package/lib/components/booking/components/footer/utils.d.ts +1 -0
  222. package/lib/components/booking/components/footer/utils.js +2 -0
  223. package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
  224. package/lib/components/booking/components/voucher/index.js +2 -2
  225. package/lib/components/booking/editBookingModal/index.d.ts +5 -0
  226. package/lib/components/booking/editBookingModal/index.js +363 -0
  227. package/lib/components/booking/editBookingModal/index.less +8 -0
  228. package/lib/components/booking/editBookingModal/locales.d.ts +21 -0
  229. package/lib/components/booking/editBookingModal/locales.js +44 -0
  230. package/lib/components/booking/editBookingModal/mock.d.ts +807 -0
  231. package/lib/components/booking/editBookingModal/mock.js +3314 -0
  232. package/lib/components/booking/editBookingModal/serve.d.ts +51 -0
  233. package/lib/components/booking/editBookingModal/serve.js +178 -0
  234. package/lib/components/booking/editBookingModal/type.d.ts +12 -0
  235. package/lib/components/booking/editBookingModal/type.js +17 -0
  236. package/lib/components/booking/editBookingModal/utils.d.ts +12 -0
  237. package/lib/components/booking/editBookingModal/utils.js +158 -0
  238. package/lib/components/booking/forms/table/index.d.ts +1 -0
  239. package/lib/components/booking/info/addServiceVariant/index.d.ts +1 -0
  240. package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
  241. package/lib/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
  242. package/lib/components/booking/info/index.d.ts +1 -0
  243. package/lib/components/booking/info/service/like/index.d.ts +1 -0
  244. package/lib/components/booking/info/service2/utils.js +2 -2
  245. package/lib/components/booking/info2/service/addService/utils.d.ts +10 -0
  246. package/lib/components/booking/info2/service/addService/utils.js +32 -5
  247. package/lib/components/booking/info2/service/editService/Resources/index.js +54 -10
  248. package/lib/components/booking/info2/service/editService/Resources/index.less +6 -0
  249. package/lib/components/booking/info2/service/editService/ResourcesV2/MaxLengthSelect/index.d.ts +7 -0
  250. package/lib/components/booking/info2/service/editService/ResourcesV2/MaxLengthSelect/index.js +53 -0
  251. package/lib/components/booking/info2/service/editService/ResourcesV2/index.d.ts +10 -0
  252. package/lib/components/booking/info2/service/editService/ResourcesV2/index.js +311 -0
  253. package/lib/components/booking/info2/service/editService/ResourcesV2/index.less +44 -0
  254. package/lib/components/booking/info2/utilsByBooking.js +6 -0
  255. package/lib/components/booking/locales.d.ts +3 -0
  256. package/lib/components/booking/locales.js +3 -0
  257. package/lib/components/booking/materiels/holder/index.d.ts +1 -0
  258. package/lib/components/eftpos/deviceList/index.d.ts +1 -0
  259. package/lib/components/eftpos/form/index.d.ts +1 -0
  260. package/lib/components/eftpos/group/index.d.ts +1 -0
  261. package/lib/components/eftpos/hooks.d.ts +1 -0
  262. package/lib/components/eftpos/icon/apiKey.d.ts +1 -0
  263. package/lib/components/eftpos/icon/device.d.ts +1 -0
  264. package/lib/components/eftpos/receipt/index.d.ts +1 -0
  265. package/lib/components/eftpos/surcharge/index.d.ts +1 -0
  266. package/lib/components/eftposPay/component/alert/warn.d.ts +1 -0
  267. package/lib/components/eftposPay/component/header/titlebar.d.ts +1 -0
  268. package/lib/components/eftposPay/component/step/index.d.ts +1 -0
  269. package/lib/components/eftposPay/component/step/step.d.ts +1 -0
  270. package/lib/components/eftposPay/const.d.ts +4 -1
  271. package/lib/components/eftposPay/const.js +2 -0
  272. package/lib/components/eftposPay/hooks.d.ts +1 -1
  273. package/lib/components/eftposPay/hooks.js +11 -4
  274. package/lib/components/eftposPay/index.js +1 -1
  275. package/lib/components/eftposPay/linkly/const.d.ts +23 -0
  276. package/lib/components/eftposPay/linkly/const.js +102 -0
  277. package/lib/components/eftposPay/linkly/hooks/index.d.ts +2 -0
  278. package/lib/components/eftposPay/linkly/hooks/index.js +25 -0
  279. package/lib/components/eftposPay/linkly/hooks/normal.d.ts +30 -0
  280. package/lib/components/eftposPay/linkly/hooks/normal.js +239 -0
  281. package/lib/components/eftposPay/linkly/hooks/useTimeQuery.d.ts +4 -0
  282. package/lib/components/eftposPay/linkly/hooks/useTimeQuery.js +222 -0
  283. package/lib/components/eftposPay/linkly/index.d.ts +2 -0
  284. package/lib/components/eftposPay/linkly/index.js +208 -0
  285. package/lib/components/eftposPay/linkly/service.d.ts +32 -0
  286. package/lib/components/eftposPay/linkly/service.js +55 -0
  287. package/lib/components/eftposPay/manufacturer.d.ts +1 -0
  288. package/lib/components/eftposPay/manufacturer.js +6 -0
  289. package/lib/components/eftposPay/pay.d.ts +1 -1
  290. package/lib/components/eftposPay/pay.js +13 -2
  291. package/lib/components/eftposPay/store/index.d.ts +1 -1
  292. package/lib/components/eftposPay/tyro/hooks.d.ts +1 -0
  293. package/lib/components/eftposPay/windcave/windcave.js +11 -0
  294. package/lib/components/eventBooking/components/ErrorTip/index.d.ts +1 -0
  295. package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +16 -3
  296. package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +3 -0
  297. package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.js +55 -0
  298. package/lib/components/eventBooking/components/Provider/Cart/Item/Total.js +8 -5
  299. package/lib/components/eventBooking/components/Provider/Cart/Item/index.js +4 -2
  300. package/lib/components/eventBooking/components/Provider/Event/index.js +10 -3
  301. package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +1 -0
  302. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
  303. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +1 -0
  304. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +1 -0
  305. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +1 -0
  306. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
  307. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
  308. package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
  309. package/lib/components/eventBooking/components/bookingDetailModal/index.js +10 -4
  310. package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +1 -0
  311. package/lib/components/eventBooking/index.js +11 -7
  312. package/lib/components/eventBooking/locales.d.ts +24 -0
  313. package/lib/components/eventBooking/locales.js +30 -6
  314. package/lib/components/index.d.ts +3 -1
  315. package/lib/components/index.js +6 -0
  316. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +1 -0
  317. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +1 -0
  318. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
  319. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +1 -0
  320. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +1 -0
  321. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +1 -0
  322. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
  323. package/lib/components/pay/toC/PaymentMethods/index.js +10 -9
  324. package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +1 -0
  325. package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +1 -0
  326. package/lib/components/productExtension/fields/Actor/index.d.ts +1 -0
  327. package/lib/components/productExtension/fields/Forms/index.d.ts +1 -0
  328. package/lib/components/schedules/calendar/calendarItem.d.ts +1 -0
  329. package/lib/components/schedules/components/CurrentDay/index.d.ts +1 -0
  330. package/lib/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +1 -0
  331. package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
  332. package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
  333. package/lib/components/schedules/products/index.d.ts +1 -0
  334. package/lib/components/schedules/resources/relationProduct/index.d.ts +1 -0
  335. package/lib/components/shoppingCart/components/Empty/index.d.ts +1 -0
  336. package/lib/components/shoppingCart/components/Render/index.d.ts +1 -0
  337. package/lib/components/stepController/components/Content/index.d.ts +7 -0
  338. package/lib/components/stepController/components/Content/index.js +40 -0
  339. package/lib/components/stepController/components/Content/index.less +8 -0
  340. package/lib/components/stepController/components/Footer/index.d.ts +8 -0
  341. package/lib/components/stepController/components/Footer/index.js +49 -0
  342. package/lib/components/stepController/components/Footer/index.less +39 -0
  343. package/lib/components/stepController/components/Header/index.d.ts +20 -0
  344. package/lib/components/stepController/components/Header/index.js +104 -0
  345. package/lib/components/stepController/components/Header/index.less +21 -0
  346. package/lib/components/stepController/index.d.ts +5 -0
  347. package/lib/components/stepController/index.js +89 -0
  348. package/lib/components/stepController/index.less +11 -0
  349. package/lib/components/stepController/locales.d.ts +27 -0
  350. package/lib/components/stepController/locales.js +50 -0
  351. package/lib/components/stepController/types.d.ts +23 -0
  352. package/lib/components/stepController/types.js +17 -0
  353. package/lib/components/ticketBooking/components/addServiceVariant/addService.js +1 -1
  354. package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +1 -0
  355. package/lib/components/ticketBooking/components/menuBar/index.d.ts +1 -0
  356. package/lib/components/ticketBooking/components/ticketBooking/index.d.ts +1 -0
  357. package/lib/components/ticketBooking/components/ticketBooking/index.js +263 -139
  358. package/lib/components/ticketBooking/locales.d.ts +164 -146
  359. package/lib/components/ticketBooking/locales.js +22 -4
  360. package/lib/components/ticketBooking/utils/formatProductMessage.d.ts +2 -0
  361. package/lib/components/ticketBooking/utils/formatProductMessage.js +84 -0
  362. package/lib/components/ticketBooking/utils/formatTime.d.ts +31 -0
  363. package/lib/components/ticketBooking/utils/formatTime.js +139 -0
  364. package/lib/components/workSpaceList/components/Modal/index.d.ts +1 -0
  365. package/lib/hooks/useWindowSize.d.ts +5 -0
  366. package/lib/hooks/useWindowSize.js +51 -0
  367. package/lib/index.d.ts +2 -0
  368. package/lib/index.js +6 -0
  369. package/lowcode/edit-booking-modal/meta.ts +53 -0
  370. package/lowcode/step-controller/meta.ts +88 -0
  371. package/package.json +4 -4
@@ -1,22 +1,23 @@
1
- var _excluded = ["detail", "product"];
2
1
  var _this = this;
3
- function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
4
- function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
2
+ var _excluded = ["detail", "product"];
5
3
  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); }
6
4
  function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
7
5
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
8
6
  function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
9
- 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
- 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
- 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
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
13
- 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); }
7
+ 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; } } }; }
14
8
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
15
9
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
16
10
  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); }
17
11
  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; }
18
12
  function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
19
13
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
14
+ 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; }
15
+ 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; }
16
+ 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; }
17
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
18
+ 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); }
19
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
20
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
20
21
  import React, { useEffect, useRef } from 'react';
21
22
  import { locales } from '@pisell/utils';
22
23
  import { message } from 'antd';
@@ -30,6 +31,138 @@ import { formatDateToStr, getNextTimeSlice, getDisabledEdit, restoreProductOther
30
31
  import AddServiceVariant from "../addServiceVariant";
31
32
  import TimeBar from "../timeBar";
32
33
  import "./index.less";
34
+ import { formatProducts } from "../../../booking/info/service2/utils";
35
+ import { getSumTotal } from "../../../booking/components/footer/amount";
36
+ import formatProductMessage from "../../utils/formatProductMessage";
37
+ export var _formatBookingDetail = function _formatBookingDetail(data, modalState) {
38
+ var _bookings$list, _bookings$list2;
39
+ var customer_id = data.customer_id,
40
+ holder = data.holder,
41
+ customer_name = data.customer_name,
42
+ email = data.email,
43
+ phone = data.phone,
44
+ country_calling_code = data.country_calling_code,
45
+ bookings = data.bookings,
46
+ customer = data.customer,
47
+ note = data.note,
48
+ payment_status = data.payment_status,
49
+ is_other_entrance_edited = data.is_other_entrance_edited,
50
+ shop_discount = data.shop_discount;
51
+ var clientValue = {
52
+ name: ((customer === null || customer === void 0 ? void 0 : customer.display_name) || '').trim() || ((customer === null || customer === void 0 ? void 0 : customer.nickname) || '').trim() || '',
53
+ id: customer_id || (customer === null || customer === void 0 ? void 0 : customer.id) || (customer === null || customer === void 0 ? void 0 : customer.customer_id) || 1,
54
+ email: customer === null || customer === void 0 ? void 0 : customer.email,
55
+ phone: (customer === null || customer === void 0 ? void 0 : customer.phone) || '',
56
+ country_calling_code: (customer === null || customer === void 0 ? void 0 : customer.country_calling_code) || '',
57
+ cover: (customer === null || customer === void 0 ? void 0 : customer.cover) || ''
58
+ };
59
+ var start_date = bookings === null || bookings === void 0 || (_bookings$list = bookings.list) === null || _bookings$list === void 0 || (_bookings$list = _bookings$list[0]) === null || _bookings$list === void 0 ? void 0 : _bookings$list.start_date;
60
+ var dateValue = dayjs(start_date ? start_date + ' ' + (bookings === null || bookings === void 0 || (_bookings$list2 = bookings.list) === null || _bookings$list2 === void 0 || (_bookings$list2 = _bookings$list2[0]) === null || _bookings$list2 === void 0 ? void 0 : _bookings$list2.start_time) : new Date());
61
+ var petsValue = holder;
62
+ var getCapacity = function getCapacity(resetD) {
63
+ var _resetD$metadata;
64
+ return (_resetD$metadata = resetD.metadata) === null || _resetD$metadata === void 0 ? void 0 : _resetD$metadata.capacity;
65
+ };
66
+ var getResource = function getResource(resetD) {
67
+ if (!bookings.relation_type) {
68
+ try {
69
+ var _resetD$event_resourc;
70
+ if (resetD !== null && resetD !== void 0 && resetD.event_resources && resetD !== null && resetD !== void 0 && (_resetD$event_resourc = resetD.event_resources) !== null && _resetD$event_resourc !== void 0 && _resetD$event_resourc.length) {
71
+ return resetD.event_resources.reduce(function (pre, cur) {
72
+ if (pre[cur.form_id]) {
73
+ pre[cur.form_id].push(cur);
74
+ } else {
75
+ pre[cur.form_id] = [cur];
76
+ }
77
+ return pre;
78
+ }, {});
79
+ }
80
+ } catch (err) {
81
+ console.error(err);
82
+ }
83
+ }
84
+ return resetD.relation_id;
85
+ };
86
+ var serviceValue = bookings.list.map(function (d) {
87
+ var detail = d.detail,
88
+ product = d.product,
89
+ resetD = _objectWithoutProperties(d, _excluded);
90
+ var _detail = detail || mockProduct;
91
+ var start_date = dayjs(resetD.start_date + ' ' + resetD.start_time);
92
+ var end_date = dayjs(resetD.end_date + ' ' + resetD.end_time);
93
+ return _objectSpread(_objectSpread({
94
+ _id: (Math.random() + '').replace(/\D/g, '').substring(0, 11)
95
+ }, _detail), {}, {
96
+ booking_id: resetD.id,
97
+ id: _detail.product_id,
98
+ title: _detail.product_title,
99
+ quantity: Number(_detail.product_quantity),
100
+ cover: _detail.product_cover,
101
+ // 商品本身的价格
102
+ price: Number(_detail.source_product_price),
103
+ relation_form_name: resetD.relation_form_name,
104
+ product_resource: product === null || product === void 0 ? void 0 : product.product_resource,
105
+ capacity: product === null || product === void 0 ? void 0 : product.capacity,
106
+ _extend: _objectSpread(_objectSpread({}, resetD), {}, {
107
+ quantity: Number(_detail.product_quantity),
108
+ startDate: start_date,
109
+ start_date: start_date,
110
+ endDate: end_date,
111
+ end_date: end_date,
112
+ // 商品本身的价格
113
+ price: Number(_detail.source_product_price),
114
+ product_name: _detail.product_title,
115
+ discount_reason: _detail.product_discount_reason,
116
+ // resource: resetD.relation_id,
117
+ order_detail_id: _detail.order_detail_id,
118
+ // 总价: 商品本身价格 + 套餐价格 + 单规格价格 包含折扣
119
+ total: Number(_detail.selling_price),
120
+ // 原总价: 商品本身价格 + 套餐价格 + 单规格价格 不包含折扣
121
+ origin_total: Number(_detail.original_price),
122
+ payment_price: Number(_detail.payment_price),
123
+ other: restoreProductOtherData(d),
124
+ // 是否编辑了套餐 默认为0 如果编辑之后为1
125
+ bundle_edit: 0,
126
+ discount_per: _detail.discount_per,
127
+ discount_type: _detail.discount_type,
128
+ discountway: _detail.discountway,
129
+ capacity: getCapacity(resetD),
130
+ resource: getResource(resetD)
131
+ })
132
+ });
133
+ });
134
+ var disabledEdit = getDisabledEdit(data);
135
+ var channelDisabledEdit = !!is_other_entrance_edited;
136
+ return _objectSpread(_objectSpread({}, modalState), {}, {
137
+ client: _objectSpread(_objectSpread({}, modalState.client), {}, {
138
+ value: clientValue,
139
+ edit: false,
140
+ showModal: false
141
+ }),
142
+ date: _objectSpread(_objectSpread({}, modalState.date), {}, {
143
+ value: dateValue,
144
+ edit: false,
145
+ showModal: false
146
+ }),
147
+ pet: _objectSpread(_objectSpread({}, modalState.pet), {}, {
148
+ showModal: false,
149
+ edit: false
150
+ }),
151
+ service: _objectSpread(_objectSpread({}, modalState.service), {}, {
152
+ value: serviceValue,
153
+ addModal: false,
154
+ editModal: false,
155
+ edit: false
156
+ }),
157
+ notes: _objectSpread(_objectSpread({}, modalState.notes), {}, {
158
+ orderNote: note,
159
+ edit: false
160
+ }),
161
+ disabledEdit: disabledEdit,
162
+ channelDisabledEdit: channelDisabledEdit,
163
+ appointment_status: bookings === null || bookings === void 0 ? void 0 : bookings.appointment_status
164
+ });
165
+ };
33
166
  var TicketBooking = function TicketBooking() {
34
167
  var _engineContext$appHel2;
35
168
  var _useStore = useStore(),
@@ -45,7 +178,9 @@ var TicketBooking = function TicketBooking() {
45
178
  interaction = _engineContext$appHel.interaction,
46
179
  store = _engineContext$appHel.store,
47
180
  storage = _engineContext$appHel.storage,
48
- Toast = _engineContext$appHel.Toast;
181
+ Toast = _engineContext$appHel.Toast,
182
+ getSymbolic = _engineContext$appHel.getSymbolic,
183
+ translation = _engineContext$appHel.translation;
49
184
  var _persistentRef = useRef(false);
50
185
  var _initStateRef = useRef({});
51
186
  var _listTimerRef = useRef();
@@ -125,6 +260,119 @@ var TicketBooking = function TicketBooking() {
125
260
  });
126
261
  };
127
262
 
263
+ // 商品加购信息发生变化时,需要发送至native端
264
+ useEffect(function () {
265
+ var _state$modalState, _locales$getText, _interaction$utils5, _interaction$utils5$p;
266
+ var cartItems = state === null || state === void 0 || (_state$modalState = state.modalState) === null || _state$modalState === void 0 || (_state$modalState = _state$modalState.service) === null || _state$modalState === void 0 ? void 0 : _state$modalState.value;
267
+ if (!Array.isArray(cartItems) || cartItems.length === 0) {
268
+ var _interaction$utils4, _interaction$utils4$p;
269
+ interaction === null || interaction === void 0 || (_interaction$utils4 = interaction.utils) === null || _interaction$utils4 === void 0 || (_interaction$utils4$p = _interaction$utils4.postMessageToApp) === null || _interaction$utils4$p === void 0 || _interaction$utils4$p.call(_interaction$utils4, {
270
+ module: 'cds',
271
+ key: 'cartUpdate',
272
+ data: {
273
+ currency_symbol: getSymbolic(),
274
+ total: '0',
275
+ // 小计
276
+ products: [],
277
+ fees: []
278
+ }
279
+ });
280
+ }
281
+ var total = getSumTotal(state.modalState, true);
282
+ var formatedProducts = [];
283
+ try {
284
+ formatedProducts = formatProducts(cartItems, state.modalState, false, true, true);
285
+ } catch (error) {
286
+ console.error(error);
287
+ }
288
+ console.log('formatedProducts', total, formatedProducts);
289
+ var fees = [];
290
+ var products = [];
291
+ var _iterator = _createForOfIteratorHelper(formatedProducts),
292
+ _step;
293
+ try {
294
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
295
+ var _origin$discount_list;
296
+ var item = _step.value;
297
+ var id = item.id,
298
+ name = item.name,
299
+ image = item.image,
300
+ origin_total = item.origin_total,
301
+ _total = item.total,
302
+ num = item.num,
303
+ note = item.note,
304
+ _origin = item._origin;
305
+ _origin === null || _origin === void 0 || (_origin$discount_list = _origin.discount_list) === null || _origin$discount_list === void 0 || _origin$discount_list.forEach(function (dl) {
306
+ fees.push({
307
+ isReduce: dl.type === 'good_pass',
308
+ title: translation(dl === null || dl === void 0 ? void 0 : dl.discount.title),
309
+ price: dl.amount,
310
+ type: dl.type
311
+ });
312
+ });
313
+ var msg = '';
314
+ try {
315
+ var _engineContext$appHel3;
316
+ msg = formatProductMessage(_objectSpread(_objectSpread({}, item), {}, {
317
+ currency_symbol: getSymbolic()
318
+ }), (_engineContext$appHel3 = engineContext.appHelper) === null || _engineContext$appHel3 === void 0 ? void 0 : _engineContext$appHel3.utils);
319
+ } catch (error) {
320
+ console.error(error);
321
+ }
322
+ var _item = {
323
+ productID: id,
324
+ title: name,
325
+ cover: image,
326
+ // 封面图
327
+ price: _total,
328
+ // 售价
329
+ buyCount: num,
330
+ // 购买数量
331
+ productFormatMessage: msg,
332
+ note: note
333
+ };
334
+ if (origin_total !== _total) _item.modifyPrice = origin_total; //原价, 注意字段名反了
335
+ products.push(_item);
336
+ }
337
+ } catch (err) {
338
+ _iterator.e(err);
339
+ } finally {
340
+ _iterator.f();
341
+ }
342
+ console.log('formatedProducts', (_locales$getText = locales.getText('pisell2.product.card.cart-items')) === null || _locales$getText === void 0 ? void 0 : _locales$getText(products.length));
343
+ if (products.length > 0) {
344
+ var _locales$getText2;
345
+ fees.unshift({
346
+ title: locales.getText('pisell2.product.card.subtotal'),
347
+ price: total.productAmount,
348
+ type: 'subtotal',
349
+ message: (_locales$getText2 = locales.getText('pisell2.product.card.cart-items')) === null || _locales$getText2 === void 0 ? void 0 : _locales$getText2(products.length)
350
+ });
351
+ }
352
+ console.log('start post message, config:', {
353
+ module: 'cds',
354
+ key: 'cartUpdate',
355
+ data: {
356
+ currency_symbol: getSymbolic(),
357
+ total: total.productAmount,
358
+ // 小计
359
+ products: products,
360
+ fees: fees
361
+ }
362
+ });
363
+ interaction === null || interaction === void 0 || (_interaction$utils5 = interaction.utils) === null || _interaction$utils5 === void 0 || (_interaction$utils5$p = _interaction$utils5.postMessageToApp) === null || _interaction$utils5$p === void 0 || _interaction$utils5$p.call(_interaction$utils5, {
364
+ module: 'cds',
365
+ key: 'cartUpdate',
366
+ data: {
367
+ currency_symbol: getSymbolic(),
368
+ total: total.expectAmount,
369
+ // 小计
370
+ products: products,
371
+ fees: fees
372
+ }
373
+ });
374
+ }, [state.modalState]);
375
+
128
376
  /**
129
377
  * 设置弹窗内的状态
130
378
  */
@@ -318,135 +566,6 @@ var TicketBooking = function TicketBooking() {
318
566
  });
319
567
  }
320
568
  };
321
- var _formatBookingDetail = function _formatBookingDetail(data, modalState) {
322
- var _bookings$list, _bookings$list2;
323
- var customer_id = data.customer_id,
324
- holder = data.holder,
325
- customer_name = data.customer_name,
326
- email = data.email,
327
- phone = data.phone,
328
- country_calling_code = data.country_calling_code,
329
- bookings = data.bookings,
330
- customer = data.customer,
331
- note = data.note,
332
- payment_status = data.payment_status,
333
- is_other_entrance_edited = data.is_other_entrance_edited,
334
- shop_discount = data.shop_discount;
335
- var clientValue = {
336
- name: ((customer === null || customer === void 0 ? void 0 : customer.display_name) || '').trim() || ((customer === null || customer === void 0 ? void 0 : customer.nickname) || '').trim() || '',
337
- id: customer_id || (customer === null || customer === void 0 ? void 0 : customer.id) || (customer === null || customer === void 0 ? void 0 : customer.customer_id) || 1,
338
- email: customer === null || customer === void 0 ? void 0 : customer.email,
339
- phone: (customer === null || customer === void 0 ? void 0 : customer.phone) || '',
340
- country_calling_code: (customer === null || customer === void 0 ? void 0 : customer.country_calling_code) || '',
341
- cover: (customer === null || customer === void 0 ? void 0 : customer.cover) || ''
342
- };
343
- var start_date = bookings === null || bookings === void 0 || (_bookings$list = bookings.list) === null || _bookings$list === void 0 || (_bookings$list = _bookings$list[0]) === null || _bookings$list === void 0 ? void 0 : _bookings$list.start_date;
344
- var dateValue = dayjs(start_date ? start_date + ' ' + (bookings === null || bookings === void 0 || (_bookings$list2 = bookings.list) === null || _bookings$list2 === void 0 || (_bookings$list2 = _bookings$list2[0]) === null || _bookings$list2 === void 0 ? void 0 : _bookings$list2.start_time) : new Date());
345
- var petsValue = holder;
346
- var getCapacity = function getCapacity(resetD) {
347
- var _resetD$metadata;
348
- return (_resetD$metadata = resetD.metadata) === null || _resetD$metadata === void 0 ? void 0 : _resetD$metadata.capacity;
349
- };
350
- var getResource = function getResource(resetD) {
351
- if (!bookings.relation_type) {
352
- try {
353
- var _resetD$event_resourc;
354
- if (resetD !== null && resetD !== void 0 && resetD.event_resources && resetD !== null && resetD !== void 0 && (_resetD$event_resourc = resetD.event_resources) !== null && _resetD$event_resourc !== void 0 && _resetD$event_resourc.length) {
355
- return resetD.event_resources.reduce(function (pre, cur) {
356
- if (pre[cur.form_id]) {
357
- pre[cur.form_id].push(cur);
358
- } else {
359
- pre[cur.form_id] = [cur];
360
- }
361
- return pre;
362
- }, {});
363
- }
364
- } catch (err) {
365
- console.error(err);
366
- }
367
- }
368
- return resetD.relation_id;
369
- };
370
- var serviceValue = bookings.list.map(function (d) {
371
- var detail = d.detail,
372
- product = d.product,
373
- resetD = _objectWithoutProperties(d, _excluded);
374
- var _detail = detail || mockProduct;
375
- var start_date = dayjs(resetD.start_date + ' ' + resetD.start_time);
376
- var end_date = dayjs(resetD.end_date + ' ' + resetD.end_time);
377
- return _objectSpread(_objectSpread({
378
- _id: (Math.random() + '').replace(/\D/g, '').substring(0, 11)
379
- }, _detail), {}, {
380
- booking_id: resetD.id,
381
- id: _detail.product_id,
382
- title: _detail.product_title,
383
- quantity: Number(_detail.product_quantity),
384
- cover: _detail.product_cover,
385
- // 商品本身的价格
386
- price: Number(_detail.source_product_price),
387
- relation_form_name: resetD.relation_form_name,
388
- product_resource: product === null || product === void 0 ? void 0 : product.product_resource,
389
- capacity: product === null || product === void 0 ? void 0 : product.capacity,
390
- _extend: _objectSpread(_objectSpread({}, resetD), {}, {
391
- quantity: Number(_detail.product_quantity),
392
- startDate: start_date,
393
- start_date: start_date,
394
- endDate: end_date,
395
- end_date: end_date,
396
- // 商品本身的价格
397
- price: Number(_detail.source_product_price),
398
- product_name: _detail.product_title,
399
- discount_reason: _detail.product_discount_reason,
400
- // resource: resetD.relation_id,
401
- order_detail_id: _detail.order_detail_id,
402
- // 总价: 商品本身价格 + 套餐价格 + 单规格价格 包含折扣
403
- total: Number(_detail.selling_price),
404
- // 原总价: 商品本身价格 + 套餐价格 + 单规格价格 不包含折扣
405
- origin_total: Number(_detail.original_price),
406
- payment_price: Number(_detail.payment_price),
407
- other: restoreProductOtherData(d),
408
- // 是否编辑了套餐 默认为0 如果编辑之后为1
409
- bundle_edit: 0,
410
- discount_per: _detail.discount_per,
411
- discount_type: _detail.discount_type,
412
- discountway: _detail.discountway,
413
- capacity: getCapacity(resetD),
414
- resource: getResource(resetD)
415
- })
416
- });
417
- });
418
- var disabledEdit = getDisabledEdit(data);
419
- var channelDisabledEdit = !!is_other_entrance_edited;
420
- return _objectSpread(_objectSpread({}, modalState), {}, {
421
- client: _objectSpread(_objectSpread({}, modalState.client), {}, {
422
- value: clientValue,
423
- edit: false,
424
- showModal: false
425
- }),
426
- date: _objectSpread(_objectSpread({}, modalState.date), {}, {
427
- value: dateValue,
428
- edit: false,
429
- showModal: false
430
- }),
431
- pet: _objectSpread(_objectSpread({}, modalState.pet), {}, {
432
- showModal: false,
433
- edit: false
434
- }),
435
- service: _objectSpread(_objectSpread({}, modalState.service), {}, {
436
- value: serviceValue,
437
- addModal: false,
438
- editModal: false,
439
- edit: false
440
- }),
441
- notes: _objectSpread(_objectSpread({}, modalState.notes), {}, {
442
- orderNote: note,
443
- edit: false
444
- }),
445
- disabledEdit: disabledEdit,
446
- channelDisabledEdit: channelDisabledEdit,
447
- appointment_status: bookings === null || bookings === void 0 ? void 0 : bookings.appointment_status
448
- });
449
- };
450
569
 
451
570
  /**
452
571
  * 初始化预约数据