@pisell/private-materials 6.3.78 → 6.3.80

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 (353) 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.css +1 -1
  6. package/build/lowcode/render/default/view.js +9 -9
  7. package/build/lowcode/view.css +1 -1
  8. package/build/lowcode/view.js +9 -9
  9. package/es/businessModel/SalesModel/index.d.ts +0 -1
  10. package/es/components/Sales/Cart/index.d.ts +1 -1
  11. package/es/components/Sales/Cart/index.js +18 -3
  12. package/es/components/Sales/Cart/utils.d.ts +68 -0
  13. package/es/components/Sales/Checkout/utils.d.ts +41 -0
  14. package/es/components/Sales/Checkout/utils.js +57 -1
  15. package/es/components/Sales/Summary/index.d.ts +2 -0
  16. package/es/components/Sales/Summary/index.js +7 -2
  17. package/es/components/Sales/Summary/utils.d.ts +58 -0
  18. package/es/components/Sales/Summary/utils.js +57 -10
  19. package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +0 -1
  20. package/es/components/appointmentBooking/components/Cart/Item/index.js +62 -4
  21. package/es/components/appointmentBooking/components/Content/index.d.ts +0 -1
  22. package/es/components/appointmentBooking/components/Deposit/index.d.ts +5 -1
  23. package/es/components/appointmentBooking/components/Deposit/index.js +9 -4
  24. package/es/components/appointmentBooking/components/Header/index.d.ts +0 -1
  25. package/es/components/appointmentBooking/components/TimeSlicing/components/SelectDateOS.d.ts +0 -1
  26. package/es/components/appointmentBooking/index.d.ts +0 -1
  27. package/es/components/appointmentBooking/locales.d.ts +366 -0
  28. package/es/components/booking/addons/model.d.ts +10 -1
  29. package/es/components/booking/components/footer/index.d.ts +0 -1
  30. package/es/components/booking/components/reloadResourceModal/index.d.ts +1 -0
  31. package/es/components/booking/components/tabPane/index.d.ts +4 -0
  32. package/es/components/booking/deposit/DepositItem/index.d.ts +25 -0
  33. package/es/components/booking/deposit/index.d.ts +0 -1
  34. package/es/components/booking/forms/model.d.ts +10 -1
  35. package/es/components/booking/hooks/useIsBooking4Shop.d.ts +1 -0
  36. package/es/components/booking/info/addServiceVariant/index.d.ts +0 -1
  37. package/es/components/booking/info/clientVariant/hooks/useClientFn.d.ts +1 -0
  38. package/es/components/booking/info/clientVariant/utils.d.ts +1 -0
  39. package/es/components/booking/info/date/index.d.ts +1 -0
  40. package/es/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
  41. package/es/components/booking/info/index.d.ts +0 -1
  42. package/es/components/booking/info/model.d.ts +10 -1
  43. package/es/components/booking/info/notes/index.d.ts +1 -0
  44. package/es/components/booking/info/service/Lists.d.ts +0 -1
  45. package/es/components/booking/info/service/actions/index.d.ts +1 -0
  46. package/es/components/booking/info/service/addService/index.d.ts +0 -1
  47. package/es/components/booking/info/service/addService/utils.d.ts +1 -1
  48. package/es/components/booking/info/service/addTimeModal/index.d.ts +0 -1
  49. package/es/components/booking/info/service/serviceList/index.d.ts +0 -1
  50. package/es/components/booking/info/service2/Lists.d.ts +0 -1
  51. package/es/components/booking/info/service2/utils.d.ts +1 -0
  52. package/es/components/booking/info/service2/utils.js +4 -4
  53. package/es/components/booking/info2/service/actions/index.d.ts +1 -0
  54. package/es/components/booking/info2/service/addService/utils.d.ts +1 -1
  55. package/es/components/booking/info2/service/addTimeModal/index.d.ts +0 -1
  56. package/es/components/booking/info2/service/editService/utils.d.ts +13 -0
  57. package/es/components/booking/info2/service/serviceList/index.d.ts +0 -1
  58. package/es/components/booking/materiels/contacts/index.d.ts +1 -0
  59. package/es/components/booking/materiels/duration/index.d.ts +1 -0
  60. package/es/components/booking/materiels/holder/index.d.ts +1 -0
  61. package/es/components/booking/materiels/startTime/index.d.ts +1 -0
  62. package/es/components/booking/model.d.ts +9 -1
  63. package/es/components/booking/notes/addNote/index.d.ts +3 -0
  64. package/es/components/booking/notes/model.d.ts +10 -1
  65. package/es/components/booking/payments/model.d.ts +10 -1
  66. package/es/components/booking/utils.d.ts +2 -2
  67. package/es/components/eftpos/const.d.ts +3 -1
  68. package/es/components/eftpos/const.js +2 -0
  69. package/es/components/eftpos/device.d.ts +3 -1
  70. package/es/components/eftpos/device.js +5 -3
  71. package/es/components/eftpos/index.js +34 -11
  72. package/es/components/eftpos/index.less +26 -1
  73. package/es/components/eftpos/locales.d.ts +3 -0
  74. package/es/components/eftpos/locales.js +3 -0
  75. package/es/components/eftpos/pos.d.ts +1 -0
  76. package/es/components/eftposPay/aggregatePayment/hooks/usePayment.d.ts +6 -0
  77. package/es/components/eftposPay/aggregatePayment/hooks/usePayment.js +125 -0
  78. package/es/components/eftposPay/aggregatePayment/index.d.ts +3 -0
  79. package/es/components/eftposPay/aggregatePayment/index.js +3 -0
  80. package/es/components/eftposPay/aggregatePayment/mock.d.ts +495 -0
  81. package/es/components/eftposPay/aggregatePayment/mock.js +567 -0
  82. package/es/components/eftposPay/aggregatePayment/service.d.ts +24 -0
  83. package/es/components/eftposPay/aggregatePayment/service.js +70 -0
  84. package/es/components/eftposPay/aggregatePayment/types.d.ts +96 -0
  85. package/es/components/eftposPay/aggregatePayment/types.js +61 -0
  86. package/es/components/eftposPay/aggregatePayment/utils/logs.d.ts +110 -0
  87. package/es/components/eftposPay/aggregatePayment/utils/logs.js +385 -0
  88. package/es/components/eftposPay/aggregatePayment/utils/payment.d.ts +132 -0
  89. package/es/components/eftposPay/aggregatePayment/utils/payment.js +1127 -0
  90. package/es/components/eftposPay/amount.d.ts +1 -2
  91. package/es/components/eftposPay/app.d.ts +0 -1
  92. package/es/components/eftposPay/component/fail/failCustom.d.ts +0 -1
  93. package/es/components/eftposPay/component/fail/network.d.ts +1 -0
  94. package/es/components/eftposPay/component/fail/unknow.d.ts +1 -0
  95. package/es/components/eftposPay/component/manual/index.d.ts +1 -0
  96. package/es/components/eftposPay/component/signature/index.d.ts +1 -0
  97. package/es/components/eftposPay/const.d.ts +189 -0
  98. package/es/components/eftposPay/const.js +2 -0
  99. package/es/components/eftposPay/device.d.ts +1 -2
  100. package/es/components/eftposPay/hooks.d.ts +36 -0
  101. package/es/components/eftposPay/hooks.js +12 -0
  102. package/es/components/eftposPay/index.d.ts +0 -1
  103. package/es/components/eftposPay/linkly/index.d.ts +0 -1
  104. package/es/components/eftposPay/linkly/index.js +1 -0
  105. package/es/components/eftposPay/locales.d.ts +330 -0
  106. package/es/components/eftposPay/manufacturer.d.ts +1 -0
  107. package/es/components/eftposPay/manufacturer.js +4 -0
  108. package/es/components/eftposPay/mx51/Action.d.ts +6 -0
  109. package/es/components/eftposPay/mx51/Action.js +91 -0
  110. package/es/components/eftposPay/mx51/const.d.ts +5 -0
  111. package/es/components/eftposPay/mx51/const.js +69 -0
  112. package/es/components/eftposPay/mx51/index.d.ts +6 -0
  113. package/es/components/eftposPay/mx51/index.js +362 -0
  114. package/es/components/eftposPay/mx51/types.d.ts +136 -0
  115. package/es/components/eftposPay/mx51/types.js +29 -0
  116. package/es/components/eftposPay/mx51/utils.d.ts +10 -0
  117. package/es/components/eftposPay/mx51/utils.js +120 -0
  118. package/es/components/eftposPay/pay.d.ts +0 -1
  119. package/es/components/eftposPay/pay.js +7 -2
  120. package/es/components/eftposPay/store/index.d.ts +355 -0
  121. package/es/components/eftposPay/tyro/index.d.ts +9 -0
  122. package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +4 -2
  123. package/es/components/eventBooking/components/Provider/Cart/Deposit/index.js +4 -1
  124. package/es/components/eventBooking/components/Provider/Cart/Item/index.js +79 -6
  125. package/es/components/eventBooking/components/Provider/Cart/Item/index.less +7 -6
  126. package/es/components/eventBooking/components/Provider/Cart/index.js +2 -7
  127. package/es/components/eventBooking/components/Provider/Content/index.less +1 -1
  128. package/es/components/eventBooking/components/Voucher/components/locales.d.ts +39 -0
  129. package/es/components/eventBooking/components/Voucher/index.js +1 -1
  130. package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
  131. package/es/components/eventBooking/index.d.ts +0 -1
  132. package/es/components/index.d.ts +1 -2
  133. package/es/components/index.js +1 -2
  134. package/es/components/pay/toC/PaymentList/utils.d.ts +36 -0
  135. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/Content.d.ts +6 -0
  136. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +2 -0
  137. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +2 -0
  138. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +2 -0
  139. package/es/components/pay/toC/PaymentMethods/StripePay/index.d.ts +10 -0
  140. package/es/components/pay/toC/model.d.ts +40 -0
  141. package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
  142. package/es/components/pisellSelectCustomerModal/RightPanel/index.d.ts +0 -1
  143. package/es/components/productExtension/index.d.ts +0 -1
  144. package/es/components/ruleSetting/index.d.ts +0 -1
  145. package/es/components/schedules/components/ScheduleList/index.d.ts +1 -0
  146. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
  147. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
  148. package/es/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
  149. package/es/components/schedules/products/index.d.ts +1 -0
  150. package/es/components/schedules/resources/index.d.ts +1 -0
  151. package/es/components/schedules/schedules/AllSchedules/index.d.ts +1 -0
  152. package/es/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +1 -0
  153. package/es/components/schedules/schedules/index.d.ts +1 -0
  154. package/es/components/shoppingCart/locales.d.ts +33 -0
  155. package/es/components/shoppingCart/type.d.ts +48 -0
  156. package/es/components/subTotal/index.d.ts +2 -0
  157. package/es/components/subTotal/index.js +42 -20
  158. package/es/components/subTotal/locales.d.ts +42 -0
  159. package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
  160. package/es/components/ticketBooking/locales.d.ts +174 -0
  161. package/es/hooks/useEngineContext.d.ts +10 -0
  162. package/es/hooks/useWindowSize.d.ts +5 -0
  163. package/es/plus/productSelect/ProductList/gridComponents.d.ts +44 -0
  164. package/es/plus/selectHolder/locales.d.ts +21 -0
  165. package/es/plus/skuOptionsSelection/components/NormalCard/index.d.ts +0 -1
  166. package/es/plus/skuOptionsSelection/components/VariantCard/index.d.ts +0 -1
  167. package/es/plus/skuOptionsSelection/types.d.ts +429 -0
  168. package/es/plus/skuOptionsSelection/utils/transformSelectorValueToValue.d.ts +4 -0
  169. package/es/plus/skuOptionsSelection/utils/transformValueToSelectorValue.d.ts +4 -0
  170. package/es/plus/walletEditor/components/relationProduct/index.d.ts +1 -0
  171. package/es/pro/NumericStepper/index.d.ts +43 -0
  172. package/es/pro/Selector/Selector.d.ts +14 -0
  173. package/es/pro/Selector/components/Card/index.d.ts +57 -0
  174. package/es/pro/Selector/components/Indicator/index.d.ts +19 -0
  175. package/es/pro/Selector/components/LayoutContainer/index.d.ts +16 -0
  176. package/es/pro/Selector/demo.d.ts +0 -1
  177. package/es/pro/Selector/hooks/usePresetProps.d.ts +24 -0
  178. package/es/pro/Selector/types.d.ts +173 -0
  179. package/es/pro/pisellNumberSelector/example.d.ts +3 -0
  180. package/lib/businessModel/SalesModel/index.d.ts +0 -1
  181. package/lib/components/Sales/Cart/index.d.ts +1 -1
  182. package/lib/components/Sales/Cart/index.js +20 -7
  183. package/lib/components/Sales/Cart/utils.d.ts +68 -0
  184. package/lib/components/Sales/Checkout/utils.d.ts +41 -0
  185. package/lib/components/Sales/Checkout/utils.js +64 -1
  186. package/lib/components/Sales/Summary/index.d.ts +2 -0
  187. package/lib/components/Sales/Summary/index.js +8 -2
  188. package/lib/components/Sales/Summary/utils.d.ts +58 -0
  189. package/lib/components/Sales/Summary/utils.js +38 -13
  190. package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +0 -1
  191. package/lib/components/appointmentBooking/components/Cart/Item/index.js +52 -4
  192. package/lib/components/appointmentBooking/components/Content/index.d.ts +0 -1
  193. package/lib/components/appointmentBooking/components/Deposit/index.d.ts +5 -1
  194. package/lib/components/appointmentBooking/components/Deposit/index.js +7 -4
  195. package/lib/components/appointmentBooking/components/Header/index.d.ts +0 -1
  196. package/lib/components/appointmentBooking/components/TimeSlicing/components/SelectDateOS.d.ts +0 -1
  197. package/lib/components/appointmentBooking/index.d.ts +0 -1
  198. package/lib/components/appointmentBooking/locales.d.ts +366 -0
  199. package/lib/components/booking/addons/model.d.ts +10 -1
  200. package/lib/components/booking/components/footer/index.d.ts +0 -1
  201. package/lib/components/booking/components/reloadResourceModal/index.d.ts +1 -0
  202. package/lib/components/booking/components/tabPane/index.d.ts +4 -0
  203. package/lib/components/booking/deposit/DepositItem/index.d.ts +25 -0
  204. package/lib/components/booking/deposit/index.d.ts +0 -1
  205. package/lib/components/booking/forms/model.d.ts +10 -1
  206. package/lib/components/booking/hooks/useIsBooking4Shop.d.ts +1 -0
  207. package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -1
  208. package/lib/components/booking/info/clientVariant/hooks/useClientFn.d.ts +1 -0
  209. package/lib/components/booking/info/clientVariant/utils.d.ts +1 -0
  210. package/lib/components/booking/info/date/index.d.ts +1 -0
  211. package/lib/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
  212. package/lib/components/booking/info/index.d.ts +0 -1
  213. package/lib/components/booking/info/model.d.ts +10 -1
  214. package/lib/components/booking/info/notes/index.d.ts +1 -0
  215. package/lib/components/booking/info/service/Lists.d.ts +0 -1
  216. package/lib/components/booking/info/service/actions/index.d.ts +1 -0
  217. package/lib/components/booking/info/service/addService/index.d.ts +0 -1
  218. package/lib/components/booking/info/service/addService/utils.d.ts +1 -1
  219. package/lib/components/booking/info/service/addTimeModal/index.d.ts +0 -1
  220. package/lib/components/booking/info/service/serviceList/index.d.ts +0 -1
  221. package/lib/components/booking/info/service2/Lists.d.ts +0 -1
  222. package/lib/components/booking/info/service2/utils.d.ts +1 -0
  223. package/lib/components/booking/info/service2/utils.js +4 -4
  224. package/lib/components/booking/info2/service/actions/index.d.ts +1 -0
  225. package/lib/components/booking/info2/service/addService/utils.d.ts +1 -1
  226. package/lib/components/booking/info2/service/addTimeModal/index.d.ts +0 -1
  227. package/lib/components/booking/info2/service/editService/utils.d.ts +13 -0
  228. package/lib/components/booking/info2/service/serviceList/index.d.ts +0 -1
  229. package/lib/components/booking/materiels/contacts/index.d.ts +1 -0
  230. package/lib/components/booking/materiels/duration/index.d.ts +1 -0
  231. package/lib/components/booking/materiels/holder/index.d.ts +1 -0
  232. package/lib/components/booking/materiels/startTime/index.d.ts +1 -0
  233. package/lib/components/booking/model.d.ts +9 -1
  234. package/lib/components/booking/notes/addNote/index.d.ts +3 -0
  235. package/lib/components/booking/notes/model.d.ts +10 -1
  236. package/lib/components/booking/payments/model.d.ts +10 -1
  237. package/lib/components/booking/utils.d.ts +2 -2
  238. package/lib/components/eftpos/const.d.ts +3 -1
  239. package/lib/components/eftpos/const.js +2 -0
  240. package/lib/components/eftpos/device.d.ts +3 -1
  241. package/lib/components/eftpos/device.js +3 -3
  242. package/lib/components/eftpos/index.js +20 -5
  243. package/lib/components/eftpos/index.less +26 -1
  244. package/lib/components/eftpos/locales.d.ts +3 -0
  245. package/lib/components/eftpos/locales.js +3 -0
  246. package/lib/components/eftpos/pos.d.ts +1 -0
  247. package/lib/components/eftposPay/aggregatePayment/hooks/usePayment.d.ts +6 -0
  248. package/lib/components/eftposPay/aggregatePayment/hooks/usePayment.js +152 -0
  249. package/lib/components/eftposPay/aggregatePayment/index.d.ts +3 -0
  250. package/lib/components/eftposPay/aggregatePayment/index.js +32 -0
  251. package/lib/components/eftposPay/aggregatePayment/mock.d.ts +495 -0
  252. package/lib/components/eftposPay/aggregatePayment/mock.js +679 -0
  253. package/lib/components/eftposPay/aggregatePayment/service.d.ts +24 -0
  254. package/lib/components/eftposPay/aggregatePayment/service.js +81 -0
  255. package/lib/components/eftposPay/aggregatePayment/types.d.ts +96 -0
  256. package/lib/components/eftposPay/aggregatePayment/types.js +74 -0
  257. package/lib/components/eftposPay/aggregatePayment/utils/logs.d.ts +110 -0
  258. package/lib/components/eftposPay/aggregatePayment/utils/logs.js +302 -0
  259. package/lib/components/eftposPay/aggregatePayment/utils/payment.d.ts +132 -0
  260. package/lib/components/eftposPay/aggregatePayment/utils/payment.js +746 -0
  261. package/lib/components/eftposPay/amount.d.ts +1 -2
  262. package/lib/components/eftposPay/app.d.ts +0 -1
  263. package/lib/components/eftposPay/component/fail/failCustom.d.ts +0 -1
  264. package/lib/components/eftposPay/component/fail/network.d.ts +1 -0
  265. package/lib/components/eftposPay/component/fail/unknow.d.ts +1 -0
  266. package/lib/components/eftposPay/component/manual/index.d.ts +1 -0
  267. package/lib/components/eftposPay/component/signature/index.d.ts +1 -0
  268. package/lib/components/eftposPay/const.d.ts +189 -0
  269. package/lib/components/eftposPay/const.js +2 -0
  270. package/lib/components/eftposPay/device.d.ts +1 -2
  271. package/lib/components/eftposPay/hooks.d.ts +36 -0
  272. package/lib/components/eftposPay/hooks.js +16 -0
  273. package/lib/components/eftposPay/index.d.ts +0 -1
  274. package/lib/components/eftposPay/linkly/index.d.ts +0 -1
  275. package/lib/components/eftposPay/linkly/index.js +1 -0
  276. package/lib/components/eftposPay/locales.d.ts +330 -0
  277. package/lib/components/eftposPay/manufacturer.d.ts +1 -0
  278. package/lib/components/eftposPay/manufacturer.js +6 -0
  279. package/lib/components/eftposPay/mx51/Action.d.ts +6 -0
  280. package/lib/components/eftposPay/mx51/Action.js +127 -0
  281. package/lib/components/eftposPay/mx51/const.d.ts +5 -0
  282. package/lib/components/eftposPay/mx51/const.js +85 -0
  283. package/lib/components/eftposPay/mx51/index.d.ts +6 -0
  284. package/lib/components/eftposPay/mx51/index.js +330 -0
  285. package/lib/components/eftposPay/mx51/types.d.ts +136 -0
  286. package/lib/components/eftposPay/mx51/types.js +39 -0
  287. package/lib/components/eftposPay/mx51/utils.d.ts +10 -0
  288. package/lib/components/eftposPay/mx51/utils.js +114 -0
  289. package/lib/components/eftposPay/pay.d.ts +0 -1
  290. package/lib/components/eftposPay/pay.js +4 -2
  291. package/lib/components/eftposPay/store/index.d.ts +355 -0
  292. package/lib/components/eftposPay/tyro/index.d.ts +9 -0
  293. package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +4 -2
  294. package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.js +3 -1
  295. package/lib/components/eventBooking/components/Provider/Cart/Item/index.js +77 -5
  296. package/lib/components/eventBooking/components/Provider/Cart/Item/index.less +7 -6
  297. package/lib/components/eventBooking/components/Provider/Cart/index.js +2 -2
  298. package/lib/components/eventBooking/components/Provider/Content/index.less +1 -1
  299. package/lib/components/eventBooking/components/Voucher/components/locales.d.ts +39 -0
  300. package/lib/components/eventBooking/components/Voucher/index.js +1 -1
  301. package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
  302. package/lib/components/eventBooking/index.d.ts +0 -1
  303. package/lib/components/index.d.ts +1 -2
  304. package/lib/components/index.js +0 -3
  305. package/lib/components/pay/toC/PaymentList/utils.d.ts +36 -0
  306. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/Content.d.ts +6 -0
  307. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +2 -0
  308. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +2 -0
  309. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +2 -0
  310. package/lib/components/pay/toC/PaymentMethods/StripePay/index.d.ts +10 -0
  311. package/lib/components/pay/toC/model.d.ts +40 -0
  312. package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
  313. package/lib/components/pisellSelectCustomerModal/RightPanel/index.d.ts +0 -1
  314. package/lib/components/productExtension/index.d.ts +0 -1
  315. package/lib/components/ruleSetting/index.d.ts +0 -1
  316. package/lib/components/schedules/components/ScheduleList/index.d.ts +1 -0
  317. package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
  318. package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
  319. package/lib/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
  320. package/lib/components/schedules/products/index.d.ts +1 -0
  321. package/lib/components/schedules/resources/index.d.ts +1 -0
  322. package/lib/components/schedules/schedules/AllSchedules/index.d.ts +1 -0
  323. package/lib/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +1 -0
  324. package/lib/components/schedules/schedules/index.d.ts +1 -0
  325. package/lib/components/shoppingCart/locales.d.ts +33 -0
  326. package/lib/components/shoppingCart/type.d.ts +48 -0
  327. package/lib/components/subTotal/index.d.ts +2 -0
  328. package/lib/components/subTotal/index.js +34 -20
  329. package/lib/components/subTotal/locales.d.ts +42 -0
  330. package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
  331. package/lib/components/ticketBooking/locales.d.ts +174 -0
  332. package/lib/hooks/useEngineContext.d.ts +10 -0
  333. package/lib/hooks/useWindowSize.d.ts +5 -0
  334. package/lib/plus/productSelect/ProductList/gridComponents.d.ts +44 -0
  335. package/lib/plus/selectHolder/locales.d.ts +21 -0
  336. package/lib/plus/skuOptionsSelection/components/NormalCard/index.d.ts +0 -1
  337. package/lib/plus/skuOptionsSelection/components/VariantCard/index.d.ts +0 -1
  338. package/lib/plus/skuOptionsSelection/types.d.ts +429 -0
  339. package/lib/plus/skuOptionsSelection/utils/transformSelectorValueToValue.d.ts +4 -0
  340. package/lib/plus/skuOptionsSelection/utils/transformValueToSelectorValue.d.ts +4 -0
  341. package/lib/plus/walletEditor/components/relationProduct/index.d.ts +1 -0
  342. package/lib/pro/NumericStepper/index.d.ts +43 -0
  343. package/lib/pro/Selector/Selector.d.ts +14 -0
  344. package/lib/pro/Selector/components/Card/index.d.ts +57 -0
  345. package/lib/pro/Selector/components/Indicator/index.d.ts +19 -0
  346. package/lib/pro/Selector/components/LayoutContainer/index.d.ts +16 -0
  347. package/lib/pro/Selector/demo.d.ts +0 -1
  348. package/lib/pro/Selector/hooks/usePresetProps.d.ts +24 -0
  349. package/lib/pro/Selector/types.d.ts +173 -0
  350. package/lib/pro/pisellNumberSelector/example.d.ts +3 -0
  351. package/lowcode/eco-cup-list/meta.ts +63 -0
  352. package/lowcode/eco-customer-list/meta.ts +63 -0
  353. package/package.json +1 -1
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const SalesModel: ({ children, hooks, config }: any) => JSX.Element;
3
2
  export * from './Sales';
