@pisell/private-materials 6.5.2 → 6.5.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.
- package/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +150 -164
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +9 -9
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +9 -9
- package/es/businessModel/SalesModel/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Content/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Header/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Voucher/index.d.ts +1 -0
- package/es/components/appointmentBooking/deposit/index.d.ts +1 -0
- package/es/components/appointmentBooking/index.d.ts +1 -0
- package/es/components/booking/components/actionButtons/index.js +2 -2
- package/es/components/booking/components/customiseItemModal/index.js +2 -2
- package/es/components/booking/components/footer/index.d.ts +1 -0
- package/es/components/booking/components/footer/index.js +48 -42
- package/es/components/booking/components/voucher/index.d.ts +1 -0
- package/es/components/booking/components/voucher/index.js +18 -4
- package/es/components/booking/deposit/index.d.ts +1 -0
- package/es/components/booking/hooks/useQuotation.d.ts +1 -0
- package/es/components/booking/info/addServiceVariant/index.d.ts +1 -0
- package/es/components/booking/info/header/index.d.ts +1 -0
- package/es/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
- package/es/components/booking/info/index.d.ts +1 -0
- package/es/components/booking/info/service/Lists.d.ts +1 -0
- package/es/components/booking/info/service/addService/index.d.ts +1 -0
- package/es/components/booking/info/service/addTimeModal/index.d.ts +1 -0
- package/es/components/booking/info/service/editService/BookingList/index.d.ts +1 -0
- package/es/components/booking/info/service/serviceItem/index.d.ts +1 -0
- package/es/components/booking/info/service/serviceList/index.d.ts +1 -0
- package/es/components/booking/info/service2/Lists.d.ts +1 -0
- package/es/components/booking/info/service2/utils.d.ts +1 -1
- package/es/components/booking/info2/cartClientCard/index.js +33 -20
- package/es/components/booking/info2/cartClientCard/utils.d.ts +2 -2
- package/es/components/booking/info2/service/addService/index.d.ts +1 -0
- package/es/components/booking/info2/service/serviceItem/index.d.ts +1 -0
- package/es/components/booking/info2/service/serviceList/index.d.ts +1 -0
- package/es/components/booking/notes/NoteBlock/index.d.ts +1 -0
- package/es/components/booking/notes/addNote/index.d.ts +1 -0
- package/es/components/booking/utils.d.ts +2 -2
- package/es/components/checkout/PaymentModal.js +719 -432
- package/es/components/checkout/PaymentPlugin.d.ts +1 -0
- package/es/components/checkout/components/AdditionalModule/index.d.ts +1 -1
- package/es/components/checkout/components/AdditionalModule/index.js +80 -49
- package/es/components/checkout/components/AdditionalModule/index.less +33 -34
- package/es/components/checkout/components/AdditionalModule/locales.d.ts +3 -0
- package/es/components/checkout/components/AdditionalModule/locales.js +7 -4
- package/es/components/checkout/components/AmountSummary/index.d.ts +2 -1
- package/es/components/checkout/components/AmountSummary/index.js +69 -31
- package/es/components/checkout/components/AmountSummary/index.less +27 -9
- package/es/components/checkout/components/CashPaymentModule/index.js +8 -1
- package/es/components/checkout/components/CashPaymentModule/index.less +0 -2
- package/es/components/checkout/components/PaymentDetailModal/index.js +55 -10
- package/es/components/checkout/components/PaymentOptionsModule/index.d.ts +2 -1
- package/es/components/checkout/components/PaymentOptionsModule/index.js +40 -25
- package/es/components/checkout/components/PaymentOptionsModule/index.less +11 -6
- package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +42 -9
- package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.js +512 -82
- package/es/components/checkout/components/PaymentResultToast/index.d.ts +2 -1
- package/es/components/checkout/components/PaymentResultToast/index.js +90 -35
- package/es/components/checkout/components/PaymentResultToast/index.less +445 -77
- package/es/components/checkout/components/PaymentResultToast/types.d.ts +3 -3
- package/es/components/checkout/components/PaymentResultToast/utils.d.ts +26 -0
- package/es/components/checkout/components/PaymentResultToast/utils.js +81 -2
- package/es/components/checkout/components/SearchAndClientModule/index.d.ts +1 -0
- package/es/components/checkout/components/SearchAndClientModule/index.js +17 -16
- package/es/components/checkout/components/SearchAndClientModule/index.less +29 -8
- package/es/components/checkout/components/WalletPassModule/components/ConflictModal/index.d.ts +1 -0
- package/es/components/checkout/components/WalletPassModule/components/DiscountWallet/index.d.ts +1 -0
- package/es/components/checkout/components/WalletPassModule/components/WalletPassHeader/index.js +3 -1
- package/es/components/checkout/components/WalletPassModule/index.less +3 -3
- package/es/components/checkout/hooks/useWalletPass.d.ts +1 -1
- package/es/components/checkout/hooks/useWalletPass.js +1 -1
- package/es/components/checkout/index.d.ts +1 -1
- package/es/components/checkout/index.js +1 -1
- package/es/components/checkout/index.less +56 -38
- package/es/components/checkout/locales.d.ts +6 -0
- package/es/components/checkout/locales.js +9 -3
- package/es/components/checkout/payment-modal-utils.js +5 -5
- package/es/components/checkout/utils/PaymentResultToastUtils.d.ts +3 -3
- package/es/components/checkout/utils/PaymentResultToastUtils.js +111 -72
- package/es/components/eftpos/surcharge/index.d.ts +1 -0
- package/es/components/eftposPay/amount.d.ts +1 -1
- package/es/components/eftposPay/app.d.ts +1 -0
- package/es/components/eftposPay/device.d.ts +1 -1
- package/es/components/eftposPay/hooks.d.ts +2 -2
- package/es/components/eftposPay/index.d.ts +1 -0
- package/es/components/eftposPay/linkly/index.d.ts +1 -0
- package/es/components/eftposPay/store/index.d.ts +6 -6
- package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/Total.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +1 -0
- package/es/components/eventBooking/index.d.ts +1 -0
- package/es/components/pay/toB/components/Cache/index.d.ts +1 -0
- package/es/components/pay/toB/components/Card/index.d.ts +1 -0
- package/es/components/pay/toB/components/CardGroup/index.d.ts +1 -0
- package/es/components/pay/toB/components/ConfirmedPayment/index.d.ts +1 -0
- package/es/components/pay/toB/components/Content/Footer.d.ts +1 -0
- package/es/components/pay/toB/components/Content/Header.d.ts +1 -0
- package/es/components/pay/toB/components/EFTPOS/index.js +91 -58
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/index.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/index.d.ts +1 -0
- package/es/components/productExtension/index.d.ts +1 -0
- package/es/components/productSelect/components/TabProduct/index.d.ts +1 -0
- package/es/components/productSelect/components/productGroup/index.d.ts +1 -0
- package/es/components/ruleSetting/index.d.ts +1 -0
- package/es/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +1 -0
- package/es/components/schedules/utils.d.ts +1 -1
- package/es/components/shoppingCart/components/Cart/Product.d.ts +1 -0
- package/es/components/taxSelect/index.d.ts +1 -0
- package/es/components/ticketBooking/components/addServiceVariant/addService.d.ts +1 -0
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +4 -3
- package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +1 -0
- package/es/components/ticketBooking/components/bookingDataPanel/index.js +1 -1
- package/es/components/ticketBooking/components/menuBar/index.d.ts +1 -0
- package/es/components/ticketBooking/components/menuBar/index.js +1 -1
- package/es/components/ticketBooking/components/ticketBooking/index.d.ts +1 -0
- package/es/components/ticketBooking/components/ticketBooking/index.js +2 -2
- package/es/components/ticketBooking/components/timeBar/index.d.ts +1 -0
- package/es/components/ticketBooking/hooks/pisellos/useScanCustomer.js +1 -1
- package/es/components/ticketBooking/hooks/pisellos/useScanGlobal.js +1 -1
- package/es/components/ticketBooking/hooks/pisellos/useScanGlobalHandle.js +4 -2
- package/es/components/ticketBooking/index.d.ts +1 -0
- package/es/components/workSpaceList/components/SearchWorkspaceAndBase/index.d.ts +1 -0
- package/es/plus/clientCard/index.js +3 -2
- package/es/plus/clientCard/index.less +3 -32
- package/es/plus/clientName/index.d.ts +1 -0
- package/es/plus/clinetSearch/Add/BirthdayField/index.d.ts +1 -0
- package/es/plus/clinetSearch/Add/GenderField/index.d.ts +1 -0
- package/es/plus/clinetSearch/Add/PhoneField/index.d.ts +1 -0
- package/es/plus/noteModal/AddTempModal.d.ts +1 -0
- package/es/plus/saasCreateOrganization/index.d.ts +1 -0
- package/es/pro/comprehensiveSearch/components/searchSection/index.js +9 -12
- package/es/pro/comprehensiveSearch/components/searchSection/index.less +22 -19
- package/es/pro/pisellPhoneKeyboard/index.d.ts +1 -0
- package/es/utils/index.d.ts +1 -1
- package/lib/businessModel/SalesModel/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Content/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Header/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Voucher/index.d.ts +1 -0
- package/lib/components/appointmentBooking/deposit/index.d.ts +1 -0
- package/lib/components/appointmentBooking/index.d.ts +1 -0
- package/lib/components/booking/components/actionButtons/index.js +2 -1
- package/lib/components/booking/components/customiseItemModal/index.js +2 -2
- package/lib/components/booking/components/footer/index.d.ts +1 -0
- package/lib/components/booking/components/footer/index.js +3 -0
- package/lib/components/booking/components/voucher/index.d.ts +1 -0
- package/lib/components/booking/components/voucher/index.js +15 -3
- package/lib/components/booking/deposit/index.d.ts +1 -0
- package/lib/components/booking/hooks/useQuotation.d.ts +1 -0
- package/lib/components/booking/info/addServiceVariant/index.d.ts +1 -0
- package/lib/components/booking/info/header/index.d.ts +1 -0
- package/lib/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
- package/lib/components/booking/info/index.d.ts +1 -0
- package/lib/components/booking/info/service/Lists.d.ts +1 -0
- package/lib/components/booking/info/service/addService/index.d.ts +1 -0
- package/lib/components/booking/info/service/addTimeModal/index.d.ts +1 -0
- package/lib/components/booking/info/service/editService/BookingList/index.d.ts +1 -0
- package/lib/components/booking/info/service/serviceItem/index.d.ts +1 -0
- package/lib/components/booking/info/service/serviceList/index.d.ts +1 -0
- package/lib/components/booking/info/service2/Lists.d.ts +1 -0
- package/lib/components/booking/info/service2/utils.d.ts +1 -1
- package/lib/components/booking/info2/cartClientCard/index.js +16 -5
- package/lib/components/booking/info2/cartClientCard/utils.d.ts +2 -2
- package/lib/components/booking/info2/service/addService/index.d.ts +1 -0
- package/lib/components/booking/info2/service/serviceItem/index.d.ts +1 -0
- package/lib/components/booking/info2/service/serviceList/index.d.ts +1 -0
- package/lib/components/booking/notes/NoteBlock/index.d.ts +1 -0
- package/lib/components/booking/notes/addNote/index.d.ts +1 -0
- package/lib/components/booking/utils.d.ts +2 -2
- package/lib/components/checkout/PaymentModal.js +241 -109
- package/lib/components/checkout/PaymentPlugin.d.ts +1 -0
- package/lib/components/checkout/components/AdditionalModule/index.d.ts +1 -1
- package/lib/components/checkout/components/AdditionalModule/index.js +98 -34
- package/lib/components/checkout/components/AdditionalModule/index.less +33 -34
- package/lib/components/checkout/components/AdditionalModule/locales.d.ts +3 -0
- package/lib/components/checkout/components/AdditionalModule/locales.js +7 -4
- package/lib/components/checkout/components/AmountSummary/index.d.ts +2 -1
- package/lib/components/checkout/components/AmountSummary/index.js +103 -47
- package/lib/components/checkout/components/AmountSummary/index.less +27 -9
- package/lib/components/checkout/components/CashPaymentModule/index.js +5 -1
- package/lib/components/checkout/components/CashPaymentModule/index.less +0 -2
- package/lib/components/checkout/components/PaymentDetailModal/index.js +56 -11
- package/lib/components/checkout/components/PaymentOptionsModule/index.d.ts +2 -1
- package/lib/components/checkout/components/PaymentOptionsModule/index.js +11 -8
- package/lib/components/checkout/components/PaymentOptionsModule/index.less +11 -6
- package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +42 -9
- package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.js +279 -73
- package/lib/components/checkout/components/PaymentResultToast/index.d.ts +2 -1
- package/lib/components/checkout/components/PaymentResultToast/index.js +69 -22
- package/lib/components/checkout/components/PaymentResultToast/index.less +445 -77
- package/lib/components/checkout/components/PaymentResultToast/types.d.ts +3 -3
- package/lib/components/checkout/components/PaymentResultToast/utils.d.ts +26 -0
- package/lib/components/checkout/components/PaymentResultToast/utils.js +58 -4
- package/lib/components/checkout/components/SearchAndClientModule/index.d.ts +1 -0
- package/lib/components/checkout/components/SearchAndClientModule/index.js +17 -15
- package/lib/components/checkout/components/SearchAndClientModule/index.less +29 -8
- package/lib/components/checkout/components/WalletPassModule/components/ConflictModal/index.d.ts +1 -0
- package/lib/components/checkout/components/WalletPassModule/components/DiscountWallet/index.d.ts +1 -0
- package/lib/components/checkout/components/WalletPassModule/components/WalletPassHeader/index.js +12 -2
- package/lib/components/checkout/components/WalletPassModule/index.less +3 -3
- package/lib/components/checkout/hooks/useWalletPass.d.ts +1 -1
- package/lib/components/checkout/hooks/useWalletPass.js +2 -2
- package/lib/components/checkout/index.d.ts +1 -1
- package/lib/components/checkout/index.js +2 -0
- package/lib/components/checkout/index.less +56 -38
- package/lib/components/checkout/locales.d.ts +6 -0
- package/lib/components/checkout/locales.js +9 -3
- package/lib/components/checkout/payment-modal-utils.js +5 -5
- package/lib/components/checkout/utils/PaymentResultToastUtils.d.ts +3 -3
- package/lib/components/checkout/utils/PaymentResultToastUtils.js +26 -18
- package/lib/components/eftpos/surcharge/index.d.ts +1 -0
- package/lib/components/eftposPay/amount.d.ts +1 -1
- package/lib/components/eftposPay/app.d.ts +1 -0
- package/lib/components/eftposPay/device.d.ts +1 -1
- package/lib/components/eftposPay/hooks.d.ts +2 -2
- package/lib/components/eftposPay/index.d.ts +1 -0
- package/lib/components/eftposPay/linkly/index.d.ts +1 -0
- package/lib/components/eftposPay/store/index.d.ts +6 -6
- package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/Total.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +1 -0
- package/lib/components/eventBooking/index.d.ts +1 -0
- package/lib/components/pay/toB/components/Cache/index.d.ts +1 -0
- package/lib/components/pay/toB/components/Card/index.d.ts +1 -0
- package/lib/components/pay/toB/components/CardGroup/index.d.ts +1 -0
- package/lib/components/pay/toB/components/ConfirmedPayment/index.d.ts +1 -0
- package/lib/components/pay/toB/components/Content/Footer.d.ts +1 -0
- package/lib/components/pay/toB/components/Content/Header.d.ts +1 -0
- package/lib/components/pay/toB/components/EFTPOS/index.js +25 -10
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/index.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/index.d.ts +1 -0
- package/lib/components/productExtension/index.d.ts +1 -0
- package/lib/components/productSelect/components/TabProduct/index.d.ts +1 -0
- package/lib/components/productSelect/components/productGroup/index.d.ts +1 -0
- package/lib/components/ruleSetting/index.d.ts +1 -0
- package/lib/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +1 -0
- package/lib/components/schedules/utils.d.ts +1 -1
- package/lib/components/shoppingCart/components/Cart/Product.d.ts +1 -0
- package/lib/components/taxSelect/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/addServiceVariant/addService.d.ts +1 -0
- package/lib/components/ticketBooking/components/addServiceVariant/addService.js +7 -6
- package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/bookingDataPanel/index.js +2 -2
- package/lib/components/ticketBooking/components/menuBar/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/menuBar/index.js +1 -1
- package/lib/components/ticketBooking/components/ticketBooking/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/ticketBooking/index.js +1 -1
- package/lib/components/ticketBooking/components/timeBar/index.d.ts +1 -0
- package/lib/components/ticketBooking/hooks/pisellos/useScanCustomer.js +2 -12
- package/lib/components/ticketBooking/hooks/pisellos/useScanGlobal.js +2 -12
- package/lib/components/ticketBooking/hooks/pisellos/useScanGlobalHandle.js +5 -13
- package/lib/components/ticketBooking/index.d.ts +1 -0
- package/lib/components/workSpaceList/components/SearchWorkspaceAndBase/index.d.ts +1 -0
- package/lib/plus/clientCard/index.js +5 -4
- package/lib/plus/clientCard/index.less +3 -32
- package/lib/plus/clientName/index.d.ts +1 -0
- package/lib/plus/clinetSearch/Add/BirthdayField/index.d.ts +1 -0
- package/lib/plus/clinetSearch/Add/GenderField/index.d.ts +1 -0
- package/lib/plus/clinetSearch/Add/PhoneField/index.d.ts +1 -0
- package/lib/plus/noteModal/AddTempModal.d.ts +1 -0
- package/lib/plus/saasCreateOrganization/index.d.ts +1 -0
- package/lib/pro/comprehensiveSearch/components/searchSection/index.js +6 -18
- package/lib/pro/comprehensiveSearch/components/searchSection/index.less +22 -19
- package/lib/pro/pisellPhoneKeyboard/index.d.ts +1 -0
- package/lib/utils/index.d.ts +1 -1
- package/package.json +12 -12
@@ -70,7 +70,7 @@ var calculateSubtitle = (status, amount, gapAmount, getData) => {
|
|
70
70
|
case "paid":
|
71
71
|
if (gapAmount) {
|
72
72
|
text = `${import_utils.locales.getText("payment.result.changeDue") || "Change Due"} ${formatCurrency(Math.abs(gapAmount), amountSymbol)}`;
|
73
|
-
colorClass = "
|
73
|
+
colorClass = "paid";
|
74
74
|
} else {
|
75
75
|
text = `${import_utils.locales.getText("payment.result.paid") || "Paid"} ${formatCurrency(amount, amountSymbol)}`;
|
76
76
|
colorClass = "paid";
|
@@ -93,7 +93,7 @@ var calculateSubtitle = (status, amount, gapAmount, getData) => {
|
|
93
93
|
default:
|
94
94
|
return null;
|
95
95
|
}
|
96
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: "payment-result-toast-subtitle" }, /* @__PURE__ */ import_react.default.createElement("
|
96
|
+
return /* @__PURE__ */ import_react.default.createElement("div", { className: "payment-result-toast-subtitle" }, /* @__PURE__ */ import_react.default.createElement("div", { className: getSubtitleClassName(colorClass) }, text));
|
97
97
|
};
|
98
98
|
var calculateStatusClassName = (status) => {
|
99
99
|
switch (status) {
|
@@ -109,36 +109,36 @@ var calculateStatusClassName = (status) => {
|
|
109
109
|
}
|
110
110
|
};
|
111
111
|
var calculateAutoCloseConfig = (status, hasChangeDue) => {
|
112
|
+
const autoCloseDelay = 30;
|
112
113
|
switch (status) {
|
113
114
|
case "paid":
|
114
115
|
return {
|
115
116
|
autoClose: true,
|
116
|
-
autoCloseDelay
|
117
|
-
|
118
|
-
maskClosable: true
|
117
|
+
autoCloseDelay,
|
118
|
+
maskClosable: false
|
119
119
|
};
|
120
120
|
case "partially_paid":
|
121
121
|
return {
|
122
122
|
autoClose: true,
|
123
|
-
autoCloseDelay
|
124
|
-
maskClosable:
|
123
|
+
autoCloseDelay,
|
124
|
+
maskClosable: false
|
125
125
|
};
|
126
126
|
case "failed":
|
127
127
|
case "wallet-pass-redemption-failed":
|
128
128
|
return {
|
129
129
|
autoClose: false,
|
130
|
-
autoCloseDelay
|
130
|
+
autoCloseDelay,
|
131
131
|
maskClosable: false
|
132
132
|
};
|
133
133
|
default:
|
134
134
|
return {
|
135
135
|
autoClose: false,
|
136
|
-
autoCloseDelay
|
136
|
+
autoCloseDelay,
|
137
137
|
maskClosable: false
|
138
138
|
};
|
139
139
|
}
|
140
140
|
};
|
141
|
-
var displayPaymentResultToast = (params, config) => {
|
141
|
+
var displayPaymentResultToast = async (params, config) => {
|
142
142
|
const {
|
143
143
|
paymentStatus,
|
144
144
|
orderTotalAmount,
|
@@ -149,7 +149,7 @@ var displayPaymentResultToast = (params, config) => {
|
|
149
149
|
} = params;
|
150
150
|
const { getData, onToastClose } = config;
|
151
151
|
if (paymentStatus === "paid") {
|
152
|
-
(0, import_PaymentResultToast.showPaymentResultToastSuccess)({
|
152
|
+
await (0, import_PaymentResultToast.showPaymentResultToastSuccess)({
|
153
153
|
title: calculateTitle(paymentStatus),
|
154
154
|
subtitle: calculateSubtitle(
|
155
155
|
paymentStatus,
|
@@ -161,10 +161,14 @@ var displayPaymentResultToast = (params, config) => {
|
|
161
161
|
autoCloseDelay: (autoCloseConfig == null ? void 0 : autoCloseConfig.autoCloseDelay) || 3e3,
|
162
162
|
showCountdownProgress: true,
|
163
163
|
actionButtons: actionButtons || [],
|
164
|
-
onClose: onToastClose
|
164
|
+
onClose: onToastClose || (() => {
|
165
|
+
}),
|
166
|
+
// 提供默认空函数
|
167
|
+
closable: false
|
168
|
+
// 控制关闭按钮显示
|
165
169
|
});
|
166
170
|
} else if (paymentStatus === "partially_paid") {
|
167
|
-
(0, import_PaymentResultToast.showPaymentResultToastSuccess)({
|
171
|
+
await (0, import_PaymentResultToast.showPaymentResultToastSuccess)({
|
168
172
|
title: calculateTitle(paymentStatus),
|
169
173
|
subtitle: calculateSubtitle(
|
170
174
|
paymentStatus,
|
@@ -174,10 +178,12 @@ var displayPaymentResultToast = (params, config) => {
|
|
174
178
|
),
|
175
179
|
autoClose: (autoCloseConfig == null ? void 0 : autoCloseConfig.autoClose) || false,
|
176
180
|
actionButtons: actionButtons || [],
|
177
|
-
onClose: onToastClose
|
181
|
+
onClose: onToastClose || (() => {
|
182
|
+
})
|
183
|
+
// 提供默认空函数
|
178
184
|
});
|
179
185
|
} else if (paymentStatus === "failed" || paymentStatus === "error") {
|
180
|
-
(0, import_PaymentResultToast.showPaymentResultToastFailed)({
|
186
|
+
await (0, import_PaymentResultToast.showPaymentResultToastFailed)({
|
181
187
|
title: calculateTitle(paymentStatus, failureReason),
|
182
188
|
subtitle: calculateSubtitle(
|
183
189
|
paymentStatus,
|
@@ -187,12 +193,14 @@ var displayPaymentResultToast = (params, config) => {
|
|
187
193
|
),
|
188
194
|
autoClose: (autoCloseConfig == null ? void 0 : autoCloseConfig.autoClose) || false,
|
189
195
|
actionButtons: actionButtons || [],
|
190
|
-
onClose: onToastClose
|
196
|
+
onClose: onToastClose || (() => {
|
197
|
+
})
|
198
|
+
// 提供默认空函数
|
191
199
|
});
|
192
200
|
}
|
193
201
|
};
|
194
202
|
var createShowSuccessToast = (config, getActionButtons) => {
|
195
|
-
return (result) => {
|
203
|
+
return async (result) => {
|
196
204
|
var _a;
|
197
205
|
const responseData = (_a = result.response) == null ? void 0 : _a.data;
|
198
206
|
const paymentStatus = responseData == null ? void 0 : responseData.payment_status;
|
@@ -203,7 +211,7 @@ var createShowSuccessToast = (config, getActionButtons) => {
|
|
203
211
|
!!gapAmount
|
204
212
|
);
|
205
213
|
const actionButtons = getActionButtons ? getActionButtons(paymentStatus) : [];
|
206
|
-
displayPaymentResultToast({
|
214
|
+
await displayPaymentResultToast({
|
207
215
|
paymentStatus,
|
208
216
|
orderTotalAmount,
|
209
217
|
gapAmount,
|
@@ -9,7 +9,7 @@ import { PosProps } from './const';
|
|
9
9
|
*/
|
10
10
|
declare const _default: ({ className, onChange, onClose, formatAmount, isMobile, net, client }: {
|
11
11
|
className?: string | undefined;
|
12
|
-
onChange?: ((status: "
|
12
|
+
onChange?: ((status: "success" | "page" | "fail" | "print" | "mark_tx_processed", params?: string | {
|
13
13
|
[keys: string]: unknown;
|
14
14
|
} | undefined, other?: any) => void) | undefined;
|
15
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;
|
@@ -11,7 +11,7 @@ import './device.less';
|
|
11
11
|
declare const _default: ({ api, onChange, onClose, className, device_number, isMobile, net, client, formatAmount, containerStyle, }: {
|
12
12
|
api: PayProps['api'];
|
13
13
|
className?: string | undefined;
|
14
|
-
onChange?: ((status: "
|
14
|
+
onChange?: ((status: "success" | "page" | "fail" | "print" | "mark_tx_processed", params?: string | {
|
15
15
|
[keys: string]: unknown;
|
16
16
|
} | undefined, other?: any) => void) | undefined;
|
17
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<"
|
18
|
+
readonly statusRef: React.MutableRefObject<"success" | "warn" | "loading" | "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<"
|
22
|
+
readonly eftposRef: React.MutableRefObject<"payo" | "tyro" | "windcave" | "stripe" | "linkly">;
|
23
23
|
readonly clientRef: React.MutableRefObject<ClientEnum>;
|
24
24
|
readonly dataRef: React.MutableRefObject<import("./store").State>;
|
25
25
|
};
|
@@ -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: "
|
177
|
+
status: "success" | "warn" | "loading" | "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?: "pay" | "
|
298
|
+
mode?: "pay" | "fullPay" | "refund" | "query" | undefined;
|
299
299
|
order_id?: string | number | undefined;
|
300
|
-
eftpos?: "
|
301
|
-
action?: "
|
300
|
+
eftpos?: "payo" | "tyro" | "windcave" | "stripe" | "linkly" | undefined;
|
301
|
+
action?: "amount" | "pay" | "deviceList" | undefined;
|
302
302
|
key?: number | undefined;
|
303
303
|
step?: number | undefined;
|
304
304
|
title?: string | undefined;
|
305
305
|
subTitle?: string | undefined;
|
306
|
-
type?: "
|
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?: "
|
311
|
+
status?: "success" | "warn" | "loading" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
|
312
312
|
warn?: string | undefined;
|
313
313
|
steps?: {
|
314
314
|
/** 用于重置当前步骤 */
|
@@ -38,9 +38,13 @@ var import_ahooks = require("ahooks");
|
|
38
38
|
var import_EFTPos = __toESM(require("../../../../eftposPay/EFTPos"));
|
39
39
|
var import_utils = require("../../../../../utils");
|
40
40
|
var import_useLogger = __toESM(require("../../../../../hooks/useLogger"));
|
41
|
+
var import_hooks = require("../../../../../hooks");
|
41
42
|
var import_index = require("./index.less");
|
42
43
|
var updateTransactionReceiveStatus = async (params) => import_utils.request.getRequest().post("/shop/pay/card-reader/transaction/receive/status", params);
|
43
44
|
var EFTPOS = (props, ref) => {
|
45
|
+
var _a;
|
46
|
+
const context = (0, import_hooks.useEngineContext)();
|
47
|
+
const { interaction } = ((_a = context.appHelper) == null ? void 0 : _a.utils) || {};
|
44
48
|
const logger = (0, import_useLogger.default)();
|
45
49
|
const network = (0, import_ahooks.useNetwork)();
|
46
50
|
const [visible, setVisible] = (0, import_react.useState)(false);
|
@@ -51,9 +55,9 @@ var EFTPOS = (props, ref) => {
|
|
51
55
|
const eftposInitDataRef = (0, import_react.useRef)(null);
|
52
56
|
const [isEftposLoading, setIsEftposLoading] = (0, import_react.useState)(false);
|
53
57
|
(0, import_react.useEffect)(() => {
|
54
|
-
var
|
58
|
+
var _a2, _b;
|
55
59
|
if (eftposRef.current) {
|
56
|
-
(_b = (
|
60
|
+
(_b = (_a2 = eftposRef.current) == null ? void 0 : _a2.updateNetwork) == null ? void 0 : _b.call(_a2, { network: network.online });
|
57
61
|
}
|
58
62
|
}, [network.online]);
|
59
63
|
const closeModal = () => {
|
@@ -61,8 +65,8 @@ var EFTPOS = (props, ref) => {
|
|
61
65
|
eftposHandlingRef.current = false;
|
62
66
|
setVisible(false);
|
63
67
|
};
|
64
|
-
const onOpen = ({ source, data, payCallback }) => {
|
65
|
-
var
|
68
|
+
const onOpen = async ({ source, data, payCallback }) => {
|
69
|
+
var _a2, _b, _c, _d, _e;
|
66
70
|
if (eftposHandlingRef.current || visible) {
|
67
71
|
logger == null ? void 0 : logger.addLog({
|
68
72
|
type: "info",
|
@@ -72,6 +76,15 @@ var EFTPOS = (props, ref) => {
|
|
72
76
|
return;
|
73
77
|
}
|
74
78
|
eftposHandlingRef.current = true;
|
79
|
+
let device_number = "";
|
80
|
+
try {
|
81
|
+
device_number = await ((_b = (_a2 = interaction == null ? void 0 : interaction.utils) == null ? void 0 : _a2.asyncDataManager) == null ? void 0 : _b.call(_a2, {
|
82
|
+
module: "get",
|
83
|
+
key: "device_number"
|
84
|
+
}));
|
85
|
+
} catch (error) {
|
86
|
+
console.error("获取设备编号失败", error);
|
87
|
+
}
|
75
88
|
const { type, payMethod, params, mode } = data;
|
76
89
|
const newData = {
|
77
90
|
type,
|
@@ -83,12 +96,14 @@ var EFTPOS = (props, ref) => {
|
|
83
96
|
order_id: params.orderId,
|
84
97
|
name: payMethod.name,
|
85
98
|
symbol: params.symbol,
|
86
|
-
amount: params.amount
|
99
|
+
amount: params.amount,
|
100
|
+
device_number
|
87
101
|
},
|
88
102
|
mode
|
89
103
|
};
|
104
|
+
console.log("newData>>>>>>>>>>>>>>", newData);
|
90
105
|
if (!(newData == null ? void 0 : newData.type) && (newData == null ? void 0 : newData.code)) {
|
91
|
-
newData.type = (
|
106
|
+
newData.type = (_e = (_d = (_c = newData.code) == null ? void 0 : _c.split("_")) == null ? void 0 : _d[1]) == null ? void 0 : _e.toLocaleLowerCase();
|
92
107
|
}
|
93
108
|
logger == null ? void 0 : logger.addLog({
|
94
109
|
type: "info",
|
@@ -113,7 +128,7 @@ var EFTPOS = (props, ref) => {
|
|
113
128
|
}
|
114
129
|
};
|
115
130
|
const onAfterOpenChange = (v) => {
|
116
|
-
var
|
131
|
+
var _a2, _b;
|
117
132
|
logger == null ? void 0 : logger.addLog({
|
118
133
|
type: "info",
|
119
134
|
title: "ToB_EFTPOS_modal_onAfterOpenChange",
|
@@ -121,7 +136,7 @@ var EFTPOS = (props, ref) => {
|
|
121
136
|
});
|
122
137
|
if (v) {
|
123
138
|
const { data, source } = eftposInitDataRef.current;
|
124
|
-
(_b = (
|
139
|
+
(_b = (_a2 = eftposRef.current) == null ? void 0 : _a2.update) == null ? void 0 : _b.call(_a2, data, source);
|
125
140
|
eftposInitDataRef.current = null;
|
126
141
|
}
|
127
142
|
};
|
@@ -148,7 +163,7 @@ var EFTPOS = (props, ref) => {
|
|
148
163
|
eftposHandlingRef.current = false;
|
149
164
|
};
|
150
165
|
const onPayResult = ({ status, params }) => {
|
151
|
-
var
|
166
|
+
var _a2;
|
152
167
|
logger == null ? void 0 : logger.addLog({
|
153
168
|
type: "info",
|
154
169
|
title: "ToB_EFTPOS_onPayResult",
|
@@ -156,7 +171,7 @@ var EFTPOS = (props, ref) => {
|
|
156
171
|
});
|
157
172
|
handleResult(status, params);
|
158
173
|
if (status === "success" || status === "fail") {
|
159
|
-
(
|
174
|
+
(_a2 = payCallbackRef.current) == null ? void 0 : _a2.call(payCallbackRef, { status, params });
|
160
175
|
closeModal();
|
161
176
|
}
|
162
177
|
};
|
@@ -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
|
20
|
+
update: (configUpdate: import("antd").ModalFuncProps | ((prevConfig: import("antd").ModalFuncProps) => import("antd").ModalFuncProps)) => void;
|
21
21
|
}>;
|
22
22
|
export { modal };
|
@@ -48,6 +48,7 @@ var import_notAvailable = __toESM(require("../notAvailable"));
|
|
48
48
|
var import_dayjs = __toESM(require("dayjs"));
|
49
49
|
var import_pisellos = require("../../hooks/pisellos");
|
50
50
|
var import_utils7 = require("./utils");
|
51
|
+
var import_materials = require("@pisell/materials");
|
51
52
|
var productListLayout = {
|
52
53
|
grid: true,
|
53
54
|
config: "12:12"
|
@@ -61,13 +62,13 @@ var productListSetting = {
|
|
61
62
|
isStock: 0
|
62
63
|
};
|
63
64
|
var AddSerivce = (props) => {
|
64
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l
|
65
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
|
65
66
|
const { onEdit, state, dispatch, renderMode = "current", onPrerenderComplete } = props;
|
66
67
|
const context = (0, import_useEngineContext.default)();
|
67
68
|
const notAvailableRef = (0, import_react.useRef)(null);
|
68
69
|
const isLoadedServiceRef = (0, import_react.useRef)(false);
|
69
70
|
import_utils2.request.setRequest(context.appHelper.utils.request);
|
70
|
-
const Toast = (
|
71
|
+
const Toast = (0, import_materials.useToast)();
|
71
72
|
const { createBookingData, createBooking } = (0, import_serviceManager.useService)({
|
72
73
|
renderMode,
|
73
74
|
onEdit,
|
@@ -75,9 +76,9 @@ var AddSerivce = (props) => {
|
|
75
76
|
dispatch
|
76
77
|
});
|
77
78
|
const isBooking4 = (0, import_utils5.isBooking4Shop)(
|
78
|
-
((
|
79
|
+
((_c = (_b = (_a = context.appHelper) == null ? void 0 : _a.utils) == null ? void 0 : _b.getData) == null ? void 0 : _c.call(_b, "shop_id")) || ((_h = (_g = (_f = (_e = (_d = context.appHelper.utils.store) == null ? void 0 : _d.getState) == null ? void 0 : _e.call(_d)) == null ? void 0 : _f.global) == null ? void 0 : _g.globalConfig) == null ? void 0 : _h.id),
|
79
80
|
state == null ? void 0 : state.renderType,
|
80
|
-
(
|
81
|
+
(_i = context.appHelper.utils) == null ? void 0 : _i.businessUtils
|
81
82
|
);
|
82
83
|
const [currentProduct, setCurrentProduct] = (0, import_react.useState)(null);
|
83
84
|
const stateRef = (0, import_react.useRef)(state);
|
@@ -117,11 +118,11 @@ var AddSerivce = (props) => {
|
|
117
118
|
const menuList = (0, import_react.useMemo)(() => {
|
118
119
|
var _a2, _b2, _c2;
|
119
120
|
return ((_c2 = (_b2 = (_a2 = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _a2.config) == null ? void 0 : _b2.menu_list_tab) == null ? void 0 : _c2.menu_list) || [];
|
120
|
-
}, [(
|
121
|
+
}, [(_j = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _j.config]);
|
121
122
|
const customerId = (0, import_react.useMemo)(() => {
|
122
123
|
var _a2, _b2;
|
123
124
|
return ((_b2 = (_a2 = state.client) == null ? void 0 : _a2.value) == null ? void 0 : _b2.id) || void 0;
|
124
|
-
}, [(
|
125
|
+
}, [(_l = (_k = state.client) == null ? void 0 : _k.value) == null ? void 0 : _l.id]);
|
125
126
|
const scanAddService = (0, import_ahooks.useMemoizedFn)((list, code) => {
|
126
127
|
let newService = [...state.service.value];
|
127
128
|
list.forEach((item) => {
|
@@ -38,11 +38,11 @@ var import_utils = require("@pisell/utils");
|
|
38
38
|
var import_icons = require("@ant-design/icons");
|
39
39
|
var import_bookingDashboard = __toESM(require("./bookingDashboard"));
|
40
40
|
var import_bookingList = __toESM(require("./bookingList"));
|
41
|
-
var
|
41
|
+
var import_materials2 = require("@pisell/materials");
|
42
42
|
var import_index = require("./index.less");
|
43
43
|
var BookingDataPanel = (0, import_react.forwardRef)((props, ref) => {
|
44
44
|
const { currentDate, onBookingClick, bookingId } = props;
|
45
|
-
const Toast = (0,
|
45
|
+
const Toast = (0, import_materials2.useToast)();
|
46
46
|
const bookingListRef = (0, import_react.useRef)(null);
|
47
47
|
const bookingDashboardRef = (0, import_react.useRef)(null);
|
48
48
|
const bookingTimeStartBetween = (0, import_react.useMemo)(() => {
|
@@ -250,13 +250,13 @@ var TicketBooking = (props) => {
|
|
250
250
|
interaction,
|
251
251
|
store,
|
252
252
|
storage,
|
253
|
-
Toast,
|
254
253
|
getSymbolic,
|
255
254
|
translation,
|
256
255
|
pisellosAllModule,
|
257
256
|
getData
|
258
257
|
} = (_a = engineContext.appHelper) == null ? void 0 : _a.utils;
|
259
258
|
const { ScheduleModule } = pisellosAllModule;
|
259
|
+
const Toast = (0, import_materials.useToast)();
|
260
260
|
const _persistentRef = (0, import_react.useRef)(false);
|
261
261
|
const _initStateRef = (0, import_react.useRef)({});
|
262
262
|
const _listTimerRef = (0, import_react.useRef)();
|