@pisell/private-materials 3.3.21 → 3.3.23

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 (214) 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/render/default/view.js +4 -4
  7. package/build/lowcode/view.js +4 -4
  8. package/es/businessModel/SalesModel/index.d.ts +1 -0
  9. package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
  10. package/es/components/appointmentBooking/components/Cart/Item/index.js +19 -7
  11. package/es/components/appointmentBooking/components/ConfirmInformation/index.d.ts +4 -0
  12. package/es/components/appointmentBooking/components/ConfirmInformation/index.js +2 -1
  13. package/es/components/appointmentBooking/components/Content/index.d.ts +4 -0
  14. package/es/components/appointmentBooking/components/Content/index.js +0 -1
  15. package/es/components/appointmentBooking/components/Date/index.d.ts +4 -0
  16. package/es/components/appointmentBooking/components/Date/index.js +1 -5
  17. package/es/components/appointmentBooking/components/Date/state.d.ts +63 -0
  18. package/es/components/appointmentBooking/components/Form/index.d.ts +4 -0
  19. package/es/components/appointmentBooking/components/Form/index.js +4 -3
  20. package/es/components/appointmentBooking/components/Guest/index.d.ts +4 -0
  21. package/es/components/appointmentBooking/components/Header/index.d.ts +1 -0
  22. package/es/components/appointmentBooking/components/Resource/index.d.ts +7 -0
  23. package/es/components/appointmentBooking/components/Services/index.d.ts +4 -0
  24. package/es/components/appointmentBooking/components/Services/index.js +21 -11
  25. package/es/components/appointmentBooking/components/TimeSlicing/index.d.ts +4 -0
  26. package/es/components/appointmentBooking/context.d.ts +35 -0
  27. package/es/components/appointmentBooking/deposit/components/PolicyModal/index.d.ts +3 -0
  28. package/es/components/appointmentBooking/hooks.d.ts +106 -0
  29. package/es/components/appointmentBooking/hooks.js +12 -18
  30. package/es/components/appointmentBooking/index.d.ts +1 -0
  31. package/es/components/appointmentBooking/index.js +3 -5
  32. package/es/components/appointmentBooking/locales.d.ts +354 -0
  33. package/es/components/appointmentBooking/utils.d.ts +114 -0
  34. package/es/components/appointmentBooking/utils.js +15 -15
  35. package/es/components/booking/addons/model.d.ts +1 -10
  36. package/es/components/booking/addons/model.js +5 -5
  37. package/es/components/booking/components/TabProduct/selectProductItem/index.js +4 -4
  38. package/es/components/booking/components/TabProduct/tabs/index.js +5 -1
  39. package/es/components/booking/components/browserSelect/index.js +1 -1
  40. package/es/components/booking/components/voucher/index.js +4 -2
  41. package/es/components/booking/deposit/index.d.ts +3 -0
  42. package/es/components/booking/forms/model.d.ts +1 -10
  43. package/es/components/booking/forms/model.js +5 -5
  44. package/es/components/booking/forms/sendModal/useSendModal.d.ts +1 -1
  45. package/es/components/booking/forms/single/index.d.ts +0 -1
  46. package/es/components/booking/info/addServiceVariant/index.d.ts +1 -0
  47. package/es/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
  48. package/es/components/booking/info/model.d.ts +1 -10
  49. package/es/components/booking/info/service/addService/index.js +14 -16
  50. package/es/components/booking/info/service/addTimeModal/index.d.ts +0 -1
  51. package/es/components/booking/info/service/like/index.js +1 -1
  52. package/es/components/booking/info/service/serviceList/index.d.ts +1 -0
  53. package/es/components/booking/info/service2/utils.d.ts +1 -1
  54. package/es/components/booking/info/service2/utils.js +1 -0
  55. package/es/components/booking/info2/service/addService/index.js +30 -17
  56. package/es/components/booking/materiels/startTime/index.js +1 -1
  57. package/es/components/booking/model.d.ts +1 -9
  58. package/es/components/booking/notes/NoteBlock/NoteItem/index.js +1 -1
  59. package/es/components/booking/notes/NoteBlock/index.js +11 -11
  60. package/es/components/booking/notes/model.d.ts +1 -10
  61. package/es/components/booking/notes/model.js +5 -5
  62. package/es/components/booking/payments/model.d.ts +1 -10
  63. package/es/components/booking/payments/model.js +5 -5
  64. package/es/components/eftposPay/amount.d.ts +2 -1
  65. package/es/components/eftposPay/app.d.ts +1 -0
  66. package/es/components/eftposPay/component/fail/unknow.d.ts +0 -1
  67. package/es/components/eftposPay/device.d.ts +2 -1
  68. package/es/components/eftposPay/hooks.d.ts +2 -2
  69. package/es/components/eftposPay/payo/config.d.ts +13 -0
  70. package/es/components/eftposPay/payo/hooks.d.ts +10 -0
  71. package/es/components/eftposPay/store/index.d.ts +6 -6
  72. package/es/components/eventBooking/components/Provider/Content/index.d.ts +1 -0
  73. package/es/components/eventBooking/components/Provider/Header/index.d.ts +1 -0
  74. package/es/components/eventBooking/components/Provider/SelectHolderModal.d.ts +1 -0
  75. package/es/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +1 -0
  76. package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
  77. package/es/components/eventBooking/index.d.ts +1 -0
  78. package/es/components/listComponent/index.js +5 -5
  79. package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
  80. package/es/components/pay/toC/model.d.ts +1 -9
  81. package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +1 -0
  82. package/es/components/pisellSelectCustomerModal/RightPanel/Add/index.d.ts +1 -0
  83. package/es/components/pisellSelectCustomerModal/RightPanel/index.d.ts +1 -0
  84. package/es/components/productExtension/card/index.js +3 -3
  85. package/es/components/productExtension/fields/Actor/CutOffTime/index.js +1 -1
  86. package/es/components/productExtension/fields/Actor/index.d.ts +1 -0
  87. package/es/components/productExtension/fields/Forms/index.js +12 -12
  88. package/es/components/productExtension/fields/SelectProducts/ProductItemPreview/index.js +1 -1
  89. package/es/components/productExtension/fields/SelectProducts/index.d.ts +1 -0
  90. package/es/components/productExtension/fields/SelectProducts/server.js +2 -2
  91. package/es/components/productExtension/fields/SelectResourcesTable/index.d.ts +1 -0
  92. package/es/components/productExtension/fields/SelectResourcesTable/server.js +2 -2
  93. package/es/components/productExtension/index.d.ts +1 -0
  94. package/es/components/productExtension/server.js +2 -2
  95. package/es/components/ruleSetting/ruleBorder/index.js +1 -1
  96. package/es/components/schedules/calendar/index.js +4 -4
  97. package/es/components/schedules/calendar/serve.js +2 -2
  98. package/es/components/schedules/components/CurrentDay/index.js +5 -5
  99. package/es/components/schedules/components/CurrentDay/serve.js +2 -2
  100. package/es/components/schedules/components/DropdownSort/index.js +1 -1
  101. package/es/components/schedules/components/ResourceList/index.js +1 -1
  102. package/es/components/schedules/components/Search/index.js +5 -5
  103. package/es/components/schedules/model.d.ts +1 -9
  104. package/es/components/schedules/model.js +5 -5
  105. package/es/components/schedules/openHours/index.js +1 -1
  106. package/es/components/schedules/openHours/serve.js +2 -2
  107. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.js +1 -1
  108. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.js +5 -5
  109. package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.js +4 -4
  110. package/es/components/schedules/products/ProductDetailDrawer/index.js +3 -3
  111. package/es/components/schedules/products/serve.js +2 -2
  112. package/es/components/schedules/products/utils.js +5 -5
  113. package/es/components/schedules/resources/detail/detailContent.js +2 -2
  114. package/es/components/schedules/resources/detail/index.js +10 -10
  115. package/es/components/schedules/resources/list/index.js +2 -2
  116. package/es/components/schedules/resources/relationProduct/index.js +1 -1
  117. package/es/components/schedules/resources/serve.js +2 -2
  118. package/es/components/schedules/schedules/ScheduleDetailDrawer/index.js +9 -9
  119. package/es/components/schedules/utils.js +4 -4
  120. package/es/components/selectModal/index.js +2 -2
  121. package/es/components/shoppingCart/components/Empty/index.d.ts +1 -0
  122. package/es/components/shoppingCart/components/Render/index.d.ts +1 -0
  123. package/es/components/ticketBooking/components/timeBar/index.js +1 -0
  124. package/es/components/ticketBooking/index.d.ts +1 -0
  125. package/es/components/wallet/Detail/model.d.ts +1 -13
  126. package/es/components/wallet/DiscountCard/model.d.ts +1 -14
  127. package/es/components/wallet/PointCard/model.d.ts +1 -13
  128. package/es/components/wallet/RechargeableCard/model.d.ts +1 -29
  129. package/es/components/wallet/Voucher/model.d.ts +1 -13
  130. package/es/components/wallet/hooks/useWalletCard.d.ts +1 -0
  131. package/es/components/wallet/model.d.ts +1 -9
  132. package/es/hooks/useComponents.js +1 -1
  133. package/lib/businessModel/SalesModel/index.d.ts +1 -0
  134. package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
  135. package/lib/components/appointmentBooking/components/Cart/Item/index.js +12 -9
  136. package/lib/components/appointmentBooking/components/ConfirmInformation/index.d.ts +4 -0
  137. package/lib/components/appointmentBooking/components/ConfirmInformation/index.js +7 -1
  138. package/lib/components/appointmentBooking/components/Content/index.d.ts +4 -0
  139. package/lib/components/appointmentBooking/components/Content/index.js +1 -1
  140. package/lib/components/appointmentBooking/components/Date/index.d.ts +4 -0
  141. package/lib/components/appointmentBooking/components/Date/index.js +1 -1
  142. package/lib/components/appointmentBooking/components/Date/state.d.ts +63 -0
  143. package/lib/components/appointmentBooking/components/Form/index.d.ts +4 -0
  144. package/lib/components/appointmentBooking/components/Form/index.js +3 -2
  145. package/lib/components/appointmentBooking/components/Guest/index.d.ts +4 -0
  146. package/lib/components/appointmentBooking/components/Header/index.d.ts +1 -0
  147. package/lib/components/appointmentBooking/components/Resource/index.d.ts +7 -0
  148. package/lib/components/appointmentBooking/components/Services/index.d.ts +4 -0
  149. package/lib/components/appointmentBooking/components/Services/index.js +8 -1
  150. package/lib/components/appointmentBooking/components/TimeSlicing/index.d.ts +4 -0
  151. package/lib/components/appointmentBooking/context.d.ts +35 -0
  152. package/lib/components/appointmentBooking/deposit/components/PolicyModal/index.d.ts +3 -0
  153. package/lib/components/appointmentBooking/hooks.d.ts +106 -0
  154. package/lib/components/appointmentBooking/hooks.js +2 -6
  155. package/lib/components/appointmentBooking/index.d.ts +1 -0
  156. package/lib/components/appointmentBooking/index.js +2 -2
  157. package/lib/components/appointmentBooking/locales.d.ts +354 -0
  158. package/lib/components/appointmentBooking/utils.d.ts +114 -0
  159. package/lib/components/appointmentBooking/utils.js +14 -23
  160. package/lib/components/booking/addons/model.d.ts +1 -10
  161. package/lib/components/booking/components/voucher/index.js +4 -2
  162. package/lib/components/booking/deposit/index.d.ts +3 -0
  163. package/lib/components/booking/forms/model.d.ts +1 -10
  164. package/lib/components/booking/forms/sendModal/useSendModal.d.ts +1 -1
  165. package/lib/components/booking/forms/single/index.d.ts +0 -1
  166. package/lib/components/booking/info/addServiceVariant/index.d.ts +1 -0
  167. package/lib/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
  168. package/lib/components/booking/info/model.d.ts +1 -10
  169. package/lib/components/booking/info/service/addService/index.js +14 -14
  170. package/lib/components/booking/info/service/addTimeModal/index.d.ts +0 -1
  171. package/lib/components/booking/info/service/serviceList/index.d.ts +1 -0
  172. package/lib/components/booking/info/service2/utils.d.ts +1 -1
  173. package/lib/components/booking/info/service2/utils.js +1 -0
  174. package/lib/components/booking/info2/service/addService/index.js +27 -15
  175. package/lib/components/booking/model.d.ts +1 -9
  176. package/lib/components/booking/notes/model.d.ts +1 -10
  177. package/lib/components/booking/payments/model.d.ts +1 -10
  178. package/lib/components/eftposPay/amount.d.ts +2 -1
  179. package/lib/components/eftposPay/app.d.ts +1 -0
  180. package/lib/components/eftposPay/component/fail/unknow.d.ts +0 -1
  181. package/lib/components/eftposPay/device.d.ts +2 -1
  182. package/lib/components/eftposPay/hooks.d.ts +2 -2
  183. package/lib/components/eftposPay/payo/config.d.ts +13 -0
  184. package/lib/components/eftposPay/payo/hooks.d.ts +10 -0
  185. package/lib/components/eftposPay/store/index.d.ts +6 -6
  186. package/lib/components/eventBooking/components/Provider/Content/index.d.ts +1 -0
  187. package/lib/components/eventBooking/components/Provider/Header/index.d.ts +1 -0
  188. package/lib/components/eventBooking/components/Provider/SelectHolderModal.d.ts +1 -0
  189. package/lib/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +1 -0
  190. package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
  191. package/lib/components/eventBooking/index.d.ts +1 -0
  192. package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
  193. package/lib/components/pay/toC/model.d.ts +1 -9
  194. package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +1 -0
  195. package/lib/components/pisellSelectCustomerModal/RightPanel/Add/index.d.ts +1 -0
  196. package/lib/components/pisellSelectCustomerModal/RightPanel/index.d.ts +1 -0
  197. package/lib/components/productExtension/fields/Actor/index.d.ts +1 -0
  198. package/lib/components/productExtension/fields/SelectProducts/index.d.ts +1 -0
  199. package/lib/components/productExtension/fields/SelectResourcesTable/index.d.ts +1 -0
  200. package/lib/components/productExtension/index.d.ts +1 -0
  201. package/lib/components/schedules/model.d.ts +1 -9
  202. package/lib/components/schedules/utils.js +1 -1
  203. package/lib/components/shoppingCart/components/Empty/index.d.ts +1 -0
  204. package/lib/components/shoppingCart/components/Render/index.d.ts +1 -0
  205. package/lib/components/ticketBooking/components/timeBar/index.js +1 -0
  206. package/lib/components/ticketBooking/index.d.ts +1 -0
  207. package/lib/components/wallet/Detail/model.d.ts +1 -13
  208. package/lib/components/wallet/DiscountCard/model.d.ts +1 -14
  209. package/lib/components/wallet/PointCard/model.d.ts +1 -13
  210. package/lib/components/wallet/RechargeableCard/model.d.ts +1 -29
  211. package/lib/components/wallet/Voucher/model.d.ts +1 -13
  212. package/lib/components/wallet/hooks/useWalletCard.d.ts +1 -0
  213. package/lib/components/wallet/model.d.ts +1 -9
  214. package/package.json +3 -3
