@pisell/private-materials 6.11.41 → 6.11.43

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 (103) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/meta.js +1 -1
  5. package/build/lowcode/render/default/view.js +1 -1
  6. package/build/lowcode/view.js +1 -1
  7. package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
  8. package/es/components/booking/components/footer/index.js +9 -3
  9. package/es/components/booking/components/voucher/index.d.ts +1 -0
  10. package/es/components/booking/deposit/index.d.ts +1 -0
  11. package/es/components/booking/info/index.d.ts +1 -0
  12. package/es/components/checkout/components/SearchAndClientModule/index.d.ts +1 -0
  13. package/es/components/eventBooking/components/Provider/Cart/Item/index.d.ts +1 -0
  14. package/es/components/pay/toB/components/Cache/index.d.ts +1 -0
  15. package/es/components/ticketBooking/components/addServiceVariant/addService.d.ts +1 -0
  16. package/es/components/ticketBooking/components/ticketBooking/index.d.ts +1 -0
  17. package/es/components/ticketBooking/hooks/pisellos/useCustomer.js +12 -0
  18. package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
  19. package/lib/components/booking/components/footer/index.js +20 -12
  20. package/lib/components/booking/components/voucher/index.d.ts +1 -0
  21. package/lib/components/booking/deposit/index.d.ts +1 -0
  22. package/lib/components/booking/info/index.d.ts +1 -0
  23. package/lib/components/checkout/components/SearchAndClientModule/index.d.ts +1 -0
  24. package/lib/components/eventBooking/components/Provider/Cart/Item/index.d.ts +1 -0
  25. package/lib/components/pay/toB/components/Cache/index.d.ts +1 -0
  26. package/lib/components/ticketBooking/components/addServiceVariant/addService.d.ts +1 -0
  27. package/lib/components/ticketBooking/components/ticketBooking/index.d.ts +1 -0
  28. package/lib/components/ticketBooking/hooks/pisellos/useCustomer.js +9 -0
  29. package/package.json +3 -3
  30. package/es/components/booking/components/footer/amount.d.ts +0 -38
  31. package/es/components/booking/components/footer/utils.d.ts +0 -67
  32. package/es/components/booking/hooks/usePromotion.d.ts +0 -301
  33. package/es/components/booking/hooks/useQuotation.d.ts +0 -5
  34. package/es/components/booking/info/pet/index.d.ts +0 -14
  35. package/es/components/booking/info/service/Lists.d.ts +0 -2
  36. package/es/components/booking/info/service2/utils.d.ts +0 -226
  37. package/es/components/booking/info2/service/addTimeModal/index.d.ts +0 -4
  38. package/es/components/booking/info2/service/editNormalService/index.d.ts +0 -3
  39. package/es/components/booking/info2/service/editService/index.d.ts +0 -8
  40. package/es/components/booking/utils/confirmHolderModal.d.ts +0 -13
  41. package/es/components/checkout/components/AmountSummary/index.d.ts +0 -26
  42. package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +0 -85
  43. package/es/components/eftposPay/huifu/const.d.ts +0 -5
  44. package/es/components/eftposPay/linkly/const.d.ts +0 -23
  45. package/es/components/eftposPay/payo/config.d.ts +0 -13
  46. package/es/components/eftposPay/payo/const.d.ts +0 -26
  47. package/es/components/eftposPay/tyro/const.d.ts +0 -17
  48. package/es/components/eftposPay/windcave/const.d.ts +0 -119
  49. package/es/components/shoppingCart/components/Cart/index.d.ts +0 -3
  50. package/es/components/shoppingCart/hooks/usePromotionModal.d.ts +0 -20
  51. package/es/components/shoppingCart/server.d.ts +0 -11
  52. package/es/components/shoppingCart/type.d.ts +0 -57
  53. package/es/components/shoppingCart/utils.d.ts +0 -163
  54. package/es/components/ticketBooking/dialog.d.ts +0 -17
  55. package/es/components/ticketBooking/locales.d.ts +0 -340
  56. package/es/components/ticketBooking/serve.d.ts +0 -289
  57. package/es/components/ticketBooking/utils/edit.d.ts +0 -1
  58. package/es/components/ticketBooking/utils/index.d.ts +0 -103
  59. package/es/plus/pisellSalesGrid/PisellSalesGrid.d.ts +0 -5
  60. package/es/plus/pisellSalesManagement/components/BookingFormsPreview.d.ts +0 -14
  61. package/es/plus/pisellSalesManagement/config/booking.d.ts +0 -185
  62. package/es/plus/pisellSalesManagement/config/order.d.ts +0 -172
  63. package/es/plus/pisellSalesManagement/hooks/useBookingPerspective.d.ts +0 -2
  64. package/es/plus/pisellSalesManagement/hooks/useOrderPerspective.d.ts +0 -2
  65. package/es/pro/skuDetailModal/index.d.ts +0 -5
  66. package/es/pro/skuDetailModal/types.d.ts +0 -388
  67. package/lib/components/booking/components/footer/amount.d.ts +0 -38
  68. package/lib/components/booking/components/footer/utils.d.ts +0 -67
  69. package/lib/components/booking/hooks/usePromotion.d.ts +0 -301
  70. package/lib/components/booking/hooks/useQuotation.d.ts +0 -5
  71. package/lib/components/booking/info/pet/index.d.ts +0 -14
  72. package/lib/components/booking/info/service/Lists.d.ts +0 -2
  73. package/lib/components/booking/info/service2/utils.d.ts +0 -226
  74. package/lib/components/booking/info2/service/addTimeModal/index.d.ts +0 -4
  75. package/lib/components/booking/info2/service/editNormalService/index.d.ts +0 -3
  76. package/lib/components/booking/info2/service/editService/index.d.ts +0 -8
  77. package/lib/components/booking/utils/confirmHolderModal.d.ts +0 -13
  78. package/lib/components/checkout/components/AmountSummary/index.d.ts +0 -26
  79. package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +0 -85
  80. package/lib/components/eftposPay/huifu/const.d.ts +0 -5
  81. package/lib/components/eftposPay/linkly/const.d.ts +0 -23
  82. package/lib/components/eftposPay/payo/config.d.ts +0 -13
  83. package/lib/components/eftposPay/payo/const.d.ts +0 -26
  84. package/lib/components/eftposPay/tyro/const.d.ts +0 -17
  85. package/lib/components/eftposPay/windcave/const.d.ts +0 -119
  86. package/lib/components/shoppingCart/components/Cart/index.d.ts +0 -3
  87. package/lib/components/shoppingCart/hooks/usePromotionModal.d.ts +0 -20
  88. package/lib/components/shoppingCart/server.d.ts +0 -11
  89. package/lib/components/shoppingCart/type.d.ts +0 -57
  90. package/lib/components/shoppingCart/utils.d.ts +0 -163
  91. package/lib/components/ticketBooking/dialog.d.ts +0 -17
  92. package/lib/components/ticketBooking/locales.d.ts +0 -340
  93. package/lib/components/ticketBooking/serve.d.ts +0 -289
  94. package/lib/components/ticketBooking/utils/edit.d.ts +0 -1
  95. package/lib/components/ticketBooking/utils/index.d.ts +0 -103
  96. package/lib/plus/pisellSalesGrid/PisellSalesGrid.d.ts +0 -5
  97. package/lib/plus/pisellSalesManagement/components/BookingFormsPreview.d.ts +0 -14
  98. package/lib/plus/pisellSalesManagement/config/booking.d.ts +0 -185
  99. package/lib/plus/pisellSalesManagement/config/order.d.ts +0 -172
  100. package/lib/plus/pisellSalesManagement/hooks/useBookingPerspective.d.ts +0 -2
  101. package/lib/plus/pisellSalesManagement/hooks/useOrderPerspective.d.ts +0 -2
  102. package/lib/pro/skuDetailModal/index.d.ts +0 -5
  103. package/lib/pro/skuDetailModal/types.d.ts +0 -388
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const CartItem: ({ onNext, renderContactInfo }: any) => JSX.Element;
3
4
  export default CartItem;