4
3
  export default SalesModel;
@@ -13,7 +13,7 @@ interface CartContextType {
13
13
  createCartItemFromEvent: (eventItem: any) => CartItem;
14
14
  createCartItemFromHolder: (holderItem: any) => CartItem;
15
15
  addToCart: () => void;
16
- updateCartItem: (cartItem: CartItem) => CartItem;
16
+ updateCartItem: (cartItem: CartItem, updateType?: 'deposit') => CartItem;
17
17
  deleteCartItem: (cartItem: CartItem) => void;
18
18
  clickCartItem: (cartItem: CartItem) => void;
19
19
  updateCurrentCartItem: (cartItem: Partial<CartItem>) => void;
@@ -342,6 +342,7 @@ export var CartProvider = function CartProvider(_ref) {
342
342
  },
343
343
  event_unique_identifier: _id // 传递给接口用于商品可用性检测的比对
344
344
  }),
345
+ _eventDetail: eventDetail,
345
346
  _productDetail: eventDetail.productDetail,
346
347
  _productOrigin: transformProduct((eventDetail === null || eventDetail === void 0 || (_eventDetail$productD3 = eventDetail.productDetail) === null || _eventDetail$productD3 === void 0 ? void 0 : _eventDetail$productD3.origin) || bookingOptionData),
