@pisell/private-materials 3.4.3 → 3.4.4

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 (183) 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 +13 -13
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +4 -4
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +7 -7
  11. package/es/components/Sales/Cart/index.js +5 -1
  12. package/es/components/Sales/Cart/utils.d.ts +40 -0
  13. package/es/components/Sales/Cart/utils.js +187 -0
  14. package/es/components/Sales/Checkout/index.d.ts +4 -0
  15. package/es/components/Sales/Checkout/index.js +52 -8
  16. package/es/components/Sales/Checkout/serve.d.ts +13 -0
  17. package/es/components/Sales/Checkout/serve.js +16 -2
  18. package/es/components/Sales/Checkout/utils.d.ts +1 -0
  19. package/es/components/Sales/Checkout/utils.js +9 -2
  20. package/es/components/Sales/Customer/index.d.ts +25 -0
  21. package/es/components/Sales/Event/Detail.d.ts +1 -0
  22. package/es/components/Sales/Event/Detail.js +45 -11
  23. package/es/components/Sales/Event/serve.d.ts +10 -0
  24. package/es/components/Sales/Event/serve.js +25 -0
  25. package/es/components/Sales/Summary/index.d.ts +10 -0
  26. package/es/components/Sales/Summary/index.js +17 -2
  27. package/es/components/Sales/Summary/serve.d.ts +1 -0
  28. package/es/components/Sales/Summary/serve.js +6 -0
  29. package/es/components/Sales/Summary/utils.d.ts +16 -1
  30. package/es/components/Sales/Summary/utils.js +43 -1
  31. package/es/components/appointmentBooking/components/Content/index.js +15 -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/Form/index.d.ts +4 -0
  35. package/es/components/appointmentBooking/components/Form/utils.d.ts +8 -0
  36. package/es/components/appointmentBooking/deposit/components/PolicyModal/index.js +25 -20
  37. package/es/components/appointmentBooking/deposit/index.js +4 -2
  38. package/es/components/booking/components/TabProduct/tabs/index.js +1 -5
  39. package/es/components/booking/components/browserSelect/index.js +1 -1
  40. package/es/components/booking/components/footer/index.js +32 -24
  41. package/es/components/booking/forms/model.js +5 -5
  42. package/es/components/booking/info/service/Lists.d.ts +2 -0
  43. package/es/components/booking/info/service/addService/utils.d.ts +1 -1
  44. package/es/components/booking/info/service/like/index.js +1 -1
  45. package/es/components/booking/info/utils.js +1 -1
  46. package/es/components/booking/info2/service/addService/utils.d.ts +1 -1
  47. package/es/components/booking/info2/service/index.d.ts +4 -0
  48. package/es/components/booking/info2/utils.d.ts +4 -0
  49. package/es/components/booking/info2/utilsByBooking.js +9 -3
  50. package/es/components/booking/materiels/startTime/index.js +1 -1
  51. package/es/components/booking/notes/NoteBlock/NoteItem/index.js +1 -1
  52. package/es/components/booking/notes/NoteBlock/index.js +11 -11
  53. package/es/components/booking/notes/model.js +5 -5
  54. package/es/components/booking/payments/model.js +5 -5
  55. package/es/components/booking/utils.d.ts +2 -2
  56. package/es/components/eftposPay/amount.d.ts +1 -1
  57. package/es/components/eftposPay/device.d.ts +1 -1
  58. package/es/components/eftposPay/hooks.d.ts +2 -2
  59. package/es/components/eftposPay/store/index.d.ts +5 -5
  60. package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +29 -17
  61. package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +2 -0
  62. package/es/components/eventBooking/components/Provider/Cart/Deposit/index.js +17 -0
  63. package/es/components/eventBooking/components/Provider/Cart/Item/Total.js +10 -6
  64. package/es/components/eventBooking/components/Provider/Cart/Item/index.js +4 -2
  65. package/es/components/eventBooking/components/bookingDetailModal/index.js +6 -3
  66. package/es/components/eventBooking/locales.d.ts +24 -0
  67. package/es/components/eventBooking/locales.js +27 -3
  68. package/es/components/listComponent/index.js +5 -5
  69. package/es/components/pay/toC/PaymentMethods/GlobePayAliPayH5/index.js +18 -3
  70. package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +1 -1
  71. package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.js +7 -2
  72. package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.less +8 -0
  73. package/es/components/pay/toC/PaymentMethods/SuperPayAliPayH5/index.js +18 -3
  74. package/es/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +113 -0
  75. package/es/components/pay/toC/locales.d.ts +3 -0
  76. package/es/components/pay/toC/locales.js +3 -0
  77. package/es/components/pay/toC/utils.d.ts +57 -0
  78. package/es/components/productExtension/card/index.js +3 -3
  79. package/es/components/productExtension/fields/Actor/CutOffTime/index.js +1 -1
  80. package/es/components/productExtension/fields/Forms/index.js +12 -12
  81. package/es/components/productExtension/fields/SelectProducts/ProductItemPreview/index.js +1 -1
  82. package/es/components/productExtension/fields/SelectProducts/server.js +2 -2
  83. package/es/components/productExtension/fields/SelectResourcesTable/server.js +2 -2
  84. package/es/components/productExtension/server.js +2 -2
  85. package/es/components/ruleSetting/ruleBorder/index.js +1 -1
  86. package/es/components/schedules/calendar/index.js +4 -4
  87. package/es/components/schedules/calendar/serve.js +2 -2
  88. package/es/components/schedules/components/CurrentDay/index.js +5 -5
  89. package/es/components/schedules/components/CurrentDay/serve.js +2 -2
  90. package/es/components/schedules/components/DropdownSort/index.js +1 -1
  91. package/es/components/schedules/components/ResourceList/index.js +1 -1
  92. package/es/components/schedules/components/Search/index.js +5 -5
  93. package/es/components/schedules/model.js +5 -5
  94. package/es/components/schedules/openHours/index.js +1 -1
  95. package/es/components/schedules/openHours/serve.js +2 -2
  96. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.js +1 -1
  97. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.js +5 -5
  98. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.js +4 -4
  99. package/es/components/schedules/products/ProductDetailDrawer/index.js +3 -3
  100. package/es/components/schedules/products/serve.js +2 -2
  101. package/es/components/schedules/products/utils.js +5 -5
  102. package/es/components/schedules/resources/detail/detailContent.js +2 -2
  103. package/es/components/schedules/resources/detail/index.js +10 -10
  104. package/es/components/schedules/resources/list/index.js +2 -2
  105. package/es/components/schedules/resources/relationProduct/index.js +1 -1
  106. package/es/components/schedules/resources/serve.js +2 -2
  107. package/es/components/schedules/schedules/ScheduleDetailDrawer/index.js +9 -9
  108. package/es/components/schedules/utils.d.ts +1 -1
  109. package/es/components/schedules/utils.js +4 -4
  110. package/es/components/selectModal/index.js +2 -2
  111. package/es/components/shoppingCart/components/Cart/Product.d.ts +3 -0
  112. package/es/components/ticketBooking/components/menuBar/index.js +38 -2
  113. package/es/components/ticketBooking/components/menuBar/index.less +8 -0
  114. package/es/components/ticketBooking/locales.d.ts +174 -0
  115. package/es/components/ticketBooking/locales.js +6 -3
  116. package/es/hooks/useComponents.js +1 -1
  117. package/es/utils/index.d.ts +1 -1
  118. package/lib/components/Sales/Cart/index.js +1 -0
  119. package/lib/components/Sales/Cart/utils.d.ts +40 -0
  120. package/lib/components/Sales/Cart/utils.js +129 -0
  121. package/lib/components/Sales/Checkout/index.d.ts +4 -0
  122. package/lib/components/Sales/Checkout/index.js +39 -7
  123. package/lib/components/Sales/Checkout/serve.d.ts +13 -0
  124. package/lib/components/Sales/Checkout/serve.js +7 -2
  125. package/lib/components/Sales/Checkout/utils.d.ts +1 -0
  126. package/lib/components/Sales/Checkout/utils.js +5 -2
  127. package/lib/components/Sales/Customer/index.d.ts +25 -0
  128. package/lib/components/Sales/Event/Detail.d.ts +1 -0
  129. package/lib/components/Sales/Event/Detail.js +37 -12
  130. package/lib/components/Sales/Event/serve.d.ts +10 -0
  131. package/lib/components/Sales/Event/serve.js +7 -0
  132. package/lib/components/Sales/Summary/index.d.ts +10 -0
  133. package/lib/components/Sales/Summary/index.js +7 -1
  134. package/lib/components/Sales/Summary/serve.d.ts +1 -0
  135. package/lib/components/Sales/Summary/serve.js +32 -0
  136. package/lib/components/Sales/Summary/utils.d.ts +16 -1
  137. package/lib/components/Sales/Summary/utils.js +30 -1
  138. package/lib/components/appointmentBooking/components/Content/index.js +6 -1
  139. package/lib/components/appointmentBooking/components/Deposit/index.d.ts +6 -0
  140. package/lib/components/appointmentBooking/components/Deposit/index.js +36 -4
  141. package/lib/components/appointmentBooking/components/Form/index.d.ts +4 -0
  142. package/lib/components/appointmentBooking/components/Form/utils.d.ts +8 -0
  143. package/lib/components/appointmentBooking/deposit/components/PolicyModal/index.js +8 -4
  144. package/lib/components/appointmentBooking/deposit/index.js +4 -2
  145. package/lib/components/booking/components/footer/index.js +24 -11
  146. package/lib/components/booking/info/service/Lists.d.ts +2 -0
  147. package/lib/components/booking/info/service/addService/utils.d.ts +1 -1
  148. package/lib/components/booking/info/utils.js +3 -1
  149. package/lib/components/booking/info2/service/addService/utils.d.ts +1 -1
  150. package/lib/components/booking/info2/service/index.d.ts +4 -0
  151. package/lib/components/booking/info2/utils.d.ts +4 -0
  152. package/lib/components/booking/info2/utilsByBooking.js +4 -1
  153. package/lib/components/booking/utils.d.ts +2 -2
  154. package/lib/components/eftposPay/amount.d.ts +1 -1
  155. package/lib/components/eftposPay/device.d.ts +1 -1
  156. package/lib/components/eftposPay/hooks.d.ts +2 -2
  157. package/lib/components/eftposPay/store/index.d.ts +5 -5
  158. package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +16 -4
  159. package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +2 -0
  160. package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.js +55 -0
  161. package/lib/components/eventBooking/components/Provider/Cart/Item/Total.js +8 -5
  162. package/lib/components/eventBooking/components/Provider/Cart/Item/index.js +4 -2
  163. package/lib/components/eventBooking/components/bookingDetailModal/index.js +4 -3
  164. package/lib/components/eventBooking/locales.d.ts +24 -0
  165. package/lib/components/eventBooking/locales.js +27 -3
  166. package/lib/components/pay/toC/PaymentMethods/GlobePayAliPayH5/index.js +13 -1
  167. package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +1 -1
  168. package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.js +2 -2
  169. package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.less +8 -0
  170. package/lib/components/pay/toC/PaymentMethods/SuperPayAliPayH5/index.js +13 -1
  171. package/lib/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +113 -0
  172. package/lib/components/pay/toC/locales.d.ts +3 -0
  173. package/lib/components/pay/toC/locales.js +3 -0
  174. package/lib/components/pay/toC/utils.d.ts +57 -0
  175. package/lib/components/schedules/utils.d.ts +1 -1
  176. package/lib/components/schedules/utils.js +1 -1
  177. package/lib/components/shoppingCart/components/Cart/Product.d.ts +3 -0
  178. package/lib/components/ticketBooking/components/menuBar/index.js +42 -2
  179. package/lib/components/ticketBooking/components/menuBar/index.less +8 -0
  180. package/lib/components/ticketBooking/locales.d.ts +174 -0
  181. package/lib/components/ticketBooking/locales.js +6 -3
  182. package/lib/utils/index.d.ts +1 -1
  183. package/package.json +4 -4
