@pisell/private-materials 6.5.31 → 6.5.32
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 +2 -2
- package/build/lowcode/preview.js +7 -7
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +10 -10
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +10 -10
- package/es/components/appointmentBooking/components/Voucher/index.js +2 -1
- package/es/components/booking/addons/index.js +25 -17
- package/es/components/booking/addons/model.d.ts +1 -10
- package/es/components/booking/components/TabProduct/index.d.ts +1 -0
- package/es/components/booking/components/TabProduct/productItem/index.d.ts +1 -0
- package/es/components/booking/components/TabProduct/selectProductItem/index.d.ts +1 -0
- package/es/components/booking/components/collapsibleList/utils.d.ts +1 -0
- package/es/components/booking/components/emptyBooking/index.d.ts +1 -0
- package/es/components/booking/components/footer/FooterMenus/index.d.ts +1 -0
- package/es/components/booking/components/footer/amount.d.ts +1 -0
- package/es/components/booking/components/footer/amount.js +529 -79
- package/es/components/booking/components/footer/index.js +15 -3
- package/es/components/booking/components/footer/utils.d.ts +19 -0
- package/es/components/booking/components/footer/utils.js +160 -61
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/es/components/booking/components/reloadResourceModal/index.d.ts +1 -0
- package/es/components/booking/components/voucher/index.js +20 -6
- package/es/components/booking/forms/model.d.ts +1 -10
- package/es/components/booking/forms/single/index.d.ts +1 -0
- package/es/components/booking/forms/table/index.d.ts +1 -0
- package/es/components/booking/info/clientVariant/hooks/useClientFn.d.ts +1 -0
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/es/components/booking/info/date/index.d.ts +1 -0
- package/es/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
- package/es/components/booking/info/model.d.ts +1 -10
- package/es/components/booking/info/notes/index.d.ts +1 -0
- package/es/components/booking/info/service/actions/index.d.ts +1 -0
- package/es/components/booking/info/service/like/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.js +1 -0
- package/es/components/booking/info2/service/actions/index.d.ts +1 -0
- package/es/components/booking/info2/service/addService/index.js +2 -3
- package/es/components/booking/info2/service/contactInfoMode/index.d.ts +1 -0
- package/es/components/booking/info2/service/serviceList/index.d.ts +1 -0
- package/es/components/booking/materiels/contacts/index.d.ts +1 -0
- package/es/components/booking/materiels/duration/index.d.ts +1 -0
- package/es/components/booking/materiels/holder/index.d.ts +1 -0
- package/es/components/booking/materiels/startTime/index.d.ts +1 -0
- package/es/components/booking/model.d.ts +1 -9
- package/es/components/booking/notes/NoteBlock/NoteItem/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/notes/model.d.ts +1 -10
- package/es/components/booking/payments/model.d.ts +1 -10
- package/es/components/booking/utils.d.ts +1 -0
- package/es/components/booking/utils.js +16 -3
- package/es/components/checkout/PaymentModal.d.ts +7 -5
- package/es/components/checkout/PaymentModal.js +44 -108
- package/es/components/checkout/components/AdditionalModule/index.js +2 -0
- package/es/components/checkout/components/AmountSummary/index.less +4 -5
- package/es/components/checkout/components/SearchAndClientModule/index.d.ts +1 -0
- package/es/components/checkout/hooks/useWalletPass.d.ts +1 -1
- package/es/components/checkout/utils/PaymentResultToastUtils.d.ts +0 -1
- package/es/components/eftpos/deviceList/index.d.ts +1 -0
- package/es/components/eftpos/form/index.d.ts +1 -0
- package/es/components/eftpos/group/index.d.ts +1 -0
- package/es/components/eftpos/hooks.d.ts +1 -0
- package/es/components/eftpos/icon/apiKey.d.ts +1 -0
- package/es/components/eftpos/icon/device.d.ts +1 -0
- package/es/components/eftpos/index.d.ts +1 -0
- package/es/components/eftpos/pos.d.ts +1 -0
- package/es/components/eftpos/receipt/index.d.ts +1 -0
- package/es/components/eftposPay/amount.d.ts +2 -1
- package/es/components/eftposPay/app.d.ts +1 -0
- package/es/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/es/components/eftposPay/component/fail/failCustom.d.ts +1 -0
- package/es/components/eftposPay/component/fail/index.d.ts +1 -0
- package/es/components/eftposPay/component/fail/network.d.ts +1 -0
- package/es/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/es/components/eftposPay/component/header/titlebar.d.ts +1 -0
- package/es/components/eftposPay/component/manual/index.d.ts +1 -0
- package/es/components/eftposPay/component/signature/index.d.ts +1 -0
- package/es/components/eftposPay/component/step/index.d.ts +1 -0
- package/es/components/eftposPay/component/step/step.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/linkly/hooks/useTimeQuery.js +14 -6
- package/es/components/eftposPay/pay.d.ts +1 -0
- package/es/components/eftposPay/payo/config.d.ts +1 -0
- package/es/components/eftposPay/payo/config.js +70 -32
- package/es/components/eftposPay/payo/payment.d.ts +66 -0
- package/es/components/eftposPay/payo/payment.js +579 -0
- package/es/components/eftposPay/store/index.d.ts +4 -4
- package/es/components/eftposPay/tip.d.ts +1 -0
- package/es/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/es/components/eftposPay/utils/log/index.d.ts +110 -0
- package/es/components/eftposPay/utils/log/index.js +371 -0
- package/es/components/eftposPay/windcave/receiptAction.d.ts +1 -0
- package/es/components/eftposPay/windcave/windcave.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
- package/es/components/index.d.ts +2 -1
- package/es/components/index.js +2 -1
- package/es/components/login/index.d.ts +1 -0
- package/es/components/pay/toB/components/Cache/index.d.ts +1 -0
- package/es/components/pay/toB/components/CardGroup/index.d.ts +1 -0
- package/es/components/pay/toB/components/Content/Header.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +13 -11
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.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/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +6 -0
- package/es/components/pay/toC/PaymentMethods/WalletPass/utils.js +4 -2
- package/es/components/pay/toC/PaymentMethods/components/PaymentReturnContent/index.js +2 -0
- package/es/components/pay/toC/PaymentMethods/components/PaymentReturnContent/index.less +13 -3
- package/es/components/pay/toC/index.js +7 -4
- package/es/components/pay/toC/locales.d.ts +3 -0
- package/es/components/pay/toC/locales.js +6 -3
- package/es/components/pay/toC/model.d.ts +1 -9
- package/es/components/pay/toC/status.d.ts +1 -0
- package/es/components/pay/toC/status.js +3 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/BirthdayField/index.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/GenderField/index.d.ts +1 -0
- package/es/components/productExtension/fields/Actor/index.d.ts +1 -0
- package/es/components/productExtension/fields/Forms/index.d.ts +1 -0
- package/es/components/productExtension/fields/SelectProducts/ProductItem/index.d.ts +1 -0
- package/es/components/productExtension/fields/SelectProducts/ProductItemPreview/index.d.ts +1 -0
- package/es/components/productExtension/fields/SelectProducts/index.d.ts +1 -0
- package/es/components/productExtension/fields/SelectResourcesTable/index.d.ts +1 -0
- package/es/components/productSelect/components/productGroup/index.d.ts +1 -0
- package/es/components/ruleSetting/ruleBorder/index.d.ts +1 -0
- package/es/components/schedules/calendar/calendarItem.d.ts +1 -0
- package/es/components/schedules/calendar/index.d.ts +1 -0
- package/es/components/schedules/components/CurrentDay/index.d.ts +1 -0
- package/es/components/schedules/components/ScheduleDetailList/index.d.ts +1 -0
- package/es/components/schedules/components/ScheduleList/index.d.ts +1 -0
- package/es/components/schedules/model.d.ts +1 -9
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
- package/es/components/schedules/products/index.d.ts +1 -0
- package/es/components/schedules/products/list/ProductItem/index.d.ts +1 -0
- package/es/components/schedules/products/list/index.d.ts +1 -0
- package/es/components/schedules/resources/index.d.ts +1 -0
- package/es/components/schedules/resources/list/index.d.ts +1 -0
- package/es/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/es/components/schedules/schedules/AllSchedules/index.d.ts +1 -0
- package/es/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +1 -0
- package/es/components/schedules/schedules/index.d.ts +1 -0
- package/es/components/shoppingCart/components/Empty/index.d.ts +1 -0
- package/es/components/shoppingCart/components/Render/index.d.ts +1 -0
- package/es/components/shoppingCart/index.d.ts +1 -0
- package/es/components/subTotal/index.js +1 -1
- package/es/components/systemSettings/registry/components/GroupModal.d.ts +4 -0
- package/es/components/{checkout/PaymentPlugin.js → systemSettings/registry/components/GroupModal.js} +132 -171
- package/es/components/systemSettings/registry/components/ItemModal.d.ts +4 -0
- package/es/components/systemSettings/registry/components/ItemModal.js +547 -0
- package/es/components/systemSettings/registry/components/ModuleList.d.ts +4 -0
- package/es/components/systemSettings/registry/components/ModuleList.js +54 -0
- package/es/components/systemSettings/registry/components/SectionList.d.ts +4 -0
- package/es/components/systemSettings/registry/components/SectionList.js +174 -0
- package/es/components/systemSettings/registry/components/SettingsTable.d.ts +4 -0
- package/es/components/systemSettings/registry/components/SettingsTable.js +765 -0
- package/es/components/systemSettings/registry/components/index.d.ts +4 -0
- package/es/components/systemSettings/registry/components/index.js +4 -0
- package/es/components/systemSettings/registry/index.d.ts +5 -0
- package/es/components/systemSettings/registry/index.js +1059 -0
- package/es/components/systemSettings/registry/index.less +410 -0
- package/es/components/systemSettings/registry/locales.d.ts +272 -0
- package/es/components/systemSettings/registry/locales.js +300 -0
- package/es/components/systemSettings/registry/services.d.ts +77 -0
- package/es/components/systemSettings/registry/services.js +472 -0
- package/es/components/systemSettings/registry/types.d.ts +126 -0
- package/es/components/systemSettings/registry/types.js +1 -0
- package/es/components/systemSettings/registry/utils/typeValidation.d.ts +16 -0
- package/es/components/systemSettings/registry/utils/typeValidation.js +284 -0
- package/es/components/systemSettings/registry/utils/validators.d.ts +8 -0
- package/es/components/systemSettings/registry/utils/validators.js +44 -0
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +1 -0
- package/es/components/ticketBooking/utils/index.d.ts +3 -0
- package/es/components/ticketBooking/utils/index.js +36 -13
- package/es/components/wallet/Detail/index.js +34 -2
- package/es/components/wallet/Detail/index.less +11 -0
- package/es/components/wallet/Detail/locales.d.ts +6 -0
- package/es/components/wallet/Detail/locales.js +14 -2
- package/es/components/wallet/Detail/model.d.ts +1 -13
- package/es/components/wallet/DiscountCard/model.d.ts +1 -14
- package/es/components/wallet/PointCard/model.d.ts +1 -13
- package/es/components/wallet/RechargeableCard/model.d.ts +1 -29
- package/es/components/wallet/Voucher/index.js +11 -10
- package/es/components/wallet/Voucher/model.d.ts +1 -13
- package/es/components/wallet/components/WalletCard.js +5 -1
- package/es/components/wallet/index.js +4 -2
- package/es/components/wallet/model.d.ts +1 -9
- package/es/components/wallet/serve.d.ts +7 -0
- package/es/components/wallet/utils.d.ts +48 -0
- package/es/components/wallet/utils.js +342 -0
- package/es/hooks/usePaymentLogger.d.ts +1 -0
- package/es/index.d.ts +4 -0
- package/es/index.js +5 -1
- 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/productSelect/ProductCard/SkuCard/SkuCardA1/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Cover/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Price/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/index.d.ts +1 -0
- package/es/plus/saasCreateOrganization/components/Header.d.ts +1 -0
- package/es/plus/saasRegister/components/EntryEmail.d.ts +1 -0
- package/es/plus/saasRegister/components/EntryInfo.d.ts +1 -0
- package/es/plus/saasRegister/components/GoLogin.d.ts +1 -0
- package/es/plus/saasRegister/components/Header.d.ts +1 -0
- package/es/plus/saasRegister/components/VerifyError.d.ts +1 -0
- package/es/plus/saasRegister/components/VerifyingLink.d.ts +1 -0
- package/es/plus/walletEditor/components/relationProduct/index.d.ts +1 -0
- package/es/plus/walletPassGallery/components/footerButton/index.js +2 -4
- package/es/plus/walletPassGallery/components/footerButton/index.less +14 -59
- package/es/plus/walletPassGallery/components/passDetail/index.d.ts +1 -0
- package/es/plus/walletPassGallery/components/passDetail/index.js +84 -31
- package/es/plus/walletPassGallery/components/passDetail/index.less +4 -0
- package/es/plus/walletPassGallery/components/recharge/index.js +19 -8
- package/es/plus/walletPassGallery/index.js +7 -3
- package/es/plus/walletPassGallery/serve.d.ts +3 -0
- package/es/plus/walletPassGallery/serve.js +4 -2
- package/es/pro/Login2.0/index.less +15 -8
- package/es/pro/pisellPaymentList/example.d.ts +1 -0
- package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +35 -30
- package/lib/components/appointmentBooking/components/Voucher/index.js +2 -1
- package/lib/components/booking/addons/index.js +15 -7
- package/lib/components/booking/addons/model.d.ts +1 -10
- package/lib/components/booking/components/TabProduct/index.d.ts +1 -0
- package/lib/components/booking/components/TabProduct/productItem/index.d.ts +1 -0
- package/lib/components/booking/components/TabProduct/selectProductItem/index.d.ts +1 -0
- package/lib/components/booking/components/collapsibleList/utils.d.ts +1 -0
- package/lib/components/booking/components/emptyBooking/index.d.ts +1 -0
- package/lib/components/booking/components/footer/FooterMenus/index.d.ts +1 -0
- package/lib/components/booking/components/footer/amount.d.ts +1 -0
- package/lib/components/booking/components/footer/amount.js +276 -38
- package/lib/components/booking/components/footer/index.js +15 -3
- package/lib/components/booking/components/footer/utils.d.ts +19 -0
- package/lib/components/booking/components/footer/utils.js +109 -33
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/lib/components/booking/components/reloadResourceModal/index.d.ts +1 -0
- package/lib/components/booking/components/voucher/index.js +21 -7
- package/lib/components/booking/forms/model.d.ts +1 -10
- package/lib/components/booking/forms/single/index.d.ts +1 -0
- package/lib/components/booking/forms/table/index.d.ts +1 -0
- package/lib/components/booking/info/clientVariant/hooks/useClientFn.d.ts +1 -0
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/lib/components/booking/info/date/index.d.ts +1 -0
- package/lib/components/booking/info/hooks/useInfoHolder.d.ts +1 -0
- package/lib/components/booking/info/model.d.ts +1 -10
- package/lib/components/booking/info/notes/index.d.ts +1 -0
- package/lib/components/booking/info/service/actions/index.d.ts +1 -0
- package/lib/components/booking/info/service/like/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.js +1 -0
- package/lib/components/booking/info2/service/actions/index.d.ts +1 -0
- package/lib/components/booking/info2/service/addService/index.js +1 -2
- package/lib/components/booking/info2/service/contactInfoMode/index.d.ts +1 -0
- package/lib/components/booking/info2/service/serviceList/index.d.ts +1 -0
- package/lib/components/booking/materiels/contacts/index.d.ts +1 -0
- package/lib/components/booking/materiels/duration/index.d.ts +1 -0
- package/lib/components/booking/materiels/holder/index.d.ts +1 -0
- package/lib/components/booking/materiels/startTime/index.d.ts +1 -0
- package/lib/components/booking/model.d.ts +1 -9
- package/lib/components/booking/notes/NoteBlock/NoteItem/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/notes/model.d.ts +1 -10
- package/lib/components/booking/payments/model.d.ts +1 -10
- package/lib/components/booking/utils.d.ts +1 -0
- package/lib/components/booking/utils.js +11 -0
- package/lib/components/checkout/PaymentModal.d.ts +7 -5
- package/lib/components/checkout/PaymentModal.js +73 -127
- package/lib/components/checkout/components/AdditionalModule/index.js +2 -0
- package/lib/components/checkout/components/AmountSummary/index.less +4 -5
- package/lib/components/checkout/components/SearchAndClientModule/index.d.ts +1 -0
- package/lib/components/checkout/hooks/useWalletPass.d.ts +1 -1
- package/lib/components/checkout/utils/PaymentResultToastUtils.d.ts +0 -1
- package/lib/components/eftpos/deviceList/index.d.ts +1 -0
- package/lib/components/eftpos/form/index.d.ts +1 -0
- package/lib/components/eftpos/group/index.d.ts +1 -0
- package/lib/components/eftpos/hooks.d.ts +1 -0
- package/lib/components/eftpos/icon/apiKey.d.ts +1 -0
- package/lib/components/eftpos/icon/device.d.ts +1 -0
- package/lib/components/eftpos/index.d.ts +1 -0
- package/lib/components/eftpos/pos.d.ts +1 -0
- package/lib/components/eftpos/receipt/index.d.ts +1 -0
- package/lib/components/eftposPay/amount.d.ts +2 -1
- package/lib/components/eftposPay/app.d.ts +1 -0
- package/lib/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/failCustom.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/index.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/network.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/lib/components/eftposPay/component/header/titlebar.d.ts +1 -0
- package/lib/components/eftposPay/component/manual/index.d.ts +1 -0
- package/lib/components/eftposPay/component/signature/index.d.ts +1 -0
- package/lib/components/eftposPay/component/step/index.d.ts +1 -0
- package/lib/components/eftposPay/component/step/step.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/linkly/hooks/useTimeQuery.js +12 -6
- package/lib/components/eftposPay/pay.d.ts +1 -0
- package/lib/components/eftposPay/payo/config.d.ts +1 -0
- package/lib/components/eftposPay/payo/config.js +98 -73
- package/lib/components/eftposPay/payo/payment.d.ts +66 -0
- package/lib/components/eftposPay/payo/payment.js +357 -0
- package/lib/components/eftposPay/store/index.d.ts +4 -4
- package/lib/components/eftposPay/tip.d.ts +1 -0
- package/lib/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/lib/components/eftposPay/utils/log/index.d.ts +110 -0
- package/lib/components/eftposPay/utils/log/index.js +294 -0
- package/lib/components/eftposPay/windcave/receiptAction.d.ts +1 -0
- package/lib/components/eftposPay/windcave/windcave.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
- package/lib/components/index.d.ts +2 -1
- package/lib/components/index.js +3 -0
- package/lib/components/login/index.d.ts +1 -0
- package/lib/components/pay/toB/components/Cache/index.d.ts +1 -0
- package/lib/components/pay/toB/components/CardGroup/index.d.ts +1 -0
- package/lib/components/pay/toB/components/Content/Header.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +13 -11
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.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/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +6 -0
- package/lib/components/pay/toC/PaymentMethods/WalletPass/utils.js +4 -2
- package/lib/components/pay/toC/PaymentMethods/components/PaymentReturnContent/index.js +1 -1
- package/lib/components/pay/toC/PaymentMethods/components/PaymentReturnContent/index.less +13 -3
- package/lib/components/pay/toC/index.js +4 -1
- package/lib/components/pay/toC/locales.d.ts +3 -0
- package/lib/components/pay/toC/locales.js +6 -3
- package/lib/components/pay/toC/model.d.ts +1 -9
- package/lib/components/pay/toC/status.d.ts +1 -0
- package/lib/components/pay/toC/status.js +5 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/BirthdayField/index.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/GenderField/index.d.ts +1 -0
- package/lib/components/productExtension/fields/Actor/index.d.ts +1 -0
- package/lib/components/productExtension/fields/Forms/index.d.ts +1 -0
- package/lib/components/productExtension/fields/SelectProducts/ProductItem/index.d.ts +1 -0
- package/lib/components/productExtension/fields/SelectProducts/ProductItemPreview/index.d.ts +1 -0
- package/lib/components/productExtension/fields/SelectProducts/index.d.ts +1 -0
- package/lib/components/productExtension/fields/SelectResourcesTable/index.d.ts +1 -0
- package/lib/components/productSelect/components/productGroup/index.d.ts +1 -0
- package/lib/components/ruleSetting/ruleBorder/index.d.ts +1 -0
- package/lib/components/schedules/calendar/calendarItem.d.ts +1 -0
- package/lib/components/schedules/calendar/index.d.ts +1 -0
- package/lib/components/schedules/components/CurrentDay/index.d.ts +1 -0
- package/lib/components/schedules/components/ScheduleDetailList/index.d.ts +1 -0
- package/lib/components/schedules/components/ScheduleList/index.d.ts +1 -0
- package/lib/components/schedules/model.d.ts +1 -9
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
- package/lib/components/schedules/products/index.d.ts +1 -0
- package/lib/components/schedules/products/list/ProductItem/index.d.ts +1 -0
- package/lib/components/schedules/products/list/index.d.ts +1 -0
- package/lib/components/schedules/resources/index.d.ts +1 -0
- package/lib/components/schedules/resources/list/index.d.ts +1 -0
- package/lib/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/lib/components/schedules/schedules/AllSchedules/index.d.ts +1 -0
- package/lib/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +1 -0
- package/lib/components/schedules/schedules/index.d.ts +1 -0
- package/lib/components/shoppingCart/components/Empty/index.d.ts +1 -0
- package/lib/components/shoppingCart/components/Render/index.d.ts +1 -0
- package/lib/components/shoppingCart/index.d.ts +1 -0
- package/lib/components/subTotal/index.js +1 -1
- package/lib/components/systemSettings/registry/components/GroupModal.d.ts +4 -0
- package/lib/components/systemSettings/registry/components/GroupModal.js +177 -0
- package/lib/components/systemSettings/registry/components/ItemModal.d.ts +4 -0
- package/lib/components/systemSettings/registry/components/ItemModal.js +508 -0
- package/lib/components/systemSettings/registry/components/ModuleList.d.ts +4 -0
- package/lib/components/systemSettings/registry/components/ModuleList.js +71 -0
- package/lib/components/systemSettings/registry/components/SectionList.d.ts +4 -0
- package/lib/components/systemSettings/registry/components/SectionList.js +181 -0
- package/lib/components/systemSettings/registry/components/SettingsTable.d.ts +4 -0
- package/lib/components/systemSettings/registry/components/SettingsTable.js +575 -0
- package/lib/components/systemSettings/registry/components/index.d.ts +4 -0
- package/lib/components/systemSettings/registry/components/index.js +48 -0
- package/lib/components/systemSettings/registry/index.d.ts +5 -0
- package/lib/components/systemSettings/registry/index.js +529 -0
- package/lib/components/systemSettings/registry/index.less +410 -0
- package/lib/components/systemSettings/registry/locales.d.ts +272 -0
- package/lib/components/systemSettings/registry/locales.js +324 -0
- package/lib/components/systemSettings/registry/services.d.ts +77 -0
- package/lib/components/systemSettings/registry/services.js +290 -0
- package/lib/components/systemSettings/registry/types.d.ts +126 -0
- package/lib/components/systemSettings/registry/types.js +17 -0
- package/lib/components/systemSettings/registry/utils/typeValidation.d.ts +16 -0
- package/lib/components/systemSettings/registry/utils/typeValidation.js +228 -0
- package/lib/components/systemSettings/registry/utils/validators.d.ts +8 -0
- package/lib/components/systemSettings/registry/utils/validators.js +54 -0
- package/lib/components/ticketBooking/utils/index.d.ts +3 -0
- package/lib/components/ticketBooking/utils/index.js +20 -6
- package/lib/components/wallet/Detail/index.js +31 -3
- package/lib/components/wallet/Detail/index.less +11 -0
- package/lib/components/wallet/Detail/locales.d.ts +6 -0
- package/lib/components/wallet/Detail/locales.js +14 -2
- package/lib/components/wallet/Detail/model.d.ts +1 -13
- package/lib/components/wallet/DiscountCard/model.d.ts +1 -14
- package/lib/components/wallet/PointCard/model.d.ts +1 -13
- package/lib/components/wallet/RechargeableCard/model.d.ts +1 -29
- package/lib/components/wallet/Voucher/index.js +8 -8
- package/lib/components/wallet/Voucher/model.d.ts +1 -13
- package/lib/components/wallet/components/WalletCard.js +4 -0
- package/lib/components/wallet/index.js +2 -2
- package/lib/components/wallet/model.d.ts +1 -9
- package/lib/components/wallet/serve.d.ts +7 -0
- package/lib/components/wallet/utils.d.ts +48 -0
- package/lib/components/wallet/utils.js +287 -0
- package/lib/hooks/usePaymentLogger.d.ts +1 -0
- package/lib/index.d.ts +4 -0
- package/lib/index.js +12 -0
- 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/productSelect/ProductCard/SkuCard/SkuCardA1/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Cover/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Price/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/index.d.ts +1 -0
- package/lib/plus/saasCreateOrganization/components/Header.d.ts +1 -0
- package/lib/plus/saasRegister/components/EntryEmail.d.ts +1 -0
- package/lib/plus/saasRegister/components/EntryInfo.d.ts +1 -0
- package/lib/plus/saasRegister/components/GoLogin.d.ts +1 -0
- package/lib/plus/saasRegister/components/Header.d.ts +1 -0
- package/lib/plus/saasRegister/components/VerifyError.d.ts +1 -0
- package/lib/plus/saasRegister/components/VerifyingLink.d.ts +1 -0
- package/lib/plus/walletEditor/components/relationProduct/index.d.ts +1 -0
- package/lib/plus/walletPassGallery/components/footerButton/index.js +2 -2
- package/lib/plus/walletPassGallery/components/footerButton/index.less +14 -59
- package/lib/plus/walletPassGallery/components/passDetail/index.d.ts +1 -0
- package/lib/plus/walletPassGallery/components/passDetail/index.js +54 -15
- package/lib/plus/walletPassGallery/components/passDetail/index.less +4 -0
- package/lib/plus/walletPassGallery/components/recharge/index.js +7 -1
- package/lib/plus/walletPassGallery/index.js +7 -3
- package/lib/plus/walletPassGallery/serve.d.ts +3 -0
- package/lib/plus/walletPassGallery/serve.js +3 -2
- package/lib/pro/Login2.0/index.less +15 -8
- package/lib/pro/pisellPaymentList/example.d.ts +1 -0
- package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +34 -39
- package/lowcode/settings-registry/meta.ts +29 -0
- package/lowcode/wallet-pass-detail/meta.ts +89 -0
- package/package.json +1 -1
- package/es/components/checkout/PaymentPlugin.d.ts +0 -2
- package/lib/components/checkout/PaymentPlugin.d.ts +0 -2
- package/lib/components/checkout/PaymentPlugin.js +0 -181
|
@@ -47,7 +47,7 @@ var getRelationDetailsTotal = (relation_details) => {
|
|
|
47
47
|
}
|
|
48
48
|
return total.toNumber();
|
|
49
49
|
};
|
|
50
|
-
var getProductExpectAmount = (state, isEdit) => {
|
|
50
|
+
var getProductExpectAmount = (state, isEdit, isOriginTotal) => {
|
|
51
51
|
var _a, _b, _c, _d;
|
|
52
52
|
let price = new import_decimal.default(0);
|
|
53
53
|
let duration = new import_decimal.default(0);
|
|
@@ -59,13 +59,15 @@ var getProductExpectAmount = (state, isEdit) => {
|
|
|
59
59
|
if (isDay || (0, import_utils3.isNormalProductByDurationSchedule)(item)) {
|
|
60
60
|
const quantity = new import_decimal.default(item._extend.quantity || 1);
|
|
61
61
|
const itemTotal = new import_decimal.default(item._extend.total || 0);
|
|
62
|
-
|
|
62
|
+
const itemOriginTotal = new import_decimal.default(item._extend.origin_total || 0);
|
|
63
|
+
price = price.add((isOriginTotal ? itemOriginTotal : itemTotal).mul(quantity));
|
|
63
64
|
const _duration = (0, import_utils3.isDayBookingProduct)(item, state) ? new import_decimal.default(item._extend.duration || 0) : new import_decimal.default(0);
|
|
64
65
|
duration = duration.add(_duration);
|
|
65
66
|
} else {
|
|
66
67
|
const quantity = new import_decimal.default(item._extend.quantity || 1);
|
|
67
68
|
const itemTotal = new import_decimal.default(item._extend.total || 0);
|
|
68
|
-
|
|
69
|
+
const itemOriginTotal = new import_decimal.default(item._extend.origin_total || 0);
|
|
70
|
+
price = price.add((isOriginTotal ? itemOriginTotal : itemTotal).mul(quantity));
|
|
69
71
|
const relationTotal = new import_decimal.default(getRelationDetailsTotal(
|
|
70
72
|
item._extend.relation_details || []
|
|
71
73
|
));
|
|
@@ -79,7 +81,8 @@ var getProductExpectAmount = (state, isEdit) => {
|
|
|
79
81
|
for (let item of state.addons.value) {
|
|
80
82
|
const quantity = new import_decimal.default(item._extend.quantity || 1);
|
|
81
83
|
const itemTotal = new import_decimal.default(item._extend.total || 0);
|
|
82
|
-
|
|
84
|
+
const itemOriginTotal = new import_decimal.default(item._extend.origin_total || 0);
|
|
85
|
+
price = price.add((isOriginTotal ? itemOriginTotal : itemTotal).mul(quantity));
|
|
83
86
|
}
|
|
84
87
|
}
|
|
85
88
|
}
|
|
@@ -130,9 +133,10 @@ var getProductItemTax = (item, state, options) => {
|
|
|
130
133
|
}
|
|
131
134
|
}
|
|
132
135
|
}
|
|
133
|
-
return singleItemTax.times(quantity);
|
|
136
|
+
return singleItemTax.times(quantity).toDecimalPlaces(2, import_decimal.default.ROUND_HALF_UP);
|
|
134
137
|
};
|
|
135
138
|
var processItemsTax = (items, state, options) => {
|
|
139
|
+
var _a, _b, _c;
|
|
136
140
|
const { tax_rate, is_price_include_tax, computed } = options;
|
|
137
141
|
const { shopDiscount, productExpectAmount } = computed;
|
|
138
142
|
let originTax = new import_decimal.default(0);
|
|
@@ -140,10 +144,11 @@ var processItemsTax = (items, state, options) => {
|
|
|
140
144
|
for (let item of items) {
|
|
141
145
|
const quantity = new import_decimal.default(item._extend.quantity || 1);
|
|
142
146
|
const unitPrice = new import_decimal.default(item._extend.total || 0);
|
|
143
|
-
const
|
|
147
|
+
const mainProductPrice = new import_decimal.default(getMainProductTotal(item) || 0);
|
|
148
|
+
let originalTaxPerItem = getProductItemTax(
|
|
144
149
|
{
|
|
145
150
|
...item,
|
|
146
|
-
total:
|
|
151
|
+
total: mainProductPrice.add(((_a = item._extend) == null ? void 0 : _a.surcharge_fee) || 0).toNumber(),
|
|
147
152
|
quantity: 1
|
|
148
153
|
},
|
|
149
154
|
state,
|
|
@@ -153,19 +158,22 @@ var processItemsTax = (items, state, options) => {
|
|
|
153
158
|
if (productExpectAmount > 0) {
|
|
154
159
|
itemDiscount = unitPrice.dividedBy(productExpectAmount).times(shopDiscount);
|
|
155
160
|
}
|
|
156
|
-
|
|
157
|
-
|
|
161
|
+
let mainItemDiscount = new import_decimal.default(0);
|
|
162
|
+
if (unitPrice.greaterThan(0)) {
|
|
163
|
+
mainItemDiscount = mainProductPrice.dividedBy(productExpectAmount).times(shopDiscount);
|
|
164
|
+
}
|
|
165
|
+
const mainItemDiscountedUnitPrice = mainProductPrice.minus(mainItemDiscount).add(((_b = item._extend) == null ? void 0 : _b.surcharge_fee) || 0);
|
|
166
|
+
const maxDiscountedTaxPerItem = getProductItemTax(
|
|
158
167
|
{
|
|
159
168
|
...item,
|
|
160
|
-
total:
|
|
169
|
+
total: mainItemDiscountedUnitPrice.toNumber(),
|
|
161
170
|
price: item._extend.total,
|
|
162
171
|
quantity: 1
|
|
163
172
|
},
|
|
164
173
|
state,
|
|
165
174
|
{ tax_rate, is_price_include_tax }
|
|
166
175
|
);
|
|
167
|
-
item._extend.
|
|
168
|
-
item._extend.tax_fee = discountedTaxPerItem.toNumber();
|
|
176
|
+
item._extend.main_product_attached_bundle_tax_fee = maxDiscountedTaxPerItem.toNumber();
|
|
169
177
|
let addTimeTotalTax = new import_decimal.default(0);
|
|
170
178
|
if (Array.isArray(item._extend.relation_details)) {
|
|
171
179
|
for (let atItem of item._extend.relation_details) {
|
|
@@ -181,8 +189,7 @@ var processItemsTax = (items, state, options) => {
|
|
|
181
189
|
const addTimeTaxPerItem = getProductItemTax(
|
|
182
190
|
{
|
|
183
191
|
...atItem,
|
|
184
|
-
total: _discountedTotal,
|
|
185
|
-
// 可能包含原有数据,或前端临时数据
|
|
192
|
+
total: _discountedTotal.add((atItem == null ? void 0 : atItem.surcharge_fee) || 0).toNumber(),
|
|
186
193
|
quantity: atItem.product_quantity || atItem.num || 1
|
|
187
194
|
},
|
|
188
195
|
state,
|
|
@@ -191,8 +198,51 @@ var processItemsTax = (items, state, options) => {
|
|
|
191
198
|
addTimeTotalTax = addTimeTotalTax.plus(addTimeTaxPerItem);
|
|
192
199
|
}
|
|
193
200
|
}
|
|
194
|
-
|
|
195
|
-
|
|
201
|
+
let bundleTotalOriginTax = new import_decimal.default(0);
|
|
202
|
+
let bundleTotalTax = new import_decimal.default(0);
|
|
203
|
+
if (Array.isArray((_c = item._extend.other) == null ? void 0 : _c.bundle)) {
|
|
204
|
+
for (let bundleItem of item._extend.other.bundle) {
|
|
205
|
+
if (getBundleItemIsOriginalPrice(bundleItem)) {
|
|
206
|
+
const bundleQuantity = new import_decimal.default(bundleItem.quantity || 1);
|
|
207
|
+
const bundleUnitPrice = new import_decimal.default(
|
|
208
|
+
bundleItem.bundle_selling_price ?? bundleItem.price ?? 0
|
|
209
|
+
);
|
|
210
|
+
const bundleOriginalTaxPerItem = getProductItemTax(
|
|
211
|
+
{
|
|
212
|
+
...bundleItem,
|
|
213
|
+
total: bundleUnitPrice.add((bundleItem == null ? void 0 : bundleItem.surcharge_fee) || 0).toNumber(),
|
|
214
|
+
quantity: 1
|
|
215
|
+
},
|
|
216
|
+
state,
|
|
217
|
+
{ tax_rate, is_price_include_tax }
|
|
218
|
+
);
|
|
219
|
+
let bundleItemDiscount = new import_decimal.default(0);
|
|
220
|
+
if (productExpectAmount > 0) {
|
|
221
|
+
bundleItemDiscount = bundleUnitPrice.dividedBy(productExpectAmount).times(shopDiscount);
|
|
222
|
+
}
|
|
223
|
+
const bundleDiscountedUnitPrice = bundleUnitPrice.minus(bundleItemDiscount).add((bundleItem == null ? void 0 : bundleItem.surcharge_fee) || 0);
|
|
224
|
+
const bundleDiscountedTaxPerItem = getProductItemTax(
|
|
225
|
+
{
|
|
226
|
+
...bundleItem,
|
|
227
|
+
total: bundleDiscountedUnitPrice.toNumber(),
|
|
228
|
+
quantity: 1
|
|
229
|
+
},
|
|
230
|
+
state,
|
|
231
|
+
{ tax_rate, is_price_include_tax }
|
|
232
|
+
);
|
|
233
|
+
bundleItem.original_tax_fee = new import_decimal.default(bundleOriginalTaxPerItem).toNumber();
|
|
234
|
+
bundleItem.tax_fee = new import_decimal.default(bundleDiscountedTaxPerItem).toNumber();
|
|
235
|
+
bundleTotalOriginTax = bundleTotalOriginTax.plus(bundleOriginalTaxPerItem.times(bundleQuantity));
|
|
236
|
+
bundleTotalTax = bundleTotalTax.plus(bundleDiscountedTaxPerItem.times(bundleQuantity));
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
const original_tax_fee = originalTaxPerItem.add(bundleTotalOriginTax);
|
|
241
|
+
const tax_fee = maxDiscountedTaxPerItem.add(bundleTotalTax);
|
|
242
|
+
item._extend.original_tax_fee = original_tax_fee.toNumber();
|
|
243
|
+
item._extend.tax_fee = tax_fee.toNumber();
|
|
244
|
+
originTax = originTax.plus(original_tax_fee.times(quantity)).plus(addTimeTotalTax);
|
|
245
|
+
tax = tax.plus(tax_fee.times(quantity)).plus(addTimeTotalTax);
|
|
196
246
|
}
|
|
197
247
|
return { originTax, tax };
|
|
198
248
|
};
|
|
@@ -253,7 +303,7 @@ var isProductMatchSurchargeCondition = (item, options) => {
|
|
|
253
303
|
}
|
|
254
304
|
const isInScheduleByDate = (_a = options.ScheduleModule) == null ? void 0 : _a.isInScheduleByDate;
|
|
255
305
|
const { surchargeConfig, scheduleById = {} } = options;
|
|
256
|
-
const { startDate,
|
|
306
|
+
const { startDate, product_id, isCustomItem } = item;
|
|
257
307
|
const {
|
|
258
308
|
open_product = 0,
|
|
259
309
|
// 1 | 0
|
|
@@ -277,7 +327,6 @@ var isProductMatchSurchargeCondition = (item, options) => {
|
|
|
277
327
|
if (isCustomItem) {
|
|
278
328
|
isProductMatch = false;
|
|
279
329
|
} else {
|
|
280
|
-
const product_id = other == null ? void 0 : other.product_id;
|
|
281
330
|
isProductMatch = available_product_ids.includes(product_id);
|
|
282
331
|
}
|
|
283
332
|
}
|
|
@@ -307,8 +356,75 @@ var isProductMatchSurchargeCondition = (item, options) => {
|
|
|
307
356
|
}
|
|
308
357
|
return isProductMatch && isScheduleMatch;
|
|
309
358
|
};
|
|
359
|
+
var getBundleItemIsOriginalPrice = (item) => {
|
|
360
|
+
return (item == null ? void 0 : item.price_type) === "markup" && (item == null ? void 0 : item.price_type_ext) === "product_price";
|
|
361
|
+
};
|
|
362
|
+
var getBundleItemIsMarkupPrice = (item) => {
|
|
363
|
+
return (item == null ? void 0 : item.price_type) === "markup" && ((item == null ? void 0 : item.price_type_ext) === "" || !(item == null ? void 0 : item.price_type_ext));
|
|
364
|
+
};
|
|
365
|
+
var getBundleItemIsDiscountPrice = (item) => {
|
|
366
|
+
return (item == null ? void 0 : item.price_type) === "markdown" && ((item == null ? void 0 : item.price_type_ext) === "" || !(item == null ? void 0 : item.price_type_ext));
|
|
367
|
+
};
|
|
368
|
+
var getBundleItemIsMarkupOrDiscountPrice = (item) => {
|
|
369
|
+
return getBundleItemIsMarkupPrice(item) || getBundleItemIsDiscountPrice(item);
|
|
370
|
+
};
|
|
371
|
+
var getDiscountAmount = (discounts) => {
|
|
372
|
+
return (discounts || []).reduce((total, discount) => {
|
|
373
|
+
return total.add(new import_decimal.default(discount.amount || 0));
|
|
374
|
+
}, new import_decimal.default(0)).toNumber();
|
|
375
|
+
};
|
|
376
|
+
var getMainProductTotal = (item) => {
|
|
377
|
+
var _a, _b, _c, _d;
|
|
378
|
+
let total = new import_decimal.default(item._extend.main_product_selling_price || item._extend.price || 0);
|
|
379
|
+
if (!item._extend.main_product_selling_price) {
|
|
380
|
+
const discountAmount = getDiscountAmount(item.discount_list);
|
|
381
|
+
total = total.minus(discountAmount);
|
|
382
|
+
}
|
|
383
|
+
if (((_a = item._extend.other) == null ? void 0 : _a.option) && Array.isArray((_b = item._extend.other) == null ? void 0 : _b.option)) {
|
|
384
|
+
total = total.add((_c = item._extend.other) == null ? void 0 : _c.option.reduce((t, option) => {
|
|
385
|
+
return t.add(new import_decimal.default(option.price || 0).mul(option.num || 1));
|
|
386
|
+
}, new import_decimal.default(0)));
|
|
387
|
+
}
|
|
388
|
+
for (let bundleItem of ((_d = item._extend.other) == null ? void 0 : _d.bundle) || []) {
|
|
389
|
+
if (getBundleItemIsMarkupOrDiscountPrice(bundleItem)) {
|
|
390
|
+
const discountAmount = getDiscountAmount(bundleItem.discount_list);
|
|
391
|
+
const bundleItemPrice = new import_decimal.default(bundleItem.bundle_selling_price ?? bundleItem.price ?? 0);
|
|
392
|
+
const bundleItemTotal = bundleItemPrice.minus(discountAmount);
|
|
393
|
+
total = total.add(bundleItemTotal);
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
return total.toNumber();
|
|
397
|
+
};
|
|
398
|
+
var clearSurchargeFee = (state) => {
|
|
399
|
+
var _a, _b;
|
|
400
|
+
const { service, addons } = state;
|
|
401
|
+
if (Array.isArray(service == null ? void 0 : service.value)) {
|
|
402
|
+
for (let item of service.value) {
|
|
403
|
+
item._extend.surcharge_fee = 0;
|
|
404
|
+
item._extend.relation_surcharge_ids = [];
|
|
405
|
+
for (let bundleItem of ((_a = item._extend.other) == null ? void 0 : _a.bundle) || []) {
|
|
406
|
+
bundleItem.surcharge_fee = 0;
|
|
407
|
+
bundleItem.relation_surcharge_ids = [];
|
|
408
|
+
}
|
|
409
|
+
for (let relationDetail of item._extend.relation_details || []) {
|
|
410
|
+
relationDetail.surcharge_fee = 0;
|
|
411
|
+
relationDetail.relation_surcharge_ids = [];
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
if (Array.isArray(addons == null ? void 0 : addons.value)) {
|
|
416
|
+
for (let item of addons.value) {
|
|
417
|
+
item._extend.surcharge_fee = 0;
|
|
418
|
+
item._extend.relation_surcharge_ids = [];
|
|
419
|
+
for (let bundleItem of ((_b = item._extend.other) == null ? void 0 : _b.bundle) || []) {
|
|
420
|
+
bundleItem.surcharge_fee = 0;
|
|
421
|
+
bundleItem.relation_surcharge_ids = [];
|
|
422
|
+
}
|
|
423
|
+
}
|
|
424
|
+
}
|
|
425
|
+
};
|
|
310
426
|
var getSurcharge = (state, options) => {
|
|
311
|
-
var _a;
|
|
427
|
+
var _a, _b, _c, _d, _e;
|
|
312
428
|
const { isEdit, ScheduleModule, surcharge_list, scheduleById } = options;
|
|
313
429
|
const { bookingDetail, bookingId } = state;
|
|
314
430
|
if (!isEdit && bookingId) {
|
|
@@ -333,6 +449,7 @@ var getSurcharge = (state, options) => {
|
|
|
333
449
|
}
|
|
334
450
|
return [];
|
|
335
451
|
}
|
|
452
|
+
clearSurchargeFee(state);
|
|
336
453
|
const { service, addons } = state;
|
|
337
454
|
if (!Array.isArray(surcharge_list) || !(surcharge_list == null ? void 0 : surcharge_list.length)) return [];
|
|
338
455
|
const surchargeWithAmount = [];
|
|
@@ -343,24 +460,89 @@ var getSurcharge = (state, options) => {
|
|
|
343
460
|
fixed = "0",
|
|
344
461
|
id,
|
|
345
462
|
type,
|
|
346
|
-
description
|
|
463
|
+
description,
|
|
464
|
+
open_product
|
|
347
465
|
} = surchargeConfig;
|
|
348
466
|
const matchedItems = [];
|
|
349
467
|
if (Array.isArray(service == null ? void 0 : service.value)) {
|
|
350
468
|
for (let item of service.value) {
|
|
351
|
-
if (isProductMatchSurchargeCondition(
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
469
|
+
if (isProductMatchSurchargeCondition(
|
|
470
|
+
{
|
|
471
|
+
isCustomItem: item.isCustomItem,
|
|
472
|
+
startDate: item._extend.startDate,
|
|
473
|
+
product_id: item.product_id
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
surchargeConfig,
|
|
477
|
+
scheduleById: scheduleById || {},
|
|
478
|
+
ScheduleModule
|
|
479
|
+
}
|
|
480
|
+
)) {
|
|
481
|
+
const total = getMainProductTotal(item);
|
|
482
|
+
const mainQuantity = item._extend.quantity || 1;
|
|
356
483
|
matchedItems.push({
|
|
357
|
-
total
|
|
358
|
-
addTimeTotal: getRelationDetailsTotal(
|
|
359
|
-
|
|
360
|
-
),
|
|
361
|
-
|
|
484
|
+
total,
|
|
485
|
+
// addTimeTotal: getRelationDetailsTotal(
|
|
486
|
+
// item._extend.relation_details || []
|
|
487
|
+
// ),
|
|
488
|
+
isMain: true,
|
|
489
|
+
quantity: mainQuantity,
|
|
490
|
+
item,
|
|
491
|
+
mainQuantity
|
|
492
|
+
// 主商品的mainQuantity等于自己的quantity
|
|
362
493
|
});
|
|
363
494
|
}
|
|
495
|
+
for (let bundleItem of ((_b = item._extend.other) == null ? void 0 : _b.bundle) || []) {
|
|
496
|
+
if (getBundleItemIsOriginalPrice(bundleItem) && isProductMatchSurchargeCondition(
|
|
497
|
+
{
|
|
498
|
+
isCustomItem: false,
|
|
499
|
+
startDate: item._extend.startDate,
|
|
500
|
+
product_id: bundleItem._bundle_product_id
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
surchargeConfig,
|
|
504
|
+
scheduleById: scheduleById || {},
|
|
505
|
+
ScheduleModule
|
|
506
|
+
}
|
|
507
|
+
)) {
|
|
508
|
+
const mainQuantity = item._extend.quantity || 1;
|
|
509
|
+
matchedItems.push({
|
|
510
|
+
isMain: false,
|
|
511
|
+
total: Number(
|
|
512
|
+
bundleItem.bundle_selling_price ?? bundleItem.price ?? 0
|
|
513
|
+
),
|
|
514
|
+
quantity: bundleItem.num || bundleItem.quantity || 1,
|
|
515
|
+
item: bundleItem,
|
|
516
|
+
mainQuantity
|
|
517
|
+
// 子商品的mainQuantity是所属主商品的quantity
|
|
518
|
+
});
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
for (let relationDetail of item._extend.relation_details || []) {
|
|
522
|
+
if (isProductMatchSurchargeCondition(
|
|
523
|
+
{
|
|
524
|
+
isCustomItem: false,
|
|
525
|
+
startDate: item._extend.startDate,
|
|
526
|
+
product_id: relationDetail.product_id
|
|
527
|
+
},
|
|
528
|
+
{
|
|
529
|
+
surchargeConfig,
|
|
530
|
+
scheduleById: scheduleById || {},
|
|
531
|
+
ScheduleModule
|
|
532
|
+
}
|
|
533
|
+
)) {
|
|
534
|
+
matchedItems.push({
|
|
535
|
+
isMain: false,
|
|
536
|
+
total: Number(
|
|
537
|
+
(relationDetail == null ? void 0 : relationDetail.price) || ((_c = relationDetail == null ? void 0 : relationDetail.metadata) == null ? void 0 : _c.main_product_attached_bundle_selling_price)
|
|
538
|
+
),
|
|
539
|
+
quantity: relationDetail.num || relationDetail.quantity || 1,
|
|
540
|
+
item: relationDetail,
|
|
541
|
+
mainQuantity: 1
|
|
542
|
+
// 加时商品不受主商品数量影响
|
|
543
|
+
});
|
|
544
|
+
}
|
|
545
|
+
}
|
|
364
546
|
}
|
|
365
547
|
}
|
|
366
548
|
if (Array.isArray(addons == null ? void 0 : addons.value)) {
|
|
@@ -371,23 +553,61 @@ var getSurcharge = (state, options) => {
|
|
|
371
553
|
ScheduleModule
|
|
372
554
|
})) {
|
|
373
555
|
matchedItems.push({
|
|
556
|
+
isMain: true,
|
|
374
557
|
total: Number(item._extend.total),
|
|
375
|
-
quantity: item._extend.quantity || 1
|
|
558
|
+
quantity: item._extend.quantity || 1,
|
|
559
|
+
item,
|
|
560
|
+
mainQuantity: 1
|
|
561
|
+
// addons独立商品,mainQuantity为1
|
|
376
562
|
});
|
|
377
563
|
}
|
|
378
564
|
}
|
|
379
565
|
}
|
|
380
566
|
let finalAmount = 0;
|
|
567
|
+
const productCount = matchedItems.reduce((total, item) => {
|
|
568
|
+
if (item.isMain) {
|
|
569
|
+
return total + (item.quantity || 1);
|
|
570
|
+
} else {
|
|
571
|
+
return total + (item.quantity || 1) * (item.mainQuantity || 1);
|
|
572
|
+
}
|
|
573
|
+
}, 0);
|
|
574
|
+
let fixedTotal = new import_decimal.default(0);
|
|
381
575
|
if (matchedItems.length > 0) {
|
|
382
576
|
let configTotal = new import_decimal.default(0);
|
|
383
|
-
if (percentage && new import_decimal.default(percentage).gt(0)) {
|
|
577
|
+
if (percentage && new import_decimal.default(percentage).gt(0) || fixed) {
|
|
384
578
|
const percentageRate = new import_decimal.default(percentage);
|
|
385
|
-
for (let item of matchedItems) {
|
|
579
|
+
for (let [index, item] of matchedItems.entries()) {
|
|
580
|
+
const isLast = index === matchedItems.length - 1;
|
|
386
581
|
const itemPrice = new import_decimal.default(Math.max(0, item.total || 0));
|
|
387
|
-
const itemQuantity = new import_decimal.default(item.quantity || 1);
|
|
582
|
+
const itemQuantity = new import_decimal.default(item.isMain ? item.quantity || 1 : item.quantity * item.mainQuantity || 1);
|
|
388
583
|
const addTimeTotal = new import_decimal.default(item.addTimeTotal || 0);
|
|
389
|
-
const
|
|
390
|
-
|
|
584
|
+
const itemTotalSurcharge = itemPrice.times(itemQuantity).plus(addTimeTotal).times(percentageRate);
|
|
585
|
+
const itemSurcharge = itemPrice.times(percentageRate);
|
|
586
|
+
const fixedSurcharge = new import_decimal.default(1).div(productCount).times(fixed).times(100).floor().div(100).toFixed(2);
|
|
587
|
+
const quantity = item.isMain ? item.quantity : item.quantity * item.mainQuantity;
|
|
588
|
+
fixedTotal = fixedTotal.plus(new import_decimal.default(fixedSurcharge).times(quantity).toNumber());
|
|
589
|
+
if (isLast && fixedTotal.gt(0)) {
|
|
590
|
+
const remaining = new import_decimal.default(fixed).minus(fixedTotal).toNumber();
|
|
591
|
+
if (remaining > 0) {
|
|
592
|
+
if (item.isMain) {
|
|
593
|
+
item.item._extend.surcharge_rounding_remainder = remaining;
|
|
594
|
+
} else {
|
|
595
|
+
item.item.surcharge_rounding_remainder = remaining;
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
if (open_product !== 0) {
|
|
600
|
+
if (item.isMain) {
|
|
601
|
+
const originSurchargeFee = new import_decimal.default(item.item._extend.surcharge_fee || 0);
|
|
602
|
+
item.item._extend.surcharge_fee = originSurchargeFee.plus(itemSurcharge).plus(fixedSurcharge).toNumber();
|
|
603
|
+
item.item._extend.relation_surcharge_ids = [...((_d = item.item._extend) == null ? void 0 : _d.relation_surcharge_ids) || [], id];
|
|
604
|
+
} else {
|
|
605
|
+
const originSurchargeFee = new import_decimal.default(item.item.surcharge_fee || 0);
|
|
606
|
+
item.item.surcharge_fee = originSurchargeFee.plus(itemSurcharge).plus(fixedSurcharge).toNumber();
|
|
607
|
+
item.item.relation_surcharge_ids = [...((_e = item.item) == null ? void 0 : _e.relation_surcharge_ids) || [], id];
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
configTotal = configTotal.plus(itemTotalSurcharge);
|
|
391
611
|
}
|
|
392
612
|
}
|
|
393
613
|
if (fixed && new import_decimal.default(fixed).gt(0)) {
|
|
@@ -410,7 +630,10 @@ var getSurcharge = (state, options) => {
|
|
|
410
630
|
type: "default",
|
|
411
631
|
fixed,
|
|
412
632
|
amount: finalAmount,
|
|
413
|
-
percentage
|
|
633
|
+
percentage,
|
|
634
|
+
metadata: {
|
|
635
|
+
open_product
|
|
636
|
+
}
|
|
414
637
|
});
|
|
415
638
|
}
|
|
416
639
|
return surchargeWithAmount;
|
|
@@ -520,6 +743,19 @@ var getSumTotal = (state, options) => {
|
|
|
520
743
|
state,
|
|
521
744
|
options
|
|
522
745
|
});
|
|
746
|
+
const { productExpectAmount: productExpectAmountWithoutDiscount } = getProductExpectAmount(
|
|
747
|
+
state,
|
|
748
|
+
options.isEdit,
|
|
749
|
+
true
|
|
750
|
+
);
|
|
751
|
+
const originExpectAmountWithoutDiscount = getExpectAmount({
|
|
752
|
+
price: productExpectAmountWithoutDiscount,
|
|
753
|
+
tax: originTax,
|
|
754
|
+
surchargeAmount,
|
|
755
|
+
shopDiscount: 0,
|
|
756
|
+
state,
|
|
757
|
+
options
|
|
758
|
+
});
|
|
523
759
|
const sumTotalAmount = getSumTotalAmount({ expectAmount, roundingAmount });
|
|
524
760
|
const sumTotalAmountDecimal = new import_decimal.default((0, import_utils2.formatAmount)(sumTotalAmount, 2, "") || 0);
|
|
525
761
|
const orderPaidAmountDecimal = new import_decimal.default(orderPaidAmount || 0);
|
|
@@ -546,7 +782,9 @@ var getSumTotal = (state, options) => {
|
|
|
546
782
|
totalRefundAmount,
|
|
547
783
|
dueAmount,
|
|
548
784
|
roundingAmount,
|
|
549
|
-
originExpectAmount
|
|
785
|
+
originExpectAmount,
|
|
786
|
+
// 订单原价 不包含整单折扣 不包含商品券折扣卡抵扣
|
|
787
|
+
originExpectAmountWithoutDiscount
|
|
550
788
|
};
|
|
551
789
|
};
|
|
552
790
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -62,7 +62,7 @@ var import_ahooks = require("ahooks");
|
|
|
62
62
|
var import_lodash = require("lodash");
|
|
63
63
|
var import_useShopDiscountModule = require("../../../ticketBooking/hooks/pisellos/useShopDiscountModule");
|
|
64
64
|
var Footer = (props) => {
|
|
65
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
|
|
65
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
|
|
66
66
|
const { state, buttons, dispatch, source } = props;
|
|
67
67
|
const [showDetail, setShowDetail] = (0, import_react.useState)(false);
|
|
68
68
|
const [loading, setLoading] = (0, import_react.useState)(false);
|
|
@@ -1420,8 +1420,20 @@ var Footer = (props) => {
|
|
|
1420
1420
|
data: paymentModalData,
|
|
1421
1421
|
callback: paymentCallback || void 0,
|
|
1422
1422
|
setEditCartMode,
|
|
1423
|
-
state,
|
|
1424
|
-
|
|
1423
|
+
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,
|
|
1424
|
+
shopDiscount: state.shop_discount,
|
|
1425
|
+
client: (_t = state.client) == null ? void 0 : _t.value,
|
|
1426
|
+
currentTotalPrice: total.productAmount,
|
|
1427
|
+
onChangeShopDiscount: (discount) => {
|
|
1428
|
+
dispatch({
|
|
1429
|
+
type: "setState",
|
|
1430
|
+
payload: {
|
|
1431
|
+
shop_discount: discount
|
|
1432
|
+
}
|
|
1433
|
+
});
|
|
1434
|
+
},
|
|
1435
|
+
onChangeOrderNote: handleNoteConfirm,
|
|
1436
|
+
onDeleteOrderNote: handleNoteDelete,
|
|
1425
1437
|
onClose: (reset) => {
|
|
1426
1438
|
setIsPaymentModalOpen(false);
|
|
1427
1439
|
setPaymentModalData(null);
|
|
@@ -16,6 +16,11 @@ export declare const formatProductOption: (option: any) => any;
|
|
|
16
16
|
* @Date: 2024-02-19 09:26
|
|
17
17
|
*/
|
|
18
18
|
export declare const formatProductBundle: (bundle: any) => any;
|
|
19
|
+
/**
|
|
20
|
+
* 获取子商品折扣信息
|
|
21
|
+
* @param item
|
|
22
|
+
*/
|
|
23
|
+
export declare const getBundleDiscountList: (bundle: any[]) => any[];
|
|
19
24
|
export interface ResourceItem {
|
|
20
25
|
[key: string]: any;
|
|
21
26
|
}
|
|
@@ -37,5 +42,19 @@ export declare const checkResourcesFormat: (resources: any[], service: any, isCh
|
|
|
37
42
|
* @Date: 2024-12-23 12:05
|
|
38
43
|
*/
|
|
39
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;
|
|
40
59
|
export declare const formatValues: (state: any) => any;
|
|
41
60
|
export declare const checkHolderIsError: (state: any) => any;
|