347
348
  _productInit: transformProduct((eventDetail === null || eventDetail === void 0 || (_eventDetail$productD4 = eventDetail.productDetail) === null || _eventDetail$productD4 === void 0 ? void 0 : _eventDetail$productD4.origin) || bookingOptionData)
@@ -378,9 +379,23 @@ export var CartProvider = function CartProvider(_ref) {
378
379
  });
379
380
  }
380
381
  };
381
- var updateCartItem = function updateCartItem(cartItem) {
382
- var newCartItems = getCurrentData().cartData.cartItems.map(function (item) {
383
- return item._id === cartItem._id ? cartItem : item;
382
+ var updateCartItem = function updateCartItem(cartItem, updateType) {
383
+ var _getCurrentData2;
384
+ var newCartItems = (_getCurrentData2 = getCurrentData()) === null || _getCurrentData2 === void 0 || (_getCurrentData2 = _getCurrentData2.cartData) === null || _getCurrentData2 === void 0 || (_getCurrentData2 = _getCurrentData2.cartItems) === null || _getCurrentData2 === void 0 ? void 0 : _getCurrentData2.map(function (item) {
385
+ if (item._id === cartItem._id) {
386
+ var _tempCartItem = _objectSpread({}, cartItem || {});
387
+ // 更新定金信息
388
+ if (updateType === 'deposit') {
389
+ var eventDetail = _tempCartItem === null || _tempCartItem === void 0 ? void 0 : _tempCartItem._eventDetail;
390
+ if (eventDetail) {
391
+ var num = (_tempCartItem === null || _tempCartItem === void 0 ? void 0 : _tempCartItem.num) || 1;
392
+ var deposit = handleProductDeposit(_tempCartItem, eventDetail, num);
393
+ _tempCartItem.deposit = deposit;
394
+ }
395
+ }
396
+ return _tempCartItem;
397
+ }
398
+ return item;
384
399
  });
385
400
  setCartData({
386
401
  cartItems: newCartItems
@@ -0,0 +1,68 @@
1
+ import Decimal from 'decimal.js';
2
+ import { ICalculatePriceParams } from './types';
3
+ export declare const handleProductInfo: (eventDetail: any, num: number) => {
4
+ price: number;
5
+ totalPrice: number;
6
+ originTotal: any;
7
+ is_charge_tax: any;
8
+ };
9
+ /**
10
+ * 获取商品价格
11
+ */
12
+ export declare const getPrice: (params: ICalculatePriceParams) => number;
13
+ /**
14
+ * 获取商品总价
15
+ * @description 当前总价计算基于商品数量为1
16
+ * @param item 商品
17
+ * @returns 商品总价
18
+ */
19
+ export declare const getTotalPrice: (params: ICalculatePriceParams) => number;
20
+ /**
21
+ * 获取商品原始总价
22
+ * @description 当前总价计算基于商品数量为1
23
+ * @param item 商品
24
+ * @returns 商品原始总价
25
+ */
26
+ export declare const getOriginTotalPrice: (params: ICalculatePriceParams) => number | undefined;
27
+ export declare const handleCartItemOrigin: (cartItem: any, eventDetail: any) => any;
28
+ export declare const formatBundleToOrigin: (bundle: any) => any;
29
+ export declare const formatOptionsToOrigin: (options: any) => any;
30
+ export declare const handleProductDeposit: (cartItem: any, eventDetail: any, num: number) => {
31
+ total: number;
32
+ protocols: any;
33
+ } | null;
34
+ /**
35
+ * 获取商品定金
36
+ * @description 定金基于商品售价来算,最终乘商品数量
37
+ * 1、如果套餐主商品有定金规则,则定金为:(套餐商品总售价 * 定金百分比 + 定金固定金额)* 商品数量
38
+ * 2、如果套餐主商品没有定金规则,子商品有定金规则,则定金为:(套餐子商品售价 * 套餐子商品定金百分比 + 套餐子商品定金固定金额)* 商品数量,最终将所有子商品定金相加
39
+ * 3、普通商品/单规格商品/组合规则商品,定金规则:(商品总售价 * 定金百分比 + 定金固定金额)* 商品数量
40
+ * @param params 参数
41
+ * @returns 商品定金
42
+ */
43
+ export declare const getProductDeposit: (params: {
44
+ cartItem: any;
45
+ product: any;
46
+ bundle?: any;
47
+ options?: any;
48
+ num?: number;
49
+ }) => {
50
+ total: number;
51
+ protocols: any;
52
+ } | null;
53
+ /**
54
+ * 计算商品定金
55
+ * @param params 参数
56
+ * @returns 商品定金
57
+ */
58
+ export declare const calculateProductDeposit: (params: {
59
+ depositData: {
60
+ deposit_fixed?: string;
61
+ deposit_percentage?: string;
62
+ };
63
+ total: string | number;
64
+ num: number;
65
+ }) => {
66
+ result: boolean;
67
+ depositTotal: Decimal;
68
+ };
@@ -0,0 +1,41 @@
1
+ /**
2
+ * @title: 套餐单规格信息
3
+ * @description:
4
+ * @param {any} option
5
+ * @return {*}
6
+ * @Author: zhiwei.Wang
7
+ * @Date: 2024-02-19 09:26
8
+ */
9
+ export declare const formatProductOption: (option: any) => any;
10
+ /**
11
+ * @title: 套餐信息
12
+ * @description:
13
+ * @param {any} bundle
14
+ * @return {*}
15
+ * @Author: zhiwei.Wang
16
+ * @Date: 2024-02-19 09:26
17
+ */
18
+ export declare const formatProductBundle: (bundle: any) => any;
19
+ /**
20
+ * @title: 格式化下单接口数据
21
+ * @description:
22
+ * @param {any} state saledModel数据源
23
+ * @param {boolean} excludeDisabled 是否需要排除购物车中失效商品
24
+ * @Author: xiangfeng.xue
25
+ * @Date: 2025-01-21 17:57
26
+ */
27
+ export declare const formatValues: (params: {
28
+ state: any;
29
+ platform: 'h5' | 'pc';
30
+ excludeDisabled?: boolean;
31
+ extra?: Record<string, any>;
32
+ otherValue?: Record<string, any>;
33
+ }) => any;
34
+ /**
35
+ * @title: 获取拉开表单弹窗参数
36
+ * @param state
37
+ */
38
+ export declare const getFormParams: (state: any) => {
39
+ product_id: any;
40
+ appointment_type: string;
41
+ };
@@ -1,9 +1,16 @@
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
+ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
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); }
5
+ function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
6
+ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
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; }
2
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; }
3
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; }
4
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; }
5
11
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
6
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); }
13
+ import Decimal from 'decimal.js';
7
14
  /**
8
15
  * @title: 套餐单规格信息
9
16
  * @description:
@@ -71,10 +78,59 @@ var getSubType = function getSubType(item) {
71
78
  var formatBookings = function formatBookings(list) {
72
79
  var bookings = [];
73
80
  bookings = list.map(function (item) {
74
- return item._originData;
81
+ var _product$product_bund;
82
+ var newOriginData = _objectSpread({}, item._originData || {});
83
+ var product = (newOriginData === null || newOriginData === void 0 ? void 0 : newOriginData.product) || {};
84
+ // 处理discount相关逻辑
85
+ var discount_list = product === null || product === void 0 ? void 0 : product.discount_list;
86
+ // 筛选出主商品的折扣
87
+ var main_product_discount = discount_list === null || discount_list === void 0 ? void 0 : discount_list.filter(function (d) {
88
+ var _d$metadata;
89
+ return !((_d$metadata = d.metadata) !== null && _d$metadata !== void 0 && _d$metadata.custom_product_bundle_map_id);
90
+ });
91
+ if (main_product_discount !== null && main_product_discount !== void 0 && main_product_discount.length) {
92
+ product.metadata = {
93
+ product_discount_difference: handleProductDiscountDifference([main_product_discount])
94
+ };
95
+ }
96
+ console.log('main_product_discount', main_product_discount);
97
+ if (product !== null && product !== void 0 && (_product$product_bund = product.product_bundle) !== null && _product$product_bund !== void 0 && _product$product_bund.length) {
98
+ var _product$product_bund2, _product$product_bund3;
99
+ // 处理套餐商品的折扣
100
+ product.product_bundle = product === null || product === void 0 || (_product$product_bund2 = product.product_bundle) === null || _product$product_bund2 === void 0 || (_product$product_bund3 = _product$product_bund2.map) === null || _product$product_bund3 === void 0 ? void 0 : _product$product_bund3.call(_product$product_bund2, function (v) {
101
+ var _item$selectedBundle, _item$selectedBundle$;
102
+ // 获取套餐商品的折扣
103
+ var bundle_item_discount = [];
104
+ item === null || item === void 0 || (_item$selectedBundle = item.selectedBundle) === null || _item$selectedBundle === void 0 || (_item$selectedBundle$ = _item$selectedBundle.forEach) === null || _item$selectedBundle$ === void 0 || _item$selectedBundle$.call(_item$selectedBundle, function (s) {
105
+ if ((s === null || s === void 0 ? void 0 : s.id) === (v === null || v === void 0 ? void 0 : v.bundle_id) && (s === null || s === void 0 ? void 0 : s.group_id) === (v === null || v === void 0 ? void 0 : v.bundle_group_id) && (s === null || s === void 0 ? void 0 : s._bundle_product_id) === (v === null || v === void 0 ? void 0 : v.bundle_product_id)) {
106
+ bundle_item_discount.push.apply(bundle_item_discount, _toConsumableArray((s === null || s === void 0 ? void 0 : s.discount_list) || []));
107
+ }
108
+ });
109
+ console.log('bundle_item_discount', bundle_item_discount);
110
+ var newBundleItem = _objectSpread({}, v || {});
111
+ if (bundle_item_discount !== null && bundle_item_discount !== void 0 && bundle_item_discount.length) {
112
+ var _bundle_item_discount;
113
+ newBundleItem.metadata = {
114
+ custom_product_bundle_map_id: bundle_item_discount === null || bundle_item_discount === void 0 || (_bundle_item_discount = bundle_item_discount[0]) === null || _bundle_item_discount === void 0 || (_bundle_item_discount = _bundle_item_discount.metadata) === null || _bundle_item_discount === void 0 ? void 0 : _bundle_item_discount.custom_product_bundle_map_id,
115
+ product_discount_difference: handleProductDiscountDifference(bundle_item_discount)
116
+ };
117
+ }
118
+ return newBundleItem;
119
+ });
120
+ }
121
+ newOriginData.product = product;
122
+ return newOriginData;
75
123
  });
124
+ console.log('bookings>>>>', bookings);
76
125
  return bookings;
77
126
  };
127
+ var handleProductDiscountDifference = function handleProductDiscountDifference(discount_list) {
128
+ var product_discount_difference = discount_list === null || discount_list === void 0 ? void 0 : discount_list.reduce(function (pre, cur) {
129
+ var _cur$metadata;
130
+ return pre.plus(new Decimal((cur === null || cur === void 0 || (_cur$metadata = cur.metadata) === null || _cur$metadata === void 0 ? void 0 : _cur$metadata.product_discount_difference) || 0));
131
+ }, new Decimal(0));
132
+ return product_discount_difference.toNumber();
133
+ };
78
134
 
79
135
  /**
80
136
  * @title: 格式化下单接口数据
@@ -7,6 +7,8 @@ interface SummaryContextType {
7
7
  taxTitle?: string;
8
8
  totalTaxFee?: string;
9
9
  isPriceIncludeTax?: 0 | 1;
10
+ taxRate?: number;
11
+ surcharge?: any;
10
12
  deposit?: {
11
13
  total: string;
12
14
  protocols: any[];
@@ -9,6 +9,7 @@ import { useCart } from "../Cart";
9
9
  import { calculatePriceDetails } from "./utils";
10
10
  import { useInit } from "../Init";
11
11
  import { getDepositProtocolApi } from "./serve";
12
+ import { usePisellOS } from "../../../hooks/useEngineContext";
12
13
 
13
14
  // 定义上下文接口
14
15
 
@@ -19,6 +20,7 @@ var defaultState = {};
19
20
  export var SummaryContext = /*#__PURE__*/createContext(undefined);