@@ -69,7 +69,7 @@ import Decimal from 'decimal.js';
69
69
  * @Date: 2024-01-30 16:51
70
70
  */
71
71
  var Footer = function Footer(props) {
72
- var _context$appHelper, _state$paymentPaid2, _state$bookingConfig2, _state$bookingConfig4, _state$addons2, _state$bookingDetail, _state$bookingDetail2, _state$client2, _state$notes3, _state$bookingDetail13, _state$addons4, _state$notes4, _state$bookingConfig7, _state$client5;
72
+ var _context$appHelper, _state$paymentPaid2, _state$bookingConfig2, _state$bookingConfig4, _state$addons2, _state$bookingDetail, _state$bookingDetail2, _state$client2, _state$notes3, _state$bookingDetail13, _state$bookingDetail16, _state$addons4, _state$notes4, _state$bookingConfig7, _state$client5;
73
73
  var state = props.state,
74
74
  buttons = props.buttons,
75
75
  dispatch = props.dispatch,
@@ -2140,13 +2140,19 @@ var Footer = function Footer(props) {
2140
2140
 
2141
2141
  // 待支付金额大于0 并且是新增时, 展示 待支付金额
2142
2142
  if (total.notPaidAmount > 0 || !state.bookingId) {
2143
- str = "".concat(locales.getText('pisell2.text.to-pay'), ": ").concat(formatAmount(total.notPaidAmount, 2, (state === null || state === void 0 ? void 0 : state.amountSymbol) || '$'));
2143
+ var _state$bookingDetail15;
2144
+ // 如果是在编辑订单里操作了删除商品,会导致进入退款逻辑,这里依旧展示 fully-paid 文案
2145
+ if (total.dueAmount < 0 && (_state$bookingDetail15 = state.bookingDetail) !== null && _state$bookingDetail15 !== void 0 && _state$bookingDetail15.id) {
2146
+ str = "".concat(locales.getText('pisell1.text.fully-paid'), ": ").concat(formatAmount(total.sumTotalAmount, 2, (state === null || state === void 0 ? void 0 : state.amountSymbol) || '$'));
2147
+ } else {
2148
+ str = "".concat(locales.getText('pisell2.text.to-pay'), ": ").concat(formatAmount(total.notPaidAmount, 2, (state === null || state === void 0 ? void 0 : state.amountSymbol) || '$'));
2149
+ }
2144
2150
  }
2145
2151
  if (total.duration) {
2146
2152
  str = str + " (".concat(total.duration, ")");
2147
2153
  }
2148
2154
  return str;
2149
- }, [state, total, state.bookingId, isOnlyDeposit]);
2155
+ }, [state, total, state.bookingId, isOnlyDeposit, (_state$bookingDetail16 = state.bookingDetail) === null || _state$bookingDetail16 === void 0 ? void 0 : _state$bookingDetail16.id]);
2150
2156
 