@@ -180,7 +180,12 @@ var Info = (props) => {
180
180
  let data = await state.apis.getServices({
181
181
  skip: 1,
182
182
  num: 500,
183
- extension_type: state.renderType === "eventBooking" ? void 0 : ["product_appointment", "appointment_ticket", "session_product", "session_ticket"],
183
+ extension_type: state.renderType === "eventBooking" ? void 0 : [
184
+ "product_appointment",
185
+ "appointment_ticket",
186
+ "session_product",
187
+ "session_ticket"
188
+ ],
184
189
  with: ["category"],
185
190
  ids: state.renderType === "eventBooking" ? (_c2 = state.eventOtherParams) == null ? void 0 : _c2.productIds : void 0,
186
191
  open_quotation: 1,
@@ -188,11 +193,7 @@ var Info = (props) => {
188
193
  with_count: ["bundleGroup", "optionGroup"],
189
194
  order_by_string: "sort:desc",
190
195
  status: "published",
191
- ...state.isBookingCreatePage ? { schedule_date: params == null ? void 0 : params.schedule_date } : {
192
- _config: {
193
- useCache: true
194
- }
195
- },
196
+ schedule_date: params == null ? void 0 : params.schedule_date,
196
197
  ...dayParams
197
198
  });
198
199
  setLoading(false);
@@ -294,16 +295,15 @@ var Info = (props) => {
294
295
  const showAddButton = (0, import_react.useMemo)(() => {
295
296
  return !state.disabledEdit && !state.channelDisabledEdit;
296
297
  }, [state.disabledEdit, state.channelDisabledEdit]);
298
+ const currentDate = (0, import_react.useMemo)(() => {
299
+ return state.date.value.format("YYYY-MM-DD");
300
+ }, [state.date.value]);
297
301
  (0, import_ahooks.useUpdateEffect)(() => {
298
302
  if (state.service.addModal) {
299
- getServices();
303
+ getServices({ schedule_date: currentDate });
300
304
  setSearch("");
301
305
  }
302
- }, [state.service.addModal]);
303
- const currentDate = (0, import_react.useMemo)(() => {
304
- return state.date.value.format("YYYY-MM-DD");
305
- }, [state.date.value]);
306
- console.log(currentDate, "currentDate");
306
+ }, [state.service.addModal, currentDate]);
307
307
  (0, import_react.useEffect)(() => {
308
308
  if (renderMode === "current") {
309
309
  getServices({ schedule_date: currentDate });
@@ -311,9 +311,9 @@ var Info = (props) => {
311
311
  }, [renderMode, currentDate]);
312
312
  (0, import_react.useEffect)(() => {
313
313
  if (state.renderType === "eventBooking" && state.modalOpen) {
314
- getServices();
314
+ getServices({ schedule_date: currentDate });
315
315
  }
316
- }, [state.renderType, state.modalOpen]);
316
+ }, [state.renderType, state.modalOpen, currentDate]);
317
317
  const addButton = (0, import_react.useMemo)(() => {
318
318
  if (isDay) {
319
319
  return;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const AddTimeModal: () => JSX.Element;
4
3
  export default AddTimeModal;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const ServiceList: ({ onEdit }: {
3
4
  onEdit: any;
@@ -240,4 +240,4 @@ export declare const updateAppointmentServicePrice: (state: any, { start_date, e
240
240
  * @Author: WangHan
241
241
  * @Date: 2024-12-24 11:32
242
242
  */
243
- export declare const updateServicePrice: (state: any) => Promise<any> | never[];
243
+ export declare const updateServicePrice: (state: any) => never[] | Promise<any>;
@@ -299,6 +299,7 @@ var updateServices = (state, currentItem, type, other, actions) => {
299
299
  }
300
300
  if (type === "change_holder") {
301
301
  products = handleChangeHolder(products, currentItem, other);
302
+ return products;
302
303
  }
303
304
  if (type === "add_holder") {
304
305
  (_c = actions == null ? void 0 : actions.handleAddHolder) == null ? void 0 : _c.call(actions, products, currentItem);
@@ -138,7 +138,13 @@ var Info = (props) => {
138
138
  let data = await state.apis.getServices({
139
139
  skip: 1,
140
140
  num: 500,
141
- extension_type: state.renderType === "eventBooking" ? void 0 : ["product_appointment", "appointment_ticket", "service_product", "session_product", "session_ticket"],
141
+ extension_type: state.renderType === "eventBooking" ? void 0 : [
142
+ "product_appointment",
143
+ "appointment_ticket",
144
+ "service_product",
145
+ "session_product",
146
+ "session_ticket"
147
+ ],
142
148
  with: ["category", "resourceRelation"],
143
149
  ids: state.renderType === "eventBooking" ? (_c2 = state.eventOtherParams) == null ? void 0 : _c2.productIds : void 0,
144
150
  open_quotation: 1,
@@ -146,11 +152,7 @@ var Info = (props) => {
146
152
  with_count: ["bundleGroup", "optionGroup"],
147
153
  order_by_string: "sort:desc",
148
154
  status: "published",
149
- ...state.isBookingCreatePage ? { schedule_date: params == null ? void 0 : params.schedule_date } : {
150
- _config: {
151
- useCache: true
152
- }
153
- }
155
+ schedule_date: params == null ? void 0 : params.schedule_date
154
156
  });
155
157
  setLoading(false);
156
158
  if (!state.service.addModal) {
@@ -238,12 +240,22 @@ var Info = (props) => {
238
240
  }
239
241
  if (cacheItem.autoClose) {
240
242
  cacheItem.autoClose = false;
241
- let _list = [...state.service.value, cacheItem];
243
+ let newValue = [...state.service.value];
244
+ if (!newValue.some((item2) => item2._id === cacheItem._id)) {
245
+ newValue.push(cacheItem);
246
+ } else {
247
+ newValue = newValue.map((item2) => {
248
+ if (item2._id === cacheItem._id) {
249
+ return { ...cacheItem, new: 0 };
250
+ }
251
+ return item2;
252
+ });
253
+ }
242
254
  dispatch({
243
255
  type: "setService",
244
256
  payload: {
245
257
  addModal: false,
246
- value: _list,
258
+ value: newValue,
247
259
  edit: true,
248
260
  changeService: false
249
261
  }
@@ -293,15 +305,15 @@ var Info = (props) => {
293
305
  const showAddButton = (0, import_react.useMemo)(() => {
294
306
  return !state.disabledEdit && !state.channelDisabledEdit;
295
307
  }, [state.disabledEdit, state.channelDisabledEdit]);
308
+ const currentDate = (0, import_react.useMemo)(() => {
309
+ return state.date.value.format("YYYY-MM-DD");
310
+ }, [state.date.value]);
296
311
  (0, import_ahooks.useUpdateEffect)(() => {
297
312
  if (state.service.addModal) {
298
- getServices();
313
+ getServices({ schedule_date: currentDate });
299
314
  setSearch("");
300
315
  }
301
- }, [state.service.addModal]);
302
- const currentDate = (0, import_react.useMemo)(() => {
303
- return state.date.value.format("YYYY-MM-DD");
304
- }, [state.date.value]);
316
+ }, [state.service.addModal, currentDate]);
305
317
  (0, import_react.useEffect)(() => {
306
318
  if (renderMode === "current") {
307
319
  getServices({ schedule_date: currentDate });
@@ -309,9 +321,9 @@ var Info = (props) => {
309
321
  }, [renderMode, currentDate]);
310
322
  (0, import_react.useEffect)(() => {
311
323
  if (state.renderType === "eventBooking" && state.modalOpen) {
312
- getServices();
324
+ getServices({ schedule_date: currentDate });
313
325
  }
314
- }, [state.renderType, state.modalOpen]);
326
+ }, [state.renderType, state.modalOpen, currentDate]);
315
327
  const addButton = (0, import_react.useMemo)(() => {
316
328
  if (state.isBookingCreatePage) {
317
329
  return /* @__PURE__ */ import_react.default.createElement("div", { style: { height: 20 } });
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  export interface FormState {
3
2
  amountSymbol: string;
4
3
  apis: {
@@ -105,11 +104,4 @@ export declare const walkInData: {
105
104
  id: number;
106
105
  nickname: string;
107
106
  };
108
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
109
- state: FormState;
110
- } & {
111
- dispatch: (params: {
112
- type: string;
113
- payload: any;
114
- }) => void;
115
- }>;
107
+ export declare const Provider: any, Context: any;
@@ -1,10 +1 @@
1
- /// <reference types="react" />
2
- import { FormState } from "../model";
3
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
4
- state: FormState;
5
- } & {
6
- dispatch: (params: {
7
- type: string;
8
- payload: any;
9
- }) => void;
10
- }>;
1
+ export declare const Provider: any, Context: any;
@@ -1,10 +1 @@
1
- /// <reference types="react" />
2
- import { FormState } from "../model";
3
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
4
- state: FormState;
5
- } & {
6
- dispatch: (params: {
7
- type: string;
8
- payload: any;
9
- }) => void;
10
- }>;
1
+ export declare const Provider: any, Context: any;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { PosProps } from './const';
2
3
  /**
3
4
  * @title: 支付金额信息配置页
@@ -8,7 +9,7 @@ import { PosProps } from './const';
8
9
  */
9
10
  declare const _default: ({ className, onChange, onClose, formatAmount, isMobile, net, client }: {
10
11
  className?: string | undefined;
11
- onChange?: ((status: "success" | "page" | "print" | "fail" | "mark_tx_processed", params?: string | {
12
+ onChange?: ((status: "page" | "success" | "fail" | "print" | "mark_tx_processed", params?: string | {
12
13
  [keys: string]: unknown;
13
14
  } | undefined, other?: any) => void) | undefined;
14
15
  onClose: () => void;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { PosProps, RouteType } from './const';
2
3
  declare const App: ({ action, api, device_number, terminal, tyroUrl, tyroVersion, onChangeParams, isMobile, channel, formatAmount, ...props }: Omit<PosProps, "type" | "mode" | "getApi"> & {
3
4
  action: RouteType;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { ActionProps } from '../../const';
3
2
  /**
4
3
  * @title: 支付状态未知页面
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { PayProps, PosProps } from './const';
2
3
  import './device.less';
3
4
  /**
@@ -10,7 +11,7 @@ import './device.less';
10
11
  declare const _default: ({ api, onChange, onClose, className, device_number, isMobile, net, client, formatAmount, }: {
11
12
  api: PayProps['api'];
12
13
  className?: string | undefined;
13
- onChange?: ((status: "success" | "page" | "print" | "fail" | "mark_tx_processed", params?: string | {
14
+ onChange?: ((status: "page" | "success" | "fail" | "print" | "mark_tx_processed", params?: string | {
14
15
  [keys: string]: unknown;
15
16
  } | undefined, other?: any) => void) | undefined;
16
17
  onClose: () => void;
@@ -15,11 +15,11 @@ export declare const useStoreRef: <T extends {
15
15
  readonly numRef: React.MutableRefObject<string | number | undefined>;
16
16
  readonly orderIdRef: React.MutableRefObject<string | number>;
17
17
  readonly modeRef: React.MutableRefObject<ModeEnum>;
18
- readonly statusRef: React.MutableRefObject<"success" | "warn" | "loading" | "fail" | "pedding" | "resove" | "reject" | "question">;
18
+ readonly statusRef: React.MutableRefObject<"loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question">;
19
19
  readonly netRef: React.MutableRefObject<boolean | undefined>;
20
20
  readonly symbolRef: React.MutableRefObject<string>;
21
21
  readonly amountRef: React.MutableRefObject<string | number>;
22
- readonly eftposRef: React.MutableRefObject<"stripe" | "payo" | "tyro" | "windcave">;
22
+ readonly eftposRef: React.MutableRefObject<"payo" | "tyro" | "windcave" | "stripe">;
23
23
  readonly clientRef: React.MutableRefObject<ClientEnum>;
24
24
  readonly dataRef: React.MutableRefObject<import("./store").State>;
25
25
  };
@@ -0,0 +1,13 @@
1
+ /// <reference types="react" />
2
+ import { StatusEnum } from '../const';
3
+ export declare const POS: ({ api, onChange, }: {
4
+ api: {
5
+ [key: string]: (...agrn: unknown[]) => Promise<unknown>;
6
+ };
7
+ onChange: (status: `${StatusEnum.Success}` | `${StatusEnum.Fail}`, params?: {
8
+ [keys: string]: unknown;
9
+ } | undefined) => void;
10
+ }) => JSX.Element;
11
+ export declare const Action: ({ onChange }: {
12
+ onChange: any;
13
+ }) => JSX.Element;
@@ -0,0 +1,10 @@
1
+ import { PayStatus } from '../const';
2
+ /**
3
+ * @title: 循环查询 接口状态
4
+ * @Author: hongbing.wang
5
+ * @Date: 2024-08-20 13:29
6
+ */
7
+ export declare const useValidate: (timeout: number) => readonly [(params_0: (...agrn: unknown[]) => Promise<any>, params_1: number, params_2?: number | undefined) => Promise<{
8
+ [key: string]: unknown;
9
+ code: `${PayStatus}`;
10
+ }>, () => void];
@@ -174,7 +174,7 @@ export declare const updateCustom: (payload: {
174
174
  export declare const updateStatus: (status: 'loading' | 'warn' | 'fail' | 'success' | 'question') => {
175
175
  type: EActionTypes;
176
176
  payload: {
177
- status: "success" | "warn" | "loading" | "fail" | "question";
177
+ status: "loading" | "success" | "warn" | "fail" | "question";
178
178
  };
179
179
  };
180
180
  /**
@@ -295,20 +295,20 @@ export declare const backUpFree: (payload: Partial<State>) => {
295
295
  name?: string | undefined;
296
296
  symbol?: string | undefined;
297
297
  amount?: string | number | undefined;
298
- mode?: "refund" | "pay" | "fullPay" | "query" | undefined;
298
+ mode?: "pay" | "fullPay" | "refund" | "query" | undefined;
299
299
  order_id?: string | number | undefined;
300
- eftpos?: "stripe" | "payo" | "tyro" | "windcave" | undefined;
301
- action?: "amount" | "pay" | "deviceList" | undefined;
300
+ eftpos?: "payo" | "tyro" | "windcave" | "stripe" | undefined;
301
+ action?: "amount" | "deviceList" | "pay" | undefined;
302
302
  key?: number | undefined;
303
303
  step?: number | undefined;
304
304
  title?: string | undefined;
305
305
  subTitle?: string | undefined;
306
- type?: "unset" | "step" | undefined;
306
+ type?: "step" | "unset" | undefined;
307
307
  render?: boolean | undefined;
308
308
  net?: boolean | undefined;
309
309
  component?: string | undefined;
310
310
  form?: string | undefined;
311
- status?: "success" | "warn" | "loading" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
311
+ status?: "loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
312
312
  warn?: string | undefined;
313
313
  steps?: {
314
314
  /** 用于重置当前步骤 */
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const Layout: () => JSX.Element;
3
4
  export default Layout;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const Header: () => JSX.Element;
3
4
  export default Header;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const SelectHolderModal: (props: any) => JSX.Element;
2
3
  export default SelectHolderModal;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const Resource: (props: any) => JSX.Element;
2
3
  export default Resource;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const Schedule: () => JSX.Element;
2
3
  export default Schedule;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const EventBooking: () => JSX.Element;
3
4
  export default EventBooking;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.module.less';
2
3
  declare const StripePayment: () => JSX.Element;
3
4
  export default StripePayment;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  export interface FormState {
3
2
  platform: 'pc' | 'h5' | '' | undefined;
4
3
  order: any;
@@ -25,11 +24,4 @@ export interface PayGroup {
25
24
  pay_number?: string;
26
25
  _order: any;
27
26
  }
28
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
29
- state: FormState;
30
- } & {
31
- dispatch: (params: {
32
- type: string;
33
- payload: any;
34
- }) => void;
35
- }>;
27
+ export declare const Provider: any, Context: any;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const PhoneField: ({ value, onChange }: any) => JSX.Element;
2
3
  export default PhoneField;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  interface AddClientProps {
3
4
  onChange: (value: any) => void;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  interface RightPanelProps {
3
4
  value: any;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  declare const Actor: ({ name }: {
2
3
  name: string;
3
4
  }) => JSX.Element;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  interface valueType {
3
4
  }
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const SelectResourcesTable: ({ value, onChange }: any) => JSX.Element;
3
4
  export default SelectResourcesTable;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import "./index.less";
2
3
  interface ProductExtensionProps {
3
4
  onDataChange: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { CalendarDataItem, ScheduleItem } from "./type";
3
2
  import dayjs from "dayjs";
4
3
  export interface FormState {
@@ -69,11 +68,4 @@ export interface FormState {
69
68
  };
70
69
  setGlobalState: Function | null;
71
70
  }
72
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
73
- state: FormState;
74
- } & {
75
- dispatch: (params: {
76
- type: string;
77
- payload: any;
78
- }) => void;
79
- }>;
71
+ export declare const Provider: any, Context: any;
@@ -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 = {};
30
31
  constructor() {
31
- this.request = {};
32
32
  }
33
33
  setRequest(val) {
34
34
  this.request = val;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const Empty: (props: any) => JSX.Element;
3
4
  export default Empty;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const Content: () => JSX.Element;
3
4
  export default Content;
@@ -101,6 +101,7 @@ var TimeBar = (props) => {
101
101
  /* @__PURE__ */ import_react.default.createElement(
102
102
  import_materials.DatePicker,
103
103
  {
104
+ inputReadOnly: true,
104
105
  value: (_b = (_a = state == null ? void 0 : state.modalState) == null ? void 0 : _a.date) == null ? void 0 : _b.value,
105
106
  format: locale === "en" ? "dddd, DD MMM YYYY" : "YYYY年MM月DD日",
106
107
  onChange: props == null ? void 0 : props.onDateChange,
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  interface TicketBookingProps {
3
4
  productExtensionType: string[];
@@ -1,13 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- addWalletCard: any;
4
- }
5
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
6
- walletDetailState: RechargeState;
7
- } & {
8
- dispatch: (params: {
9
- type: string;
10
- payload: any;
11
- }) => void;
12
- }>;
13
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,14 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- total: number;
4
- setup?: 'menu' | 'list' | 'detail' | string;
5
- }
6
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
7
- state: RechargeState;
8
- } & {
9
- dispatch: (params: {
10
- type: string;
11
- payload: any;
12
- }) => void;
13
- }>;
14
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,13 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- total: number;
4
- }
5
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
6
- state: RechargeState;
7
- } & {
8
- dispatch: (params: {
9
- type: string;
10
- payload: any;
11
- }) => void;
12
- }>;
13
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,29 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- selectedGiftOptionId: string | null;
4
- cardList: Array<{
5
- id: string;
6
- name: string;
7
- price: number;
8
- }>;
9
- selectedItem: {
10
- id?: string;
11
- gift_price?: number;
12
- price?: number;
13
- name?: string;
14
- variant_id?: string;
15
- };
16
- productId?: string;
17
- detailId?: string;
18
- total: string | number;
19
- rechargeModalOpen: boolean;
20
- }
21
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
22
- state: RechargeState;
23
- } & {
24
- dispatch: (params: {
25
- type: string;
26
- payload: any;
27
- }) => void;
28
- }>;
29
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,13 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- total: 0;
4
- }
5
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
6
- state: RechargeState;
7
- } & {
8
- dispatch: (params: {
9
- type: string;
10
- payload: any;
11
- }) => void;
12
- }>;
13
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { IWalletListItemProps } from '../serve';
2
3
  /**
3
4
  * 钱包卡片Hook的参数
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { IWalletListItemProps } from './serve';
3
2
  export interface WalletCardItemProps {
4
3
  id: string;
@@ -27,11 +26,4 @@ export interface WalletListProps {
27
26
  currentSearchListItemCode?: string;
28
27
  [key: string]: any;
29
28
  }
30
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
31
- global_wallet: WalletListProps;
32
- } & {
33
- dispatch: (params: {
34
- type: string;
35
- payload: any;
36
- }) => void;
37
- }>;
29
+ export declare const Provider: any, Context: any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/private-materials",
3
- "version": "3.3.21",
3
+ "version": "3.3.23",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",
@@ -60,9 +60,9 @@
60
60
  "rc-virtual-list": "^3.11.3",
61
61
  "decimal.js": "^10.4.3",
62
62
  "@pisell/utils": "1.0.42",
63
- "@pisell/materials": "3.3.7",
63
+ "@pisell/icon": "0.0.11",
64
64
  "@pisell/date-picker": "3.0.2",
65
- "@pisell/icon": "0.0.11"
65
+ "@pisell/materials": "3.3.7"
66
66
  },
67
67
  "peerDependencies": {
68
68
  "react": "^18.0.0",