20
21
  export var SummaryProvider = function SummaryProvider(_ref) {
21
22
  var children = _ref.children;
23
+ var pisellos = usePisellOS();
22
24
  var _useCart = useCart(),
23
25
  cartData = _useCart.cartData;
24
26
  var _useInit = useInit(),
@@ -27,9 +29,10 @@ export var SummaryProvider = function SummaryProvider(_ref) {
27
29
  _useState2 = _slicedToArray(_useState, 2),
28
30
  isAgreeDepositPolicy = _useState2[0],
29
31
  setIsAgreeDepositPolicy = _useState2[1];
32
+ var summaryModule = pisellos.getModule('summary');
30
33
  var summaryData = useMemo(function () {
31
- return calculatePriceDetails((initData === null || initData === void 0 ? void 0 : initData.shop) || {}, cartData.cartItems);
32
- }, [cartData.cartItems, initData === null || initData === void 0 ? void 0 : initData.shop]);
34
+ return calculatePriceDetails((initData === null || initData === void 0 ? void 0 : initData.shop) || {}, cartData.cartItems, summaryModule);
35
+ }, [cartData.cartItems, initData === null || initData === void 0 ? void 0 : initData.shop, summaryModule]);
33
36
  var contextValue = {
34
37
  // 商品总价
35
38
  subtotal: summaryData.subtotal,
@@ -38,6 +41,8 @@ export var SummaryProvider = function SummaryProvider(_ref) {
38
41
  taxTitle: summaryData.taxTitle,
39
42
  totalTaxFee: summaryData.totalTaxFee,
40
43
  isPriceIncludeTax: summaryData.isPriceIncludeTax,
44
+ taxRate: summaryData.taxRate,
45
+ surcharge: summaryData.surcharge,
41
46
  deposit: summaryData.deposit,
42
47
  isAgreeDepositPolicy: isAgreeDepositPolicy,
43
48
  setIsAgreeDepositPolicy: setIsAgreeDepositPolicy,
@@ -0,0 +1,58 @@
1
+ interface CartItem {
2
+ price: number | string;
3
+ quantity?: number;
4
+ [k: string]: any;
5
+ }
6
+ interface PriceDetail {
7
+ subtotal: string;
8
+ total: string;
9
+ taxTitle?: string;
10
+ totalTaxFee?: string;
11
+ isPriceIncludeTax?: 0 | 1;
12
+ taxRate?: number;
13
+ surcharge?: any;
14
+ deposit?: {
15
+ total: string;
16
+ protocols: any[];
17
+ hasDeposit: boolean;
18
+ };
19
+ }
20
+ /**
21
+ * 计算商品小计(不含其他费用)
22
+ * @param items - 购物车商品数组
23
+ * @returns 商品总价字符串,保留2位小数
24
+ */
25
+ export declare const calculateSubtotal: (items: CartItem[]) => string;
26
+ /**
27
+ * @description: 将购物车数据格式化成summaryModule需要的格式
28
+ * @param {any} items 购物车数据
29
+ * @return {*}
30
+ */
31
+ export declare const formatCartsToSummaryModule: (items: any[]) => any[];
32
+ /**
33
+ * @title: 单个商品的税费
34
+ * @description:
35
+ * 单个商品的税费 = 商品销售单价(折扣后) * 税率 * is_charge_tax /( 1+ 税率 * is_price_include_tax)
36
+ * $taxFee = $price * $taxRate * $isChargeTax / (1 + $taxRate * $isPriceIncludeTax);
37
+ * @return {*}
38
+ * @Author: xiangfeng.xue
39
+ */
40
+ export declare const calculateTaxFee: (shopInfo: any, items: CartItem[], summaryModule: any) => any;
41
+ /**
42
+ * 计算所有价格明细
43
+ * @param items - 购物车商品数组
44
+ * @param options - 其他费用配置
45
+ * @returns 价格明细对象
46
+ */
47
+ export declare const calculatePriceDetails: (shopInfo: any, items: CartItem[], summaryModule: any) => PriceDetail;
48
+ /**
49
+ * @title: 计算定金
50
+ * @param items - 购物车商品数组
51
+ * @returns 定金字符串,保留2位小数
52
+ */
53
+ export declare const calculateDeposit: (items: CartItem[]) => {
54
+ total: string;
55
+ protocols: any[];
56
+ hasDeposit: never;
57
+ } | undefined;
58
+ export {};
@@ -1,3 +1,12 @@
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
+ var _excluded = ["selectedBundle", "selectedOptions"];
3
+ 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; }
4
+ 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; }
5
+ 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; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ 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); }
8
+ 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; }
9
+ 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; }
1
10
  import Decimal from 'decimal.js';