@@ -71,6 +71,14 @@ declare const _default: {
71
71
  'pisell2.event.capacity.limit.reached.tip': string;
72
72
  'pisell2.event.schedule.item.expand': string;
73
73
  'pisell2.event.schedule.item.collapse': string;
74
+ 'pisell2.appointment.deposit': string;
75
+ 'pisell2.appointment.deposit.agreed': string;
76
+ 'pisell2.appointment.deposit.agree.policy': string;
77
+ 'pisell2.appointment.deposit.and': string;
78
+ 'pisell2.appointment.deposit.amount.tip1': string;
79
+ 'pisell2.appointment.deposit.amount.tip2': string;
80
+ 'pisell2.appointment.deposit.close': string;
81
+ 'pisell2.appointment.booking.empty.data': string;
74
82
  };
75
83
  'zh-CN': {
76
84
  'pisell2.event.calendar.limit.unavailable': string;
@@ -144,6 +152,14 @@ declare const _default: {
144
152
  'pisell2.event.capacity.limit.reached.tip': string;
145
153
  'pisell2.event.schedule.item.expand': string;
146
154
  'pisell2.event.schedule.item.collapse': string;
155
+ 'pisell2.appointment.deposit': string;
156
+ 'pisell2.appointment.deposit.agreed': string;
157
+ 'pisell2.appointment.deposit.agree.policy': string;
158
+ 'pisell2.appointment.deposit.and': string;
159
+ 'pisell2.appointment.deposit.amount.tip1': string;
160
+ 'pisell2.appointment.deposit.amount.tip2': string;
161
+ 'pisell2.appointment.deposit.close': string;
162
+ 'pisell2.appointment.booking.empty.data': string;
147
163
  };
148
164
  'zh-HK': {
149
165
  'pisell2.event.calendar.limit.unavailable': string;
@@ -217,6 +233,14 @@ declare const _default: {
217
233
  'pisell2.event.capacity.limit.reached.tip': string;
218
234
  'pisell2.event.schedule.item.expand': string;
219
235
  'pisell2.event.schedule.item.collapse': string;
236
+ 'pisell2.appointment.deposit': string;
237
+ 'pisell2.appointment.deposit.agreed': string;
238
+ 'pisell2.appointment.deposit.agree.policy': string;
239
+ 'pisell2.appointment.deposit.and': string;
240
+ 'pisell2.appointment.deposit.amount.tip1': string;
241
+ 'pisell2.appointment.deposit.amount.tip2': string;
242
+ 'pisell2.appointment.deposit.close': string;
243
+ 'pisell2.appointment.booking.empty.data': string;
220
244
  };
221
245
  };
222
246
  export default _default;
@@ -94,7 +94,15 @@ var locales_default = {
94
94
  "pisell2.event.capacity.limit.reached.title": "Capacity limit reached",
95
95
  "pisell2.event.capacity.limit.reached.tip": "One or more events in your cart are no longer available due to full capacity. Please remove unavailable events from your cart to complete checkout.",
96
96
  "pisell2.event.schedule.item.expand": "See more",
97
- "pisell2.event.schedule.item.collapse": "See less"
97
+ "pisell2.event.schedule.item.collapse": "See less",
98
+ "pisell2.appointment.deposit": "Deposit",
99
+ "pisell2.appointment.deposit.agreed": "I have read and agree to the ",
100
+ "pisell2.appointment.deposit.agree.policy": "You need to agree the policy to proceed",
101
+ "pisell2.appointment.deposit.and": " & ",
102
+ "pisell2.appointment.deposit.amount.tip1": " needs to be paid as deposit.",
103
+ "pisell2.appointment.deposit.amount.tip2": " ",
104
+ "pisell2.appointment.deposit.close": "Close",
105
+ "pisell2.appointment.booking.empty.data": "No data"
98
106
  },
99
107
  "zh-CN": {
100
108
  "pisell2.event.calendar.limit.unavailable": "不可预约",
@@ -167,7 +175,15 @@ var locales_default = {
167
175
  "pisell2.event.capacity.limit.reached.title": "活动名额已满",
168
176
  "pisell2.event.capacity.limit.reached.tip": "购物车中有一个或多个活动已达预约上限,请将已满额的活动从购物车中移除后再完成结算。",
169
177
  "pisell2.event.schedule.item.expand": "查看更多",
170
- "pisell2.event.schedule.item.collapse": "收起"
178
+ "pisell2.event.schedule.item.collapse": "收起",
179
+ "pisell2.appointment.deposit": "定金",
180
+ "pisell2.appointment.deposit.agreed": "我已阅读并同意 ",
181
+ "pisell2.appointment.deposit.agree.policy": "您需要同意协议才能继续",
182
+ "pisell2.appointment.deposit.and": " 和 ",
183
+ "pisell2.appointment.deposit.amount.tip1": "请支付 ",
184
+ "pisell2.appointment.deposit.amount.tip2": " 定金。",
185
+ "pisell2.appointment.deposit.close": "关闭",
186
+ "pisell2.appointment.booking.empty.data": "暂无数据"
171
187
  },
172
188
  "zh-HK": {
173
189
  "pisell2.event.calendar.limit.unavailable": "不可預約",
@@ -240,6 +256,14 @@ var locales_default = {
240
256
  "pisell2.event.capacity.limit.reached.title": "活動名額已滿",
241
257
  "pisell2.event.capacity.limit.reached.tip": "購物車中有一個或多個活動已達預約上限,請將已滿額的活動從購物車中移除後再完成結算。",
242
258
  "pisell2.event.schedule.item.expand": "查看更多",
243
- "pisell2.event.schedule.item.collapse": "收起"
259
+ "pisell2.event.schedule.item.collapse": "收起",
260
+ "pisell2.appointment.deposit": "定金",
261
+ "pisell2.appointment.deposit.agreed": "我已閱讀並同意 ",
262
+ "pisell2.appointment.deposit.agree.policy": "您需要同意協議才能繼續",
263
+ "pisell2.appointment.deposit.and": " 和 ",
264
+ "pisell2.appointment.deposit.amount.tip1": "請支付 ",
265
+ "pisell2.appointment.deposit.amount.tip2": " 定金。",
266
+ "pisell2.appointment.deposit.close": "关闭",
267
+ "pisell2.appointment.booking.empty.data": "暫無數據"
244
268
  }
245
269
  };
@@ -37,11 +37,14 @@ var import_materials = require("@pisell/materials");
37
37
  var import_utils = require("@pisell/utils");
38
38
  var import_ThreedsLoading = __toESM(require("../MWCreditCard/TDSPay/ThreedsLoading"));
39
39
  var import_serve = require("./serve");
40
+ var import_model = require("../../model");
40
41
  var import_payGroup = require("../../payGroup");
41
42
  var import_index = require("./index.less");
42
43
  var GlobePayAliPayH5 = (props, ref) => {
44
+ const { state } = (0, import_react.useContext)(import_model.Context);
43
45
  const { onChange } = props;
44
46
  const [open, setOpen] = (0, import_react.useState)(false);
47
+ const [showSuccessBackButton, setShowSuccessBackButton] = (0, import_react.useState)(false);
45
48
  const init = async ({ payGroup }) => {
46
49
  setOpen(true);
47
50
  const values = (0, import_payGroup.getPayGroupParamsFromStorage)(payGroup.order_id);
@@ -54,6 +57,7 @@ var GlobePayAliPayH5 = (props, ref) => {
54
57
  const url = data.url || (data == null ? void 0 : data.pay_url);
55
58
  if (url) {
56
59
  (0, import_payGroup.setPayNumber)(payGroup == null ? void 0 : payGroup.order_id, data == null ? void 0 : data.pay_number);
60
+ setShowSuccessBackButton(true);
57
61
  window.location.href = url;
58
62
  } else {
59
63
  setOpen(false);
@@ -68,6 +72,12 @@ var GlobePayAliPayH5 = (props, ref) => {
68
72
  init
69
73
  })
70
74
  );
75
+ const handleSuccessBack = () => {
76
+ var _a;
77
+ (_a = state.payCallback) == null ? void 0 : _a.call(state, {
78
+ key: "success"
79
+ });
80
+ };
71
81
  return /* @__PURE__ */ import_react.default.createElement(
72
82
  import_materials.PisellModal,
73
83
  {
@@ -81,7 +91,9 @@ var GlobePayAliPayH5 = (props, ref) => {
81
91
  /* @__PURE__ */ import_react.default.createElement("div", { className: "" }, /* @__PURE__ */ import_react.default.createElement(
82
92
  import_ThreedsLoading.default,
83
93
  {
84
- title: import_utils.locales.getText("tocPay.text.redirectingToAlipay")
94
+ title: import_utils.locales.getText("tocPay.text.redirectingToAlipay"),
95
+ onSuccessBack: handleSuccessBack,
96
+ showSuccessBackButton
85
97
  }
86
98
  ))
87
99
  );
@@ -1,3 +1,3 @@
1
1
  import './index.less';
2
- declare const ThreedsLoading: ({ title }: any) => JSX.Element;
2
+ declare const ThreedsLoading: ({ title, showSuccessBackButton, onSuccessBack }: any) => JSX.Element;
3
3
  export default ThreedsLoading;
@@ -36,7 +36,7 @@ var import_react = __toESM(require("react"));
36
36
  var import_useEngineContext = __toESM(require("../../../../../../../hooks/useEngineContext"));
37
37
  var import_index = require("./index.less");
38
38
  var import_utils = require("@pisell/utils");
39
- var ThreedsLoading = ({ title }) => {
39
+ var ThreedsLoading = ({ title, showSuccessBackButton, onSuccessBack }) => {
40
40
  var _a;
41
41
  const context = (0, import_useEngineContext.default)();
42
42
  const { config } = ((_a = context.appHelper) == null ? void 0 : _a.constants) || {};
@@ -47,6 +47,6 @@ var ThreedsLoading = ({ title }) => {
47
47
  src: config.static + "/static/stripe_loading.gif",
48
48
  alt: ""
49
49
  }
50
- ), /* @__PURE__ */ import_react.default.createElement("div", { className: "threeds-loading-title" }, title || import_utils.locales.getText("tocPay.text.waitingForBankVerification")));
50
+ ), /* @__PURE__ */ import_react.default.createElement("div", { className: "threeds-loading-title" }, title || import_utils.locales.getText("tocPay.text.waitingForBankVerification")), showSuccessBackButton && /* @__PURE__ */ import_react.default.createElement("div", { onClick: onSuccessBack, className: "threeds-loading-success-back-button" }, import_utils.locales.getText("tocPay.text.successBack")));
51
51
  };
52
52
  var ThreedsLoading_default = ThreedsLoading;
@@ -21,4 +21,12 @@
21
21
  line-height: 20px;
22
22
  color: #353535;
23
23
  }
24
+
25
+ .threeds-loading-success-back-button {
26
+ margin-top: 20px;
27
+ color: #4b6b99;
28
+ font-size: 15px;
29
+ font-weight: bold;
30
+ line-height: 20px;
31
+ }
24
32
  }
@@ -37,14 +37,17 @@ var import_materials = require("@pisell/materials");
37
37
  var import_utils = require("@pisell/utils");
38
38
  var import_ThreedsLoading = __toESM(require("../MWCreditCard/TDSPay/ThreedsLoading"));
39
39
  var import_serve = require("./serve");
40
+ var import_model = require("../../model");
40
41
  var import_payGroup = require("../../payGroup");
41
42
  var import_index = require("./index.less");
42
43
  var import_useEngineContext = __toESM(require("../../../../../hooks/useEngineContext"));
43
44
  var import_utils2 = require("../../utils");
44
45
  var SuperPayAliPayH5 = (props, ref) => {
45
46
  var _a;
47
+ const { state } = (0, import_react.useContext)(import_model.Context);
46
48
  const { onChange } = props;
47
49
  const [open, setOpen] = (0, import_react.useState)(false);
50
+ const [showSuccessBackButton, setShowSuccessBackButton] = (0, import_react.useState)(false);
48
51
  const context = (0, import_useEngineContext.default)();
49
52
  const { interaction } = (_a = context.appHelper) == null ? void 0 : _a.utils;
50
53
  const init = async ({ payGroup }) => {
@@ -62,6 +65,7 @@ var SuperPayAliPayH5 = (props, ref) => {
62
65
  const data = await (0, import_serve.getAliPayUrl)(payGroup.order_id, values);
63
66
  if (data == null ? void 0 : data.pay_url) {
64
67
  (0, import_payGroup.setPayNumber)(payGroup == null ? void 0 : payGroup.order_id, data == null ? void 0 : data.pay_number);
68
+ setShowSuccessBackButton(true);
65
69
  window.location.href = data == null ? void 0 : data.pay_url;
66
70
  } else {
67
71
  setOpen(false);
@@ -76,6 +80,12 @@ var SuperPayAliPayH5 = (props, ref) => {
76
80
  init
77
81
  })
78
82
  );
83
+ const handleSuccessBack = () => {
84
+ var _a2;
85
+ (_a2 = state.payCallback) == null ? void 0 : _a2.call(state, {
86
+ key: "success"
87
+ });
88
+ };
79
89
  return /* @__PURE__ */ import_react.default.createElement(
80
90
  import_materials.PisellModal,
81
91
  {
@@ -89,7 +99,9 @@ var SuperPayAliPayH5 = (props, ref) => {
89
99
  /* @__PURE__ */ import_react.default.createElement("div", { className: "" }, /* @__PURE__ */ import_react.default.createElement(
90
100
  import_ThreedsLoading.default,
91
101
  {
92
- title: import_utils.locales.getText("tocPay.text.redirectingToAlipay")
102
+ title: import_utils.locales.getText("tocPay.text.redirectingToAlipay"),
103
+ onSuccessBack: handleSuccessBack,
104
+ showSuccessBackButton
93
105
  }
94
106
  ))
95
107
  );
@@ -0,0 +1,113 @@
1
+ export declare type MachineCodeListParams = {
2
+ order_id: number | string;
3
+ available: number;
4
+ prepare_payments: {
5
+ voucher_id: number;
6
+ amount: number;
7
+ tag: string;
8
+ }[];
9
+ filter_prepare_wallet_pass: 1 | 0;
10
+ sale_channel: string;
11
+ other_exact_codes?: string[];
12
+ };
13
+ export declare type WalletPassDataType = {
14
+ id: number;
15
+ shop_id: number;
16
+ customer_id: number;
17
+ code: string;
18
+ encoded: string;
19
+ status: string;
20
+ cover: string;
21
+ tag: string;
22
+ relation_type: string;
23
+ product_id: number;
24
+ limit_status: string;
25
+ sales_status: number;
26
+ par_value: string;
27
+ used_par_value: string;
28
+ start_date: string;
29
+ expire_date: string;
30
+ end_time: string;
31
+ start_time: string;
32
+ created_at: string;
33
+ product_name: string;
34
+ expire_time: string;
35
+ available_max_par_value: string;
36
+ available_max_amount: string;
37
+ recommended_usage_amount: string;
38
+ custom_expire_status: number;
39
+ wallet_pass_usage_unit: WalletPassUsageUnit;
40
+ custom_order_deduct_exhausted: number;
41
+ available_product_status: number;
42
+ available_product_ids: any[];
43
+ available_product_type: string;
44
+ available_num: number;
45
+ available_product_title: string;
46
+ unified_available_status: number;
47
+ unified_messages: UnifiedMessages;
48
+ external_card: any[];
49
+ product: Product;
50
+ shop: Shop;
51
+ wallet_pass_usage?: any;
52
+ balance_par_value: string;
53
+ };
54
+ declare type Shop = {
55
+ id: number;
56
+ name: string;
57
+ default_url: string;
58
+ };
59
+ declare type Product = {
60
+ id: number;
61
+ title: string;
62
+ cover: string;
63
+ is_charge_tax: number;
64
+ };
65
+ declare type UnifiedMessages = {
66
+ title: string;
67
+ desc: string;
68
+ alert: string;
69
+ };
70
+ declare type WalletPassUsageUnit = {
71
+ price: number;
72
+ points: number;
73
+ };
74
+ /**
75
+ * 查询支付识别码列表
76
+ */
77
+ export declare const getMachineCodeList: (params: MachineCodeListParams) => Promise<WalletPassDataType[]>;
78
+ /**
79
+ * 获取推荐的支付识别码
80
+ */
81
+ export declare const getRecommendMachineCodeList: (order_id: number) => Promise<WalletPassDataType[]>;
82
+ /**
83
+ * 搜索支付识别码
84
+ */
85
+ export declare const searchMachineCodeList: (params: {
86
+ order_id: number | string;
87
+ code: string;
88
+ sale_channel: string;
89
+ prepare_payments: {
90
+ voucher_id: number;
91
+ amount: number;
92
+ tag: string;
93
+ }[];
94
+ filter_prepare_wallet_pass: 1 | 0;
95
+ }) => Promise<WalletPassDataType[]>;
96
+ /**
97
+ * walletpass支付
98
+ */
99
+ export declare const walletPassPay: (params: {
100
+ order_id: number | string;
101
+ payment_group_id: number;
102
+ payments: {
103
+ amount: string;
104
+ wallet_pass_use_value: string;
105
+ voucher_id: number;
106
+ tag: string;
107
+ wallet_pass_usage_unit: {
108
+ price: number;
109
+ points: number;
110
+ };
111
+ }[];
112
+ }) => Promise<WalletPassDataType[]>;
113
+ export {};
@@ -35,6 +35,7 @@ declare const _default: {
35
35
  'tocPay.text.done': string;
36
36
  'tocPay.text.manageCard': string;
37
37
  'tocPay.text.waitingForBankVerification': string;
38
+ 'tocPay.text.successBack': string;
38
39
  'tocPay.text.redirectingToAlipay': string;
39
40
  'tocPay.text.redirectingToPaypal': string;
40
41
  'tocPay.text.redirectingToWeChatPay': string;
@@ -130,6 +131,7 @@ declare const _default: {
130
131
  'tocPay.text.done': string;
131
132
  'tocPay.text.manageCard': string;
132
133
  'tocPay.text.waitingForBankVerification': string;
134
+ 'tocPay.text.successBack': string;
133
135
  'tocPay.text.redirectingToAlipay': string;
134
136
  'tocPay.text.redirectingToPaypal': string;
135
137
  'tocPay.text.redirectingToWeChatPay': string;
@@ -224,6 +226,7 @@ declare const _default: {
224
226
  'tocPay.text.done': string;
225
227
  'tocPay.text.manageCard': string;
226
228
  'tocPay.text.waitingForBankVerification': string;
229
+ 'tocPay.text.successBack': string;
227
230
  'tocPay.text.redirectingToAlipay': string;
228
231
  'tocPay.text.redirectingToPaypal': string;
229
232
  'tocPay.text.redirectingToWeChatPay': string;
@@ -59,6 +59,7 @@ var locales_default = {
59
59
  "tocPay.text.done": "Done",
60
60
  "tocPay.text.manageCard": "Manage card",
61
61
  "tocPay.text.waitingForBankVerification": "Waiting for bank verification, please wait for 5-10 seconds. You may be redirected to the card issuing bank’s verification page to authorize this payment.",
62
+ "tocPay.text.successBack": "Payment completed, return to order",
62
63
  "tocPay.text.redirectingToAlipay": "Redirecting to Alipay, please wait...",
63
64
  "tocPay.text.redirectingToPaypal": "Redirecting to Paypal, please wait...",
64
65
  "tocPay.text.redirectingToWeChatPay": "Redirecting to WeChat Pay, please wait...",
@@ -154,6 +155,7 @@ var locales_default = {
154
155
  "tocPay.text.done": "完成",
155
156
  "tocPay.text.manageCard": "管理卡片",
156
157
  "tocPay.text.waitingForBankVerification": "正在等待银行校验,请静候5-10秒左右。您可能被转入开卡行的持卡人校验页面来授权本次支付。",
158
+ "tocPay.text.successBack": "已支付完成返回查看订单",
157
159
  "tocPay.text.redirectingToAlipay": "正在转入支付宝支付,请稍候...",
158
160
  "tocPay.text.redirectingToPaypal": "正在转入Paypal支付,请稍候...",
159
161
  "tocPay.text.redirectingToWeChatPay": "正在转入微信支付,请稍候...",
@@ -248,6 +250,7 @@ var locales_default = {
248
250
  "tocPay.text.done": "完成",
249
251
  "tocPay.text.manageCard": "管理卡片",
250
252
  "tocPay.text.waitingForBankVerification": "正在等待銀行校驗,請靜候5-10秒左右。您可能被轉入開卡行的持卡人校驗頁面來授權本次支付。",
253
+ "tocPay.text.successBack": "已支付完成返回查看訂單",
251
254
  "tocPay.text.redirectingToAlipay": "正在轉入支付寶支付,請稍候...",
252
255
  "tocPay.text.redirectingToPaypal": "正在轉入Paypal支付,請稍候...",
253
256
  "tocPay.text.redirectingToWeChatPay": "正在轉入微信支付,請稍候...",
@@ -0,0 +1,57 @@
1
+ import { PayGroup } from "./model";
2
+ import { WalletPassDataType } from "./PaymentMethods/WalletPass/serve";
3
+ /**
4
+ * 计算walletPass列表数据的总金额
5
+ * @param list
6
+ */
7
+ export declare const calcWalletPassListAmount: (list: any[]) => any;
8
+ /**
9
+ * 将walletPass列表数据转换为prepare_payments需要的数据格式
10
+ * @param list
11
+ */
12
+ export declare const formatWalletPassList2PreparePayments: (list?: any[]) => {
13
+ voucher_id: any;
14
+ amount: number;
15
+ tag: any;
16
+ }[];
17
+ /**
18
+ * walletPass支付params
19
+ * @param payGroup
20
+ */
21
+ export declare const formatWalletPassParams: (payGroup: PayGroup) => {
22
+ order_id: string;
23
+ payment_group_id: number;
24
+ payments: {
25
+ amount: string;
26
+ wallet_pass_use_value: any;
27
+ voucher_id: any;
28
+ tag: any;
29
+ wallet_pass_usage_unit: any;
30
+ }[];
31
+ };
32
+ /**
33
+ * @title: 获取是否walletPass和三方支付的组合支付
34
+ * @description: 三方支付 (stripe 支付宝 微信 苹果 谷歌)
35
+ * @return: *
36
+ * @Author: shengjie.zuo
37
+ * @Date: 2024-08-30 10:06:17
38
+ */
39
+ export declare const getIsWalletPassAndTripartitePayment: (payGroup: PayGroup) => boolean | 0 | undefined;
40
+ export declare const isFranchiseeShop: (path?: any, history?: any) => any;
41
+ /**
42
+ * @title: 获取当前连锁加盟店铺shopid
43
+ * @description:
44
+ * @param {any} param1
45
+ * @return {*}
46
+ * @Author: chensheng.gu
47
+ * @Date: 2024-08-07 10:04
48
+ */
49
+ export declare const getFranchiseeShopId: (path?: any, history?: any) => number;
50
+ export declare const formatFranchiseeRoute: (url: string, history?: any) => string;
51
+ export declare const getAvailableMaxAmount: (data: WalletPassDataType) => string;
52
+ export declare const clientPayment: (params: {
53
+ order_id: number;
54
+ type: "aliPay" | "wxPay";
55
+ values: any;
56
+ interaction?: any;
57
+ }) => void;
@@ -17,6 +17,6 @@ declare let modal: Omit<ModalStaticFunctions, "warn">;
17
17
  export declare const setModal: (m: Omit<ModalStaticFunctions, "warn">) => void;
18
18
  export declare const saveConfirm: () => Promise<{
19
19
  destroy: () => void;
20
- update: (configUpdate: import("antd/es/modal/interface").ModalFuncProps | ((prevConfig: import("antd/es/modal/interface").ModalFuncProps) => import("antd/es/modal/interface").ModalFuncProps)) => void;
20
+ update: (configUpdate: import("antd").ModalFuncProps | ((prevConfig: import("antd").ModalFuncProps) => import("antd").ModalFuncProps)) => void;
21
21
  }>;
22
22
  export { modal };
@@ -27,8 +27,8 @@ __export(utils_exports, {
27
27
  module.exports = __toCommonJS(utils_exports);
28
28
  var import_utils = require("@pisell/utils");
29
29
  var Request = class {
30
- request = {};
31
30
  constructor() {
31
+ this.request = {};
32
32
  }
33
33
  setRequest(val) {
34
34
  this.request = val;
@@ -0,0 +1,3 @@
1
+ import { ProductProps } from '../../type';
2
+ declare const Product: (props: ProductProps) => JSX.Element;
3
+ export default Product;
@@ -35,8 +35,21 @@ module.exports = __toCommonJS(menuBar_exports);
35
35
  var import_react = __toESM(require("react"));
36
36
  var import_useNetworkStatus = require("../../hooks/useNetworkStatus");
37
37
  var import_index = require("./index.less");
38
+ var import_antd = require("antd");
39
+ var import_icons = require("@ant-design/icons");
40
+ var import_utils = require("@pisell/utils");
41
+ var import_materials = require("@pisell/materials");
38
42
  var index = () => {
39
43
  const status = (0, import_useNetworkStatus.useNetworkStatus)();
44
+ const items = [
45
+ {
46
+ key: "1",
47
+ icon: /* @__PURE__ */ import_react.default.createElement(import_icons.SettingOutlined, null),
48
+ children: [
49
+ { key: "reload", label: import_utils.locales.getText("pisell2.ticket-booking.reload") }
50
+ ]
51
+ }
52
+ ];
40
53
  const getStatusText = (status2) => {
41
54
  switch (status2) {
42
55
  case import_useNetworkStatus.NetworkStatus.GOOD:
@@ -47,7 +60,12 @@ var index = () => {
47
60
  return "Offline";
48
61
  }
49
62
  };
50
- return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-ticket-booking-menu-bar" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "logo-wrapper" }, /* @__PURE__ */ import_react.default.createElement(
63
+ const handleClick = ({ key }) => {
64
+ if (key === "reload") {
65
+ window.location.reload();
66
+ }
67
+ };
68
+ return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-ticket-booking-menu-bar" }, /* @__PURE__ */ import_react.default.createElement("div", null, /* @__PURE__ */ import_react.default.createElement("div", { className: "logo-wrapper" }, /* @__PURE__ */ import_react.default.createElement(
51
69
  "svg",
52
70
  {
53
71
  xmlns: "http://www.w3.org/2000/svg",
@@ -82,6 +100,28 @@ var index = () => {
82
100
  "stroke-linejoin": "round"
83
101
  }
84
102
  )
85
- ))), /* @__PURE__ */ import_react.default.createElement("div", { className: "status-wrapper" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "network-status", style: { background: import_useNetworkStatus.NetworkStatusColor[status] } }, getStatusText(status))));
103
+ )))), /* @__PURE__ */ import_react.default.createElement("div", null, /* @__PURE__ */ import_react.default.createElement(
104
+ import_materials.ConfigProvider,
105
+ {
106
+ theme: {
107
+ components: {
108
+ Menu: {
109
+ collapsedIconSize: 32,
110
+ itemHeight: 48,
111
+ groupTitleFontSize: 16,
112
+ fontSize: 16
113
+ }
114
+ }
115
+ }
116
+ },
117
+ /* @__PURE__ */ import_react.default.createElement(import_antd.Menu, { className: "pisell-ticket-booking-menu", mode: "inline", theme: "dark", inlineCollapsed: true, items, onClick: handleClick })
118
+ )), /* @__PURE__ */ import_react.default.createElement("div", { className: "status-wrapper" }, /* @__PURE__ */ import_react.default.createElement(
119
+ "div",
120
+ {
121
+ className: "network-status",
122
+ style: { background: import_useNetworkStatus.NetworkStatusColor[status] }
123
+ },
124
+ getStatusText(status)
125
+ )));
86
126
  };
87
127
  var menuBar_default = index;
@@ -3,6 +3,14 @@
3
3
  padding-left: 6px;
4
4
  width: 86px;
5
5
  position: relative;
6
+ display: flex;
7
+ flex-direction: column;
8
+ justify-content: space-between;
9
+ padding-bottom: 44px;
10
+
11
+ .pisell-ticket-booking-menu {
12
+ background-color: transparent;
13
+ }
6
14
 
7
15
  .logo-wrapper {
8
16
  margin-top: 24px;