2151
2157
  /**
2152
2158
  * @title: 是否显示footer loading
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const VoucherCard: (props: any) => JSX.Element | null;
3
4
  export default VoucherCard;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const Deposit: (props: any) => JSX.Element;
2
3
  export default Deposit;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { InfoProps } from './main';
2
3
  declare const APP: (props: InfoProps) => JSX.Element;
3
4
  export default APP;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  export interface IScanResult {
3
4
  status: 'success' | 'failed';
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const CartItem: () => JSX.Element;
3
4
  export default CartItem;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const ToBPayCache: (props: {
3
4
  open: boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter';
2
3
  import './index.less';
3
4
  interface AddServiceProps {
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter/types';
3
4
  export declare const _formatBookingDetail: (data: any, modalState: any) => any;
@@ -18,11 +18,13 @@ import { useBookingTicket } from "./bookingTicket";
18
18
  import { usePisellOS } from "../../../../hooks/useEngineContext";
19
19
  import { useMemoizedFn } from 'ahooks';
20
20
  import { useActiveExecute } from "./useActiveExecute";
21
+ import { useIsActive } from "../../context/IsActiveContext";
21
22
  export var useCustomer = function useCustomer(props) {
22
23
  var bookingTicket = useBookingTicket();
23
24
  var pisellos = usePisellOS();
24
25
  var _useActiveExecute = useActiveExecute(),
25
26
  executeIfActive = _useActiveExecute.executeIfActive;
27
+ var isActive = useIsActive();
26
28
 
27
29
  // 客户列表
28
30
  var _useState = useState([]),
@@ -60,6 +62,16 @@ export var useCustomer = function useCustomer(props) {
60
62
  loadingMore = _useState14[0],
61
63
  setLoadingMore = _useState14[1];
62
64
 
65
+ // 针对于有预加载的页面,如果预加载的页面不是刷新后的第一个路由页面,会导致下面依靠 effects:onCustomerListUpdate 的回调不触发
66
+ // 所以当页面 active 以后,做一个检测,如果没有客户,则从 OS 里捞出来
67
+ useEffect(function () {
68
+ if (isActive && bookingTicket) {
69
+ if ((selectedCustomer === null || selectedCustomer === void 0 ? void 0 : selectedCustomer.length) > 0) return;
70
+ var _customers = bookingTicket.getCustomers();
71
+ setCustomers(_customers);
72
+ }
73
+ }, [isActive, bookingTicket]);
74
+
63
75
  // 监听事件
64
76
  useEffect(function () {
65
77
  var _bookingTicket$store;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const CartItem: ({ onNext, renderContactInfo }: any) => JSX.Element;
3
4
  export default CartItem;
@@ -74,7 +74,7 @@ var import_serve3 = require("../../editBookingModal/serve");
74
74
  var import_ticketBooking = require("../../../ticketBooking/components/ticketBooking");
75
75
  var import_decimal = __toESM(require("decimal.js"));
76
76
  var Footer = (props) => {
77
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
77
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u;
78
78
  const { state, buttons, dispatch, source } = props;
79
79
  const [showDetail, setShowDetail] = (0, import_react.useState)(false);
80
80
  const [loading, setLoading] = (0, import_react.useState)(false);
@@ -1483,7 +1483,7 @@ var Footer = (props) => {
1483
1483
  (_n = state == null ? void 0 : state.bookingDetail) == null ? void 0 : _n.payment_status
1484
1484
  ]);
1485
1485
  const totalText = (0, import_react.useMemo)(() => {
1486
- var _a2;
1486
+ var _a2, _b2;
1487
1487
  let str = "";
1488
1488
  if (total.totalRefundAmount > 0) {
1489
1489
  return `${import_utils.locales.getText(
@@ -1509,17 +1509,25 @@ var Footer = (props) => {
1509
1509
  )}`;
1510
1510
  }
1511
1511
  if (total.notPaidAmount > 0 || !state.bookingId) {
1512
- str = `${import_utils.locales.getText("pisell2.text.to-pay")}: ${(0, import_utils.formatAmount)(
1513
- total.notPaidAmount,
1514
- 2,
1515
- (state == null ? void 0 : state.amountSymbol) || "$"
1516
- )}`;
1512
+ if (total.dueAmount < 0 && ((_b2 = state.bookingDetail) == null ? void 0 : _b2.id)) {
1513
+ str = `${import_utils.locales.getText("pisell1.text.fully-paid")}: ${(0, import_utils.formatAmount)(
1514
+ total.sumTotalAmount,
1515
+ 2,
1516
+ (state == null ? void 0 : state.amountSymbol) || "$"
1517
+ )}`;
1518
+ } else {
1519
+ str = `${import_utils.locales.getText("pisell2.text.to-pay")}: ${(0, import_utils.formatAmount)(
1520
+ total.notPaidAmount,
1521
+ 2,
1522
+ (state == null ? void 0 : state.amountSymbol) || "$"
1523
+ )}`;
1524
+ }
1517
1525
  }
1518
1526
  if (total.duration) {
1519
1527
  str = str + ` (${total.duration})`;
1520
1528
  }
1521
1529
  return str;
1522
- }, [state, total, state.bookingId, isOnlyDeposit]);
1530
+ }, [state, total, state.bookingId, isOnlyDeposit, (_o = state.bookingDetail) == null ? void 0 : _o.id]);
1523
1531
  const showFooter = (0, import_react.useMemo)(() => {
1524
1532
  var _a2;
1525
1533
  if (state.bookingId) {
@@ -1534,7 +1542,7 @@ var Footer = (props) => {
1534
1542
  }, [
1535
1543
  state.bookingId,
1536
1544
  state.bookingDetail,
1537
- (_o = state.addons) == null ? void 0 : _o.load,
1545
+ (_p = state.addons) == null ? void 0 : _p.load,
1538
1546
  state.renderType
1539
1547
  ]);
1540
1548
  const menuChange = (e) => {
@@ -1751,7 +1759,7 @@ var Footer = (props) => {
1751
1759
  {
1752
1760
  open: noteModalOpen,
1753
1761
  title: import_utils.locales.getText("pisell2.text.add-order-notes"),
1754
- value: ((_p = state.notes) == null ? void 0 : _p.orderNote) || "",
1762
+ value: ((_q = state.notes) == null ? void 0 : _q.orderNote) || "",
1755
1763
  onConfirm: handleNoteConfirm,
1756
1764
  onDelete: handleNoteDelete,
1757
1765
  onCancel: handleNoteCancel
@@ -1768,9 +1776,9 @@ var Footer = (props) => {
1768
1776
  },
1769
1777
  callback: paymentCallback || void 0,
1770
1778
  setEditCartMode,
1771
- paymentResultDisplayMode: (_s = (_r = (_q = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _q.config) == null ? void 0 : _r.payment_setting) == null ? void 0 : _s.payment_result_display_mode,
1779
+ paymentResultDisplayMode: (_t = (_s = (_r = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _r.config) == null ? void 0 : _s.payment_setting) == null ? void 0 : _t.payment_result_display_mode,
1772
1780
  shopDiscount: state.shop_discount,
1773
- client: (_t = state.client) == null ? void 0 : _t.value,
1781
+ client: (_u = state.client) == null ? void 0 : _u.value,
1774
1782
  currentTotalPrice: total.productAmount,
1775
1783
  onChangeShopDiscount: (discount) => {
1776
1784
  const normalizedDiscountAmount = new import_decimal.default(discount || 0).toDecimalPlaces(2, import_decimal.default.ROUND_DOWN).toString();
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const VoucherCard: (props: any) => JSX.Element | null;
3
4
  export default VoucherCard;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const Deposit: (props: any) => JSX.Element;
2
3
  export default Deposit;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { InfoProps } from './main';
2
3
  declare const APP: (props: InfoProps) => JSX.Element;
3
4
  export default APP;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  export interface IScanResult {
3
4
  status: 'success' | 'failed';
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const CartItem: () => JSX.Element;
3
4
  export default CartItem;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  declare const ToBPayCache: (props: {
3
4
  open: boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter';
2
3
  import './index.less';
3
4
  interface AddServiceProps {
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import './index.less';
2
3
  import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter/types';
3
4
  export declare const _formatBookingDetail: (data: any, modalState: any) => any;
@@ -27,10 +27,12 @@ var import_bookingTicket = require("./bookingTicket");
27
27
  var import_useEngineContext = require("../../../../hooks/useEngineContext");
28
28
  var import_ahooks = require("ahooks");
29
29
  var import_useActiveExecute = require("./useActiveExecute");
30
+ var import_IsActiveContext = require("../../context/IsActiveContext");
30
31
  var useCustomer = (props) => {
31
32
  const bookingTicket = (0, import_bookingTicket.useBookingTicket)();
32
33
  const pisellos = (0, import_useEngineContext.usePisellOS)();
33
34
  const { executeIfActive } = (0, import_useActiveExecute.useActiveExecute)();
35
+ const isActive = (0, import_IsActiveContext.useIsActive)();
34
36
  const [customers, setCustomers] = (0, import_react.useState)([]);
35
37
  const [selectedCustomer, setSelectedCustomer] = (0, import_react.useState)(
36
38
  null
@@ -44,6 +46,13 @@ var useCustomer = (props) => {
44
46
  });
45
47
  const [hasMore, setHasMore] = (0, import_react.useState)(false);
46
48
  const [loadingMore, setLoadingMore] = (0, import_react.useState)(false);
49
+ (0, import_react.useEffect)(() => {
50
+ if (isActive && bookingTicket) {
51
+ if ((selectedCustomer == null ? void 0 : selectedCustomer.length) > 0) return;
52
+ const customers2 = bookingTicket.getCustomers();
53
+ setCustomers(customers2);
54
+ }
55
+ }, [isActive, bookingTicket]);
47
56
  (0, import_react.useEffect)(() => {
48
57
  var _a;
49
58
  if (!bookingTicket) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/private-materials",
3
- "version": "6.11.41",
3
+ "version": "6.11.43",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",
@@ -67,10 +67,10 @@
67
67
  "react-infinite-scroll-component": "^6.1.0",
68
68
  "react-resizable": "^3.0.5",
69
69
  "styled-components": "^6.0.0-rc.3",
70
+ "@pisell/utils": "3.0.2",
70
71
  "@pisell/materials": "6.11.16",
71
72
  "@pisell/icon": "0.0.11",
72
- "@pisell/date-picker": "3.0.8",
73
- "@pisell/utils": "3.0.2"
73
+ "@pisell/date-picker": "3.0.8"
74
74
  },
75
75
  "peerDependencies": {
76
76
  "react": "^18.0.0",
@@ -1,38 +0,0 @@
1
- export declare const getRelationDetailsTotal: (relation_details: any) => number;
2
- export declare const getProductDiscountProductDiscountDifference: (product: any) => any;
3
- export declare const getIsPriceIncludeTax: (state: any) => any;
4
- /**
5
- * 总金额
6
- * @param state
7
- * @param options isEdit: 预约信息是否发生变动
8
- * @returns
9
- */
10
- export declare const getSumTotal: (state: any, options: {
11
- [key: string]: any;
12
- isEdit: boolean;
13
- ScheduleModule: any;
14
- }) => {
15
- productAmount: number;
16
- duration: string;
17
- tax: number;
18
- taxInfo: {
19
- title: any;
20
- rate: any;
21
- is_price_include_tax: any;
22
- };
23
- shopDiscount: number;
24
- surcharge: any;
25
- otherAmount: any;
26
- sumTotalAmount: number;
27
- paidAmount: any;
28
- notPaidAmount: number;
29
- paySurchargeFee: number;
30
- expectAmount: number;
31
- actualPaidAmount: any;
32
- orderPaidAmount: any;
33
- totalRefundAmount: number;
34
- dueAmount: number;
35
- roundingAmount: number;
36
- originExpectAmount: number;
37
- originExpectAmountWithoutDiscount: number;
38
- };
@@ -1,67 +0,0 @@
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, is_price_include_tax: number) => any;
19
- /**
20
- * 获取子商品折扣信息
21
- * @param item
22
- */
23
- export declare const getBundleDiscountList: (bundle: any[]) => any[];
24
- export interface ResourceItem {
25
- [key: string]: any;
26
- }
27
- /**
28
- * @title: 传入资源,如果有子资源,会根据组合资源的 capacity 计算修改子资源的 capacity
29
- * @description:
30
- * @param {object} resource
31
- * @return {*}
32
- * @Author: jinglin.tan
33
- */
34
- export declare const checkSubResourcesCapacity: (resource: ResourceItem) => void;
35
- export declare const checkResourcesFormat: (resources: any[], service: any, isChild?: boolean) => any[];
36
- /**
37
- * @title: 格式化商品单价
38
- * @description:
39
- * @param {any} item
40
- * @return {*}
41
- * @Author: WangHan
42
- * @Date: 2024-12-23 12:05
43
- */
44
- export declare const formatProductPrice: (item: any) => number;
45
- /**
46
- * checkout2.0: 单个数量商品总价(原价),包含所有套餐子商品金额、报价单等等
47
- * @param item
48
- * @returns
49
- */
50
- export declare const formatOriginalPrice: (item: any) => number;
51
- /**
52
- * checkout2.0: 商品维度折扣后价格, original_price - 商品折扣金额(商品手动折扣等等)
53
- * @param item
54
- * @returns
55
- */
56
- export declare const formatSellingPrice: (item: any) => number;
57
- export declare const getSourceProductPrice: (item: any) => number;
58
- export declare const getMainProductSellingPrice: (item: any) => number | undefined;
59
- /**
60
- * @title: 是否包含跨日预约商品
61
- * @description:
62
- * @param {any} data
63
- * @return {*}
64
- */
65
- export declare const getHasMultiDayProduct: (data: any) => any;
66
- export declare const formatValues: (state: any) => any;
67
- export declare const checkHolderIsError: (state: any) => any;