2
11
  /**
3
12
  * 计算商品小计(不含其他费用)
@@ -17,6 +26,24 @@ export var calculateSubtotal = function calculateSubtotal(items) {
17
26
  return subtotal.toFixed(2);
18
27
  };
19
28
 
29
+ /**
30
+ * @description: 将购物车数据格式化成summaryModule需要的格式
31
+ * @param {any} items 购物车数据
32
+ * @return {*}
33
+ */
34
+ export var formatCartsToSummaryModule = function formatCartsToSummaryModule(items) {
35
+ if (!Array.isArray(items) || !(items !== null && items !== void 0 && items.length)) return [];
36
+ return items.map(function (item) {
37
+ var selectedBundle = item.selectedBundle,
38
+ selectedOptions = item.selectedOptions,
39
+ rest = _objectWithoutProperties(item, _excluded);
40
+ return _objectSpread(_objectSpread({}, rest), {}, {
41
+ bundle: selectedBundle || [],
42
+ option: selectedOptions || []
43
+ });
44
+ });
45
+ };
46
+
20
47
  /**
21
48
  * @title: 单个商品的税费
22
49
  * @description:
@@ -25,7 +52,7 @@ export var calculateSubtotal = function calculateSubtotal(items) {
25
52
  * @return {*}
26
53
  * @Author: xiangfeng.xue
27
54
  */
28
- export var calculateTaxFee = function calculateTaxFee(shopInfo, items) {
55
+ export var calculateTaxFee = function calculateTaxFee(shopInfo, items, summaryModule) {
29
56
  if (!(items !== null && items !== void 0 && items.length)) {
30
57
  return '0.00';
31
58
  }
@@ -33,12 +60,22 @@ export var calculateTaxFee = function calculateTaxFee(shopInfo, items) {
33
60
  is_price_include_tax = _ref.is_price_include_tax,
34
61
  tax_rate = _ref.tax_rate;
35
62
  console.log('shopInfo>>>', is_price_include_tax, tax_rate);
36
- var totalTaxFee = items.reduce(function (sum, item) {
37
- var price = new Decimal(item.total || 0);
38
- var taxRate = new Decimal(tax_rate || 0).div(100);
39
- var productTaxRate = price.times(taxRate).times((item === null || item === void 0 ? void 0 : item.is_charge_tax) || 0).div(taxRate.times(is_price_include_tax || 0).plus(1));
40
- return sum.plus(productTaxRate);
41
- }, new Decimal(0));
63
+ // const totalTaxFee = items.reduce((sum, item) => {
64
+ // const price = new Decimal(item.price || 0);
65
+ // const taxRate = new Decimal(tax_rate || 0).div(100);
66
+ // const productTaxRate = price
67
+ // .times(taxRate)
68
+ // .times(item?.is_charge_tax || 0)
69
+ // .div(taxRate.times(is_price_include_tax || 0).plus(1));
70
+
71
+ // return sum.plus(productTaxRate);
72
+ // }, new Decimal(0));
73
+ var subtotal = new Decimal(calculateSubtotal(items));
74
+ var totalTax = summaryModule.getTaxforUtils(items, {
75
+ tax_rate: Number(tax_rate),
76
+ is_price_include_tax: Number(is_price_include_tax || 0)
77
+ }, subtotal);
78
+ var totalTaxFee = totalTax === null || totalTax === void 0 ? void 0 : totalTax.tax;
42
79
  return totalTaxFee;
43
80
  };
44
81
 
@@ -48,13 +85,21 @@ export var calculateTaxFee = function calculateTaxFee(shopInfo, items) {
48
85
  * @param options - 其他费用配置
49
86
  * @returns 价格明细对象
50
87
  */
51
- export var calculatePriceDetails = function calculatePriceDetails(shopInfo, items) {
88
+ export var calculatePriceDetails = function calculatePriceDetails(shopInfo, items, summaryModule) {
89
+ // 小计
52
90
  var subtotal = new Decimal(calculateSubtotal(items));
53
- var totalTaxFee = new Decimal(calculateTaxFee(shopInfo, items));
54
- console.log('totalTaxFee', totalTaxFee.toFixed(2));
91
+ var _carts = formatCartsToSummaryModule(items);
92
+ // 附加费
93
+ var surcharge = summaryModule.getSurchargeforUtils(_carts);
94
+ var surchargeFee = new Decimal((surcharge === null || surcharge === void 0 ? void 0 : surcharge.surchargeAmount) || 0);
95
+ // 税费
96
+ var totalTaxFee = new Decimal(calculateTaxFee(shopInfo, _carts, summaryModule));
97
+ // 税率
98
+ var taxRate = new Decimal((shopInfo === null || shopInfo === void 0 ? void 0 : shopInfo.tax_rate) || 0).div(100);
55
99
 
56
100
  // 计算总价
57
101
  var total = shopInfo !== null && shopInfo !== void 0 && shopInfo.is_price_include_tax ? subtotal : subtotal.plus(totalTaxFee);
102
+ total = total.plus(surchargeFee);
58
103
 
59
104
  // 计算定金
60
105
  var deposit = calculateDeposit(items);
@@ -64,6 +109,8 @@ export var calculatePriceDetails = function calculatePriceDetails(shopInfo, item
64
109
  taxTitle: shopInfo === null || shopInfo === void 0 ? void 0 : shopInfo.tax_title,
65
110
  totalTaxFee: totalTaxFee.toFixed(2),
66
111
  isPriceIncludeTax: shopInfo === null || shopInfo === void 0 ? void 0 : shopInfo.is_price_include_tax,
112
+ taxRate: taxRate.toNumber(),
113
+ surcharge: surcharge,
67
114
  deposit: deposit
68
115
  };
69
116
  };
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const CartItem: ({ onNext, renderContactInfo }: any) => JSX.Element;
4
3
  export default CartItem;
@@ -1,4 +1,10 @@
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
+ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
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); }
5
+ function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
6
+ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
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; }
2
8
  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; }
3
9
  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); } }
4
10
  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); }); }; }
@@ -11,12 +17,12 @@ import React, { useMemo } from 'react';
11
17
  import { isMobile, locales } from '@pisell/utils';
12
18
  import ShoppingCart from "../../../../shoppingCart";
13
19
  import ContinueButton from "../ContinueButton";
20
+ import { SubTotal } from "../../../../../index";
14
21
  import { useAppointmentBooking } from "../../../hooks";
15
22
  import { useAppointmentBookingContext } from "../../../context";
16
23
  import { useAppointmentBookingAccount, useAppointmentBookingResource, useAppointmentBookingSetting, useAppointmentBookingLogin, contextUtils } from "../../../hooks";
17
24
  import { formatHolder, formatCurrentUser, openForm, getMultiResources, updateCartResources } from "../../../utils";
18
25
  import VoucherCard from "../../Voucher";
19
- import Total from "./Total";
20
26
  import Deposit from "../../Deposit";
21
27
  import { handleAddHolder } from "../utils";
22
28
  import "./index.less";
@@ -48,8 +54,13 @@ var CartItem = function CartItem(_ref) {
48
54
  var _useAppointmentBookin4 = useAppointmentBookingLogin(),
49
55
  isLogin = _useAppointmentBookin4.isLogin;
50
56
  var utils = contextUtils();
51
- var businessUtils = utils.businessUtils;
52
- var deposit = summary.deposit;
57
+ var businessUtils = utils.businessUtils,
58
+ translation = utils.translation;
59
+ var taxTitle = summary.taxTitle,
60
+ totalTaxFee = summary.totalTaxFee,
61
+ isPriceIncludeTax = summary.isPriceIncludeTax,
62
+ total = summary.total,
63
+ deposit = summary.deposit;
53
64
 
54
65
  /**
55
66
  * @title: 当前客户
@@ -223,6 +234,45 @@ var CartItem = function CartItem(_ref) {
223
234
  return carts;
224
235
  }
225
236
  }, [carts, currentSelectedResources, currentStepParams === null || currentStepParams === void 0 ? void 0 : currentStepParams.key, isErrorHolder]);
237
+
238
+ /**
239
+ * @description: 结算列表数据
240
+ * @param {*} useMemo
241
+ * @return {*}
242
+ */
243
+ var subTotalList = useMemo(function () {
244
+ var hideDeposit = (carts === null || carts === void 0 ? void 0 : carts.length) === 0 || !(deposit !== null && deposit !== void 0 && deposit.hasDeposit);
245
+ var surcharge = ((summary === null || summary === void 0 ? void 0 : summary.surcharge) || []).map(function (d, index) {
246
+ return {
247
+ key: "custom_surcharge_".concat(index),
248
+ label: translation(d === null || d === void 0 ? void 0 : d.name),
249
+ value: d.amount
250
+ };
251
+ });
252
+ return [{
253
+ key: 'deposit',
254
+ value: deposit === null || deposit === void 0 ? void 0 : deposit.total,
255
+ label: locales.getText('pisell2.appointment.deposit'),
256
+ hidden: hideDeposit
257
+ }, {
258
+ key: 'sub_total',
259
+ value: summary === null || summary === void 0 ? void 0 : summary.subtotal
260
+ }].concat(_toConsumableArray(surcharge), [{
261
+ key: 'tax',
262
+ value: totalTaxFee,
263
+ hidden: Number(totalTaxFee) <= 0,
264
+ tax: {
265
+ rate: Number((summary === null || summary === void 0 ? void 0 : summary.taxRate) / 100),
266
+ is_price_include_tax: isPriceIncludeTax,
267
+ title: taxTitle
268
+ }
269
+ }, {
270
+ key: 'custom_total',
271
+ value: total,
272
+ label: locales.getText('pisell2.event.total'),
273
+ bold: !!hideDeposit
274
+ }]);
275
+ }, [total, summary, carts === null || carts === void 0 ? void 0 : carts.length]);
226
276
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
227
277
  className: "appointment-cart-item-wrap ".concat(isMobile() ? 'appointment-cart-mobile-item-wrap' : '')
228
278
  }, /*#__PURE__*/React.createElement("div", {
@@ -256,7 +306,15 @@ var CartItem = function CartItem(_ref) {
256
306
  }, hasGoodPassApp || hasDiscountCardApp ? /*#__PURE__*/React.createElement(VoucherCard, {
257
307
  currentUser: currentUser,
258
308
  products: carts
259
- }) : null, /*#__PURE__*/React.createElement(Total, null), (carts === null || carts === void 0 ? void 0 : carts.length) > 0 && deposit !== null && deposit !== void 0 && deposit.hasDeposit ? /*#__PURE__*/React.createElement(Deposit, null) : null, /*#__PURE__*/React.createElement(ContinueButton, {
309
+ }) : null, /*#__PURE__*/React.createElement(SubTotal, {
310
+ list: subTotalList,
311
+ style: {
312
+ padding: 0
313
+ },
314
+ children: !!((carts === null || carts === void 0 ? void 0 : carts.length) > 0 && deposit !== null && deposit !== void 0 && deposit.hasDeposit) ? /*#__PURE__*/React.createElement(Deposit, {
315
+ showTitle: false
316
+ }) : null
317
+ }), /*#__PURE__*/React.createElement(ContinueButton, {
260
318
  onNext: onNext
261
319
  }))));
262
320
  };
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Layout: () => JSX.Element;
4
3
  export default Layout;
@@ -1,9 +1,13 @@
1
1
  import './index.less';
2
+ interface DepositProps {
3
+ showTitle?: boolean;
4
+ }
2
5
  export declare const DepositContent: (props: {
3
6
  isAgreeDepositPolicy: boolean;
4
7
  setIsAgreeDepositPolicy: (value: boolean) => void;
5
8
  deposit: any;
6
9
  depositProtocolRequest?: any;
10
+ showTitle?: boolean | undefined;
7
11
  }) => JSX.Element;
8
- declare const Deposit: () => JSX.Element;
12
+ declare const Deposit: (props: DepositProps) => JSX.Element;
9
13
  export default Deposit;