@pisell/private-materials 3.3.102 → 3.3.104
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 +13 -13
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +11 -11
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +11 -11
- package/es/components/Sales/Cart/index.js +5 -1
- package/es/components/Sales/Cart/utils.d.ts +40 -0
- package/es/components/Sales/Cart/utils.js +167 -0
- package/es/components/Sales/Checkout/index.d.ts +4 -0
- package/es/components/Sales/Checkout/index.js +52 -8
- package/es/components/Sales/Checkout/serve.d.ts +13 -0
- package/es/components/Sales/Checkout/serve.js +16 -2
- package/es/components/Sales/Checkout/utils.js +7 -1
- package/es/components/Sales/Summary/index.d.ts +10 -0
- package/es/components/Sales/Summary/index.js +17 -2
- package/es/components/Sales/Summary/serve.d.ts +1 -0
- package/es/components/Sales/Summary/serve.js +6 -0
- package/es/components/Sales/Summary/utils.d.ts +15 -0
- package/es/components/Sales/Summary/utils.js +43 -1
- package/es/components/appointmentBooking/components/Cart/Item/index.js +1 -0
- package/es/components/appointmentBooking/components/Cart/Item/index.less +3 -3
- package/es/components/appointmentBooking/components/Content/index.js +15 -1
- package/es/components/appointmentBooking/components/Content/index.less +1 -1
- package/es/components/appointmentBooking/components/Deposit/index.d.ts +6 -0
- package/es/components/appointmentBooking/components/Deposit/index.js +27 -7
- package/es/components/appointmentBooking/components/Footer/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Header/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Resource/index.js +1 -0
- package/es/components/appointmentBooking/components/Services/index.js +23 -27
- package/es/components/appointmentBooking/deposit/components/PolicyModal/index.js +25 -20
- package/es/components/appointmentBooking/deposit/index.js +4 -2
- package/es/components/appointmentBooking/index.js +14 -0
- package/es/components/appointmentBooking/index.less +1 -1
- package/es/components/booking/addons/model.d.ts +10 -1
- 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/TabProduct/tabs/index.js +1 -5
- package/es/components/booking/components/browserSelect/index.js +1 -1
- 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/index.d.ts +1 -0
- package/es/components/booking/components/footer/utils.d.ts +41 -0
- package/es/components/booking/components/voucher/index.js +2 -2
- package/es/components/booking/deposit/index.d.ts +1 -0
- package/es/components/booking/forms/model.d.ts +10 -1
- package/es/components/booking/forms/model.js +5 -5
- package/es/components/booking/forms/single/index.d.ts +1 -0
- package/es/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useClientFn.d.ts +1 -0
- package/es/components/booking/info/date/index.d.ts +1 -0
- package/es/components/booking/info/header/index.d.ts +1 -0
- package/es/components/booking/info/index.d.ts +0 -1
- package/es/components/booking/info/model.d.ts +10 -1
- package/es/components/booking/info/notes/index.d.ts +1 -0
- package/es/components/booking/info/service/Lists.d.ts +1 -0
- package/es/components/booking/info/service/actions/index.d.ts +1 -0
- package/es/components/booking/info/service/like/index.js +1 -1
- 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/service/actions/index.d.ts +1 -0
- package/es/components/booking/info2/service/addService/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/startTime/index.d.ts +1 -0
- package/es/components/booking/materiels/startTime/index.js +1 -1
- package/es/components/booking/model.d.ts +9 -1
- package/es/components/booking/notes/NoteBlock/NoteItem/index.d.ts +1 -0
- package/es/components/booking/notes/NoteBlock/NoteItem/index.js +1 -1
- package/es/components/booking/notes/NoteBlock/index.d.ts +1 -0
- package/es/components/booking/notes/NoteBlock/index.js +11 -11
- package/es/components/booking/notes/addNote/index.d.ts +1 -0
- package/es/components/booking/notes/model.d.ts +10 -1
- package/es/components/booking/notes/model.js +5 -5
- package/es/components/booking/payments/model.d.ts +10 -1
- package/es/components/booking/payments/model.js +5 -5
- package/es/components/booking/utils.d.ts +2 -2
- package/es/components/eftpos/index.d.ts +1 -0
- package/es/components/eftpos/pos.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/fail/network.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/const.d.ts +4 -1
- package/es/components/eftposPay/const.js +3 -1
- package/es/components/eftposPay/device.d.ts +2 -1
- package/es/components/eftposPay/hooks.d.ts +2 -2
- package/es/components/eftposPay/hooks.js +3 -1
- package/es/components/eftposPay/index.js +1 -1
- package/es/components/eftposPay/linkly/const.d.ts +23 -0
- package/es/components/eftposPay/linkly/const.js +82 -0
- package/es/components/eftposPay/linkly/hooks/index.d.ts +2 -0
- package/es/components/eftposPay/linkly/hooks/index.js +2 -0
- package/es/components/eftposPay/linkly/hooks/normal.d.ts +30 -0
- package/es/components/eftposPay/linkly/hooks/normal.js +321 -0
- package/es/components/eftposPay/linkly/hooks/useTimeQuery.d.ts +4 -0
- package/es/components/eftposPay/linkly/hooks/useTimeQuery.js +273 -0
- package/es/components/eftposPay/linkly/index.d.ts +2 -0
- package/es/components/eftposPay/linkly/index.js +197 -0
- package/es/components/eftposPay/linkly/service.d.ts +32 -0
- package/es/components/eftposPay/linkly/service.js +81 -0
- package/es/components/eftposPay/manufacturer.d.ts +1 -0
- package/es/components/eftposPay/manufacturer.js +4 -0
- package/es/components/eftposPay/pay.d.ts +1 -1
- package/es/components/eftposPay/pay.js +6 -2
- package/es/components/eftposPay/payo/config.d.ts +1 -0
- package/es/components/eftposPay/store/index.d.ts +6 -6
- package/es/components/eftposPay/tip.d.ts +1 -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/ErrorTip/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +29 -17
- package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Cart/Deposit/index.js +17 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/Total.js +10 -6
- package/es/components/eventBooking/components/Provider/Cart/Item/index.js +4 -2
- package/es/components/eventBooking/components/Provider/Content/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/Header/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/SelectHolderModal.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +1 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
- package/es/components/eventBooking/components/bookingDetailModal/index.js +3 -1
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +0 -1
- package/es/components/eventBooking/index.d.ts +1 -0
- package/es/components/eventBooking/locales.d.ts +24 -0
- package/es/components/eventBooking/locales.js +27 -3
- package/es/components/listComponent/index.js +5 -5
- package/es/components/login/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/index.js +5 -4
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +0 -1
- package/es/components/pay/toC/model.d.ts +9 -1
- 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/pisellSelectCustomerModal/RightPanel/Add/index.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/index.d.ts +1 -0
- package/es/components/productExtension/card/index.js +3 -3
- package/es/components/productExtension/fields/Actor/CutOffTime/index.js +1 -1
- package/es/components/productExtension/fields/Forms/index.js +12 -12
- 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/ProductItemPreview/index.js +1 -1
- package/es/components/productExtension/fields/SelectProducts/index.d.ts +1 -0
- package/es/components/productExtension/fields/SelectProducts/server.js +2 -2
- package/es/components/productExtension/fields/SelectResourcesTable/index.d.ts +1 -0
- package/es/components/productExtension/fields/SelectResourcesTable/server.js +2 -2
- package/es/components/productExtension/index.d.ts +1 -0
- package/es/components/productExtension/server.js +2 -2
- package/es/components/ruleSetting/ruleBorder/index.d.ts +1 -0
- package/es/components/ruleSetting/ruleBorder/index.js +1 -1
- package/es/components/schedules/calendar/index.d.ts +1 -0
- package/es/components/schedules/calendar/index.js +4 -4
- package/es/components/schedules/calendar/serve.js +2 -2
- package/es/components/schedules/components/CurrentDay/index.js +5 -5
- package/es/components/schedules/components/CurrentDay/serve.js +2 -2
- package/es/components/schedules/components/DropdownSort/index.js +1 -1
- package/es/components/schedules/components/ResourceList/index.js +1 -1
- 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/components/Search/index.js +5 -5
- package/es/components/schedules/model.d.ts +9 -1
- package/es/components/schedules/model.js +5 -5
- package/es/components/schedules/openHours/index.js +1 -1
- package/es/components/schedules/openHours/serve.js +2 -2
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.js +1 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.js +5 -5
- 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/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.js +4 -4
- package/es/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/index.js +3 -3
- 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/products/serve.js +2 -2
- package/es/components/schedules/products/utils.js +5 -5
- package/es/components/schedules/resources/detail/detailContent.js +2 -2
- package/es/components/schedules/resources/detail/index.js +10 -10
- 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/list/index.js +2 -2
- package/es/components/schedules/resources/relationProduct/index.js +1 -1
- package/es/components/schedules/resources/serve.js +2 -2
- 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/ScheduleDetailDrawer/index.js +9 -9
- package/es/components/schedules/schedules/index.d.ts +1 -0
- package/es/components/schedules/utils.d.ts +1 -1
- package/es/components/schedules/utils.js +4 -4
- package/es/components/selectModal/index.js +2 -2
- package/es/components/shoppingCart/components/Cart/Product.d.ts +0 -1
- package/es/components/shoppingCart/index.d.ts +1 -0
- package/es/components/taxSelect/index.d.ts +1 -0
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +1 -1
- package/es/components/ticketBooking/components/menuBar/index.d.ts +0 -1
- package/es/components/ticketBooking/components/ticketBooking/index.js +120 -1
- package/es/components/ticketBooking/index.d.ts +1 -0
- package/es/components/ticketBooking/locales.d.ts +164 -146
- package/es/components/ticketBooking/locales.js +195 -147
- package/es/components/ticketBooking/utils/formatProductMessage.d.ts +2 -0
- package/es/components/ticketBooking/utils/formatProductMessage.js +62 -0
- package/es/components/ticketBooking/utils/formatTime.d.ts +31 -0
- package/es/components/ticketBooking/utils/formatTime.js +144 -0
- package/es/components/wallet/Detail/model.d.ts +13 -1
- package/es/components/wallet/DiscountCard/model.d.ts +14 -1
- package/es/components/wallet/PointCard/model.d.ts +13 -1
- package/es/components/wallet/RechargeableCard/model.d.ts +29 -1
- package/es/components/wallet/Voucher/model.d.ts +13 -1
- package/es/components/wallet/hooks/useWalletCard.d.ts +1 -0
- package/es/components/wallet/model.d.ts +9 -1
- package/es/components/workSpaceList/components/Modal/index.d.ts +0 -1
- package/es/components/workSpaceList/components/SearchWorkspaceAndBase/index.d.ts +0 -1
- package/es/hooks/useComponents.js +1 -1
- package/es/utils/index.d.ts +1 -1
- package/lib/components/Sales/Cart/index.js +1 -0
- package/lib/components/Sales/Cart/utils.d.ts +40 -0
- package/lib/components/Sales/Cart/utils.js +117 -0
- package/lib/components/Sales/Checkout/index.d.ts +4 -0
- package/lib/components/Sales/Checkout/index.js +39 -7
- package/lib/components/Sales/Checkout/serve.d.ts +13 -0
- package/lib/components/Sales/Checkout/serve.js +7 -2
- package/lib/components/Sales/Checkout/utils.js +2 -0
- package/lib/components/Sales/Summary/index.d.ts +10 -0
- package/lib/components/Sales/Summary/index.js +7 -1
- package/lib/components/Sales/Summary/serve.d.ts +1 -0
- package/lib/components/Sales/Summary/serve.js +32 -0
- package/lib/components/Sales/Summary/utils.d.ts +15 -0
- package/lib/components/Sales/Summary/utils.js +30 -1
- package/lib/components/appointmentBooking/components/Cart/Item/index.js +1 -0
- package/lib/components/appointmentBooking/components/Cart/Item/index.less +3 -3
- package/lib/components/appointmentBooking/components/Content/index.js +6 -1
- package/lib/components/appointmentBooking/components/Content/index.less +1 -1
- package/lib/components/appointmentBooking/components/Deposit/index.d.ts +6 -0
- package/lib/components/appointmentBooking/components/Deposit/index.js +36 -4
- package/lib/components/appointmentBooking/components/Footer/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Header/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Resource/index.js +1 -0
- package/lib/components/appointmentBooking/components/Services/index.js +6 -11
- package/lib/components/appointmentBooking/deposit/components/PolicyModal/index.js +8 -4
- package/lib/components/appointmentBooking/deposit/index.js +4 -2
- package/lib/components/appointmentBooking/index.js +11 -0
- package/lib/components/appointmentBooking/index.less +1 -1
- package/lib/components/booking/addons/model.d.ts +10 -1
- 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/index.d.ts +1 -0
- package/lib/components/booking/components/footer/utils.d.ts +41 -0
- package/lib/components/booking/components/voucher/index.js +2 -2
- package/lib/components/booking/deposit/index.d.ts +1 -0
- package/lib/components/booking/forms/model.d.ts +10 -1
- package/lib/components/booking/forms/single/index.d.ts +1 -0
- package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useClientFn.d.ts +1 -0
- package/lib/components/booking/info/date/index.d.ts +1 -0
- package/lib/components/booking/info/header/index.d.ts +1 -0
- package/lib/components/booking/info/index.d.ts +0 -1
- package/lib/components/booking/info/model.d.ts +10 -1
- package/lib/components/booking/info/notes/index.d.ts +1 -0
- package/lib/components/booking/info/service/Lists.d.ts +1 -0
- package/lib/components/booking/info/service/actions/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/service/actions/index.d.ts +1 -0
- package/lib/components/booking/info2/service/addService/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/startTime/index.d.ts +1 -0
- package/lib/components/booking/model.d.ts +9 -1
- 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 +10 -1
- package/lib/components/booking/payments/model.d.ts +10 -1
- package/lib/components/booking/utils.d.ts +2 -2
- package/lib/components/eftpos/index.d.ts +1 -0
- package/lib/components/eftpos/pos.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/fail/network.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/const.d.ts +4 -1
- package/lib/components/eftposPay/const.js +2 -0
- package/lib/components/eftposPay/device.d.ts +2 -1
- package/lib/components/eftposPay/hooks.d.ts +2 -2
- package/lib/components/eftposPay/hooks.js +11 -4
- package/lib/components/eftposPay/index.js +1 -1
- package/lib/components/eftposPay/linkly/const.d.ts +23 -0
- package/lib/components/eftposPay/linkly/const.js +102 -0
- package/lib/components/eftposPay/linkly/hooks/index.d.ts +2 -0
- package/lib/components/eftposPay/linkly/hooks/index.js +25 -0
- package/lib/components/eftposPay/linkly/hooks/normal.d.ts +30 -0
- package/lib/components/eftposPay/linkly/hooks/normal.js +242 -0
- package/lib/components/eftposPay/linkly/hooks/useTimeQuery.d.ts +4 -0
- package/lib/components/eftposPay/linkly/hooks/useTimeQuery.js +222 -0
- package/lib/components/eftposPay/linkly/index.d.ts +2 -0
- package/lib/components/eftposPay/linkly/index.js +208 -0
- package/lib/components/eftposPay/linkly/service.d.ts +32 -0
- package/lib/components/eftposPay/linkly/service.js +55 -0
- package/lib/components/eftposPay/manufacturer.d.ts +1 -0
- package/lib/components/eftposPay/manufacturer.js +6 -0
- package/lib/components/eftposPay/pay.d.ts +1 -1
- package/lib/components/eftposPay/pay.js +13 -2
- package/lib/components/eftposPay/payo/config.d.ts +1 -0
- package/lib/components/eftposPay/store/index.d.ts +6 -6
- package/lib/components/eftposPay/tip.d.ts +1 -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/ErrorTip/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +16 -3
- package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.js +55 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/Total.js +8 -5
- package/lib/components/eventBooking/components/Provider/Cart/Item/index.js +4 -2
- package/lib/components/eventBooking/components/Provider/Content/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/Header/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/SelectHolderModal.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingDetailModal/index.js +1 -1
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +0 -1
- package/lib/components/eventBooking/index.d.ts +1 -0
- package/lib/components/eventBooking/locales.d.ts +24 -0
- package/lib/components/eventBooking/locales.js +27 -3
- package/lib/components/login/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/index.js +10 -9
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +0 -1
- package/lib/components/pay/toC/model.d.ts +9 -1
- 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/pisellSelectCustomerModal/RightPanel/Add/index.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/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/productExtension/index.d.ts +1 -0
- package/lib/components/ruleSetting/ruleBorder/index.d.ts +1 -0
- package/lib/components/schedules/calendar/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 +9 -1
- 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/SchedulesModule/AddSchedules/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/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/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/schedules/utils.d.ts +1 -1
- package/lib/components/schedules/utils.js +1 -1
- package/lib/components/shoppingCart/components/Cart/Product.d.ts +0 -1
- package/lib/components/shoppingCart/index.d.ts +1 -0
- package/lib/components/taxSelect/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/addServiceVariant/addService.js +1 -1
- package/lib/components/ticketBooking/components/menuBar/index.d.ts +0 -1
- package/lib/components/ticketBooking/components/ticketBooking/index.js +120 -1
- package/lib/components/ticketBooking/index.d.ts +1 -0
- package/lib/components/ticketBooking/locales.d.ts +164 -146
- package/lib/components/ticketBooking/locales.js +22 -4
- package/lib/components/ticketBooking/utils/formatProductMessage.d.ts +2 -0
- package/lib/components/ticketBooking/utils/formatProductMessage.js +84 -0
- package/lib/components/ticketBooking/utils/formatTime.d.ts +31 -0
- package/lib/components/ticketBooking/utils/formatTime.js +139 -0
- package/lib/components/wallet/Detail/model.d.ts +13 -1
- package/lib/components/wallet/DiscountCard/model.d.ts +14 -1
- package/lib/components/wallet/PointCard/model.d.ts +13 -1
- package/lib/components/wallet/RechargeableCard/model.d.ts +29 -1
- package/lib/components/wallet/Voucher/model.d.ts +13 -1
- package/lib/components/wallet/hooks/useWalletCard.d.ts +1 -0
- package/lib/components/wallet/model.d.ts +9 -1
- package/lib/components/workSpaceList/components/Modal/index.d.ts +0 -1
- package/lib/components/workSpaceList/components/SearchWorkspaceAndBase/index.d.ts +0 -1
- package/lib/utils/index.d.ts +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
|
+
import React, { useEffect, useRef } from 'react';
|
|
8
|
+
import { Button } from 'antd';
|
|
9
|
+
import { locales } from '@pisell/utils';
|
|
10
|
+
import { useContextData, useDispatch, updateCustom, updateState, updateNextStep } from "../store";
|
|
11
|
+
import { useFail, useStoreRef } from "../hooks";
|
|
12
|
+
import useEngineContext from "../../../hooks/useEngineContext";
|
|
13
|
+
import { request } from "../../../utils";
|
|
14
|
+
import Step from "../component/step/step";
|
|
15
|
+
import { StatusEnum } from "../const";
|
|
16
|
+
import { useLinklyCancel, useLinklyPayOrRefund, useTimeResultQuery, useLinklySignature } from "./hooks";
|
|
17
|
+
import { LinklyActionStatus } from "./const";
|
|
18
|
+
import { getPayParams } from "../helper";
|
|
19
|
+
var Linkly = function Linkly(_ref) {
|
|
20
|
+
var api = _ref.api,
|
|
21
|
+
onChange = _ref.onChange;
|
|
22
|
+
// 设置request
|
|
23
|
+
var context = useEngineContext();
|
|
24
|
+
var utils = context.appHelper.utils || {};
|
|
25
|
+
request.setRequest(utils === null || utils === void 0 ? void 0 : utils.request);
|
|
26
|
+
var _useContextData = useContextData(),
|
|
27
|
+
custom = _useContextData.custom,
|
|
28
|
+
status = _useContextData.status;
|
|
29
|
+
var _useStoreRef = useStoreRef(),
|
|
30
|
+
statusRef = _useStoreRef.statusRef,
|
|
31
|
+
netRef = _useStoreRef.netRef,
|
|
32
|
+
modeRef = _useStoreRef.modeRef,
|
|
33
|
+
amountRef = _useStoreRef.amountRef,
|
|
34
|
+
orderIdRef = _useStoreRef.orderIdRef,
|
|
35
|
+
numRef = _useStoreRef.numRef,
|
|
36
|
+
deviceRef = _useStoreRef.deviceRef,
|
|
37
|
+
payRef = _useStoreRef.payRef;
|
|
38
|
+
var dispatch = useDispatch();
|
|
39
|
+
var stepRef = useRef(custom === null || custom === void 0 ? void 0 : custom.step);
|
|
40
|
+
var fail = useFail(0);
|
|
41
|
+
var failRef = useRef(fail);
|
|
42
|
+
var initRef = useRef(false);
|
|
43
|
+
var controllerRef = useRef();
|
|
44
|
+
var unloadRef = useRef(false);
|
|
45
|
+
var clearRef = useRef();
|
|
46
|
+
|
|
47
|
+
// 检查是否可以继续处理接口返回结果,无网 或 已卸载 则不进行处理
|
|
48
|
+
var handleCheck = function handleCheck() {
|
|
49
|
+
return !(unloadRef.current || !netRef.current);
|
|
50
|
+
};
|
|
51
|
+
var handleLinklySuccess = function handleLinklySuccess(res) {
|
|
52
|
+
var resData = (res === null || res === void 0 ? void 0 : res.data) || {};
|
|
53
|
+
var receipt = Array.isArray(resData === null || resData === void 0 ? void 0 : resData.receipt) ? resData.receipt : [resData.receipt];
|
|
54
|
+
receipt = receipt.filter(function (item) {
|
|
55
|
+
return typeof item === 'string';
|
|
56
|
+
}).filter(Boolean);
|
|
57
|
+
dispatch(updateNextStep());
|
|
58
|
+
// 将所有步骤状态设为完成 resolve
|
|
59
|
+
dispatch(updateCustom({
|
|
60
|
+
card_reader_surcharge: (resData === null || resData === void 0 ? void 0 : resData.card_reader_surcharge) || 0,
|
|
61
|
+
receipt: receipt
|
|
62
|
+
}));
|
|
63
|
+
|
|
64
|
+
// 更新支付状态与文案
|
|
65
|
+
dispatch(updateState({
|
|
66
|
+
status: 'success',
|
|
67
|
+
title: locales.getText('page.eftpos-pay.text.successful')(modeRef.current)
|
|
68
|
+
}));
|
|
69
|
+
clearRef.current = setTimeout(function () {
|
|
70
|
+
var _deviceRef$current;
|
|
71
|
+
var params = getPayParams({
|
|
72
|
+
mode: modeRef.current,
|
|
73
|
+
amount: amountRef.current,
|
|
74
|
+
order_id: orderIdRef.current,
|
|
75
|
+
number: numRef.current,
|
|
76
|
+
device: deviceRef.current,
|
|
77
|
+
pay: payRef.current,
|
|
78
|
+
custom: {
|
|
79
|
+
card_reader_surcharge: (resData === null || resData === void 0 ? void 0 : resData.card_reader_surcharge) || 0,
|
|
80
|
+
receipt: receipt
|
|
81
|
+
}
|
|
82
|
+
}, 'success');
|
|
83
|
+
onChange('success', _objectSpread(_objectSpread({}, params), {}, {
|
|
84
|
+
receipt: (_deviceRef$current = deviceRef.current) !== null && _deviceRef$current !== void 0 && (_deviceRef$current = _deviceRef$current.setting) !== null && _deviceRef$current !== void 0 && _deviceRef$current.receipts ? [] : receipt
|
|
85
|
+
}));
|
|
86
|
+
}, 1000);
|
|
87
|
+
};
|
|
88
|
+
var _useLinklyPayOrRefund = useLinklyPayOrRefund(handleCheck),
|
|
89
|
+
payOrRefund = _useLinklyPayOrRefund.payOrRefund;
|
|
90
|
+
var _useLinklyCancel = useLinklyCancel(handleCheck),
|
|
91
|
+
linklyCancel = _useLinklyCancel.linklyCancel;
|
|
92
|
+
var _useTimeResultQuery = useTimeResultQuery(api, handleCheck, handleLinklySuccess),
|
|
93
|
+
resultQuery = _useTimeResultQuery.run,
|
|
94
|
+
stopResultQuery = _useTimeResultQuery.stop;
|
|
95
|
+
var _useLinklySignature = useLinklySignature(handleCheck),
|
|
96
|
+
linklySignature = _useLinklySignature.linklySignature;
|
|
97
|
+
useEffect(function () {
|
|
98
|
+
stepRef.current = custom === null || custom === void 0 ? void 0 : custom.step;
|
|
99
|
+
}, [custom === null || custom === void 0 ? void 0 : custom.step]);
|
|
100
|
+
useEffect(function () {
|
|
101
|
+
failRef.current = fail;
|
|
102
|
+
}, [fail]);
|
|
103
|
+
useEffect(function () {
|
|
104
|
+
if (statusRef.current === StatusEnum.Success || statusRef.current === StatusEnum.Fail) {
|
|
105
|
+
return;
|
|
106
|
+
}
|
|
107
|
+
if (initRef.current) {
|
|
108
|
+
return;
|
|
109
|
+
}
|
|
110
|
+
initRef.current = true;
|
|
111
|
+
|
|
112
|
+
// 存在支付流水号
|
|
113
|
+
if (numRef.current) {
|
|
114
|
+
resultQuery();
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
payOrRefund(resultQuery, handleLinklySuccess);
|
|
118
|
+
}, []);
|
|
119
|
+
useEffect(function () {
|
|
120
|
+
return function () {
|
|
121
|
+
var _controllerRef$curren;
|
|
122
|
+
(_controllerRef$curren = controllerRef.current) === null || _controllerRef$curren === void 0 || _controllerRef$curren.abort();
|
|
123
|
+
unloadRef.current = true;
|
|
124
|
+
if (clearRef.current) {
|
|
125
|
+
clearTimeout(clearRef.current);
|
|
126
|
+
}
|
|
127
|
+
};
|
|
128
|
+
}, []);
|
|
129
|
+
|
|
130
|
+
/**
|
|
131
|
+
* 取消支付
|
|
132
|
+
*/
|
|
133
|
+
var onCancel = function onCancel() {
|
|
134
|
+
stopResultQuery();
|
|
135
|
+
linklyCancel(resultQuery);
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* 拒绝签名
|
|
140
|
+
*/
|
|
141
|
+
var onDecline = function onDecline() {
|
|
142
|
+
stopResultQuery();
|
|
143
|
+
linklySignature(2, resultQuery);
|
|
144
|
+
};
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* 接受签名
|
|
148
|
+
*/
|
|
149
|
+
var onAccept = function onAccept() {
|
|
150
|
+
stopResultQuery();
|
|
151
|
+
linklySignature(3, resultQuery);
|
|
152
|
+
};
|
|
153
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
154
|
+
className: "pisell-lowcode__eft-pay-body"
|
|
155
|
+
}, ((custom === null || custom === void 0 ? void 0 : custom.list) || []).map(function (item) {
|
|
156
|
+
return /*#__PURE__*/React.createElement(Step, {
|
|
157
|
+
key: item.index,
|
|
158
|
+
pedding: item.pedding,
|
|
159
|
+
resolve: item.resolve,
|
|
160
|
+
reject: item.reject,
|
|
161
|
+
status: item.status
|
|
162
|
+
});
|
|
163
|
+
}), status === StatusEnum.Loading ? /*#__PURE__*/React.createElement("div", {
|
|
164
|
+
className: "pisell-lowcode__eft-pay-step-item pisell-lowcode__eft-pay-step-item-tip"
|
|
165
|
+
}, locales.getText('page.eftpos-pay.text.processing')) : null, status === StatusEnum.Question ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
166
|
+
className: "pisell-lowcode__eft-pay-step-item pisell-lowcode__eft-pay-step-item-tip"
|
|
167
|
+
}, locales.getText('page.eftpos-pay.text.receipt.again.title')), /*#__PURE__*/React.createElement("div", {
|
|
168
|
+
className: "pisell-lowcode__eft-pay-step-item pisell-lowcode__eft-pay-step-item-tip"
|
|
169
|
+
}, locales.getText('page.eftpos-pay.text.receipt.again.text'))) : null, status === StatusEnum.Success ? /*#__PURE__*/React.createElement("div", {
|
|
170
|
+
className: "pisell-lowcode__eft-pay-step-item pisell-lowcode__eft-pay-step-item-tip"
|
|
171
|
+
}, locales.getText('page.eftpos-pay.text.transaction.end')) : null), (custom === null || custom === void 0 ? void 0 : custom.actionStatus) === LinklyActionStatus.Cancel ? /*#__PURE__*/React.createElement("div", {
|
|
172
|
+
className: "pisell-lowcode__eft-pay-step-item-btns"
|
|
173
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
174
|
+
block: true,
|
|
175
|
+
className: "pisell-lowcode__eft-pay-step-item-btn",
|
|
176
|
+
onClick: onCancel,
|
|
177
|
+
disabled: !!(custom !== null && custom !== void 0 && custom.buttonDisabled)
|
|
178
|
+
}, locales.getText('page.eftpos-pay.text.cancel'))) : null, (custom === null || custom === void 0 ? void 0 : custom.actionStatus) === LinklyActionStatus.CancelWaiting || (custom === null || custom === void 0 ? void 0 : custom.actionStatus) === LinklyActionStatus.SignatureWaiting ? /*#__PURE__*/React.createElement("div", {
|
|
179
|
+
className: "pisell-lowcode__eft-pay-step-item-btns"
|
|
180
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
181
|
+
block: true,
|
|
182
|
+
className: "pisell-lowcode__eft-pay-step-item-btn",
|
|
183
|
+
disabled: true
|
|
184
|
+
}, locales.getText('page.eftpos-pay.text.leave'))) : null, (custom === null || custom === void 0 ? void 0 : custom.actionStatus) === LinklyActionStatus.Signature ? /*#__PURE__*/React.createElement("div", {
|
|
185
|
+
className: "pisell-lowcode__eft-pay-step-item-btns"
|
|
186
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
187
|
+
block: true,
|
|
188
|
+
className: "pisell-lowcode__eft-pay-step-item-btn",
|
|
189
|
+
onClick: onDecline
|
|
190
|
+
}, locales.getText('page.eftpos-pay.text.decline')), /*#__PURE__*/React.createElement(Button, {
|
|
191
|
+
block: true,
|
|
192
|
+
type: "primary",
|
|
193
|
+
className: "pisell-lowcode__eft-pay-step-item-btn",
|
|
194
|
+
onClick: onAccept
|
|
195
|
+
}, locales.getText('page.eftpos-pay.text.accept'))) : null);
|
|
196
|
+
};
|
|
197
|
+
export default Linkly;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* linkly支付接口
|
|
3
|
+
*/
|
|
4
|
+
export declare const linklyPayApi: (data: any) => Promise<any>;
|
|
5
|
+
/**
|
|
6
|
+
* 查询linkly支付结果
|
|
7
|
+
*/
|
|
8
|
+
export declare const linklyPayQueryApi: (param: any) => Promise<any>;
|
|
9
|
+
/**
|
|
10
|
+
* 取消linkly支付
|
|
11
|
+
*/
|
|
12
|
+
export declare const linklyPayCancelApi: (param: any) => Promise<any>;
|
|
13
|
+
/**
|
|
14
|
+
* linkly支付签名结果处理
|
|
15
|
+
*/
|
|
16
|
+
export declare const linklyPaySignatureApi: (param: any) => Promise<any>;
|
|
17
|
+
/**
|
|
18
|
+
* linkly退款接口
|
|
19
|
+
*/
|
|
20
|
+
export declare const linklyRefundApi: (data: any) => Promise<any>;
|
|
21
|
+
/**
|
|
22
|
+
* 查询linkly退款结果
|
|
23
|
+
*/
|
|
24
|
+
export declare const linklyRefundQueryApi: (param: any) => Promise<any>;
|
|
25
|
+
/**
|
|
26
|
+
* 取消linkly退款
|
|
27
|
+
*/
|
|
28
|
+
export declare const linklyRefundCancelApi: (param: any) => Promise<any>;
|
|
29
|
+
/**
|
|
30
|
+
* linkly退款签名结果处理
|
|
31
|
+
*/
|
|
32
|
+
export declare const linklyRefundSignatureApi: (param: any) => Promise<any>;
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { request } from "../../../utils";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* linkly支付接口
|
|
5
|
+
*/
|
|
6
|
+
export var linklyPayApi = function linklyPayApi(data) {
|
|
7
|
+
return request.getRequest().post('/shop/linkly/pay/apply', data, {
|
|
8
|
+
customMessage: true,
|
|
9
|
+
fullResult: true
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* 查询linkly支付结果
|
|
15
|
+
*/
|
|
16
|
+
export var linklyPayQueryApi = function linklyPayQueryApi(param) {
|
|
17
|
+
return request.getRequest().get('/shop/linkly/pay/query', param, {
|
|
18
|
+
customMessage: true,
|
|
19
|
+
fullResult: true
|
|
20
|
+
});
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* 取消linkly支付
|
|
25
|
+
*/
|
|
26
|
+
export var linklyPayCancelApi = function linklyPayCancelApi(param) {
|
|
27
|
+
return request.getRequest().post('/shop/linkly/pay/cancel', param, {
|
|
28
|
+
customMessage: true,
|
|
29
|
+
fullResult: true
|
|
30
|
+
});
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* linkly支付签名结果处理
|
|
35
|
+
*/
|
|
36
|
+
export var linklyPaySignatureApi = function linklyPaySignatureApi(param) {
|
|
37
|
+
return request.getRequest().post('/shop/linkly/pay/signature', param, {
|
|
38
|
+
customMessage: true,
|
|
39
|
+
fullResult: true
|
|
40
|
+
});
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* linkly退款接口
|
|
45
|
+
*/
|
|
46
|
+
export var linklyRefundApi = function linklyRefundApi(data) {
|
|
47
|
+
return request.getRequest().post('/shop/linkly/refund/apply', data, {
|
|
48
|
+
customMessage: true,
|
|
49
|
+
fullResult: true
|
|
50
|
+
});
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* 查询linkly退款结果
|
|
55
|
+
*/
|
|
56
|
+
export var linklyRefundQueryApi = function linklyRefundQueryApi(param) {
|
|
57
|
+
return request.getRequest().get('/shop/linkly/refund/query', param, {
|
|
58
|
+
customMessage: true,
|
|
59
|
+
fullResult: true
|
|
60
|
+
});
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* 取消linkly退款
|
|
65
|
+
*/
|
|
66
|
+
export var linklyRefundCancelApi = function linklyRefundCancelApi(param) {
|
|
67
|
+
return request.getRequest().post('/shop/linkly/refund/cancel', param, {
|
|
68
|
+
customMessage: true,
|
|
69
|
+
fullResult: true
|
|
70
|
+
});
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* linkly退款签名结果处理
|
|
75
|
+
*/
|
|
76
|
+
export var linklyRefundSignatureApi = function linklyRefundSignatureApi(param) {
|
|
77
|
+
return request.getRequest().post('/shop/linkly/refund/signature', param, {
|
|
78
|
+
customMessage: true,
|
|
79
|
+
fullResult: true
|
|
80
|
+
});
|
|
81
|
+
};
|
|
@@ -3,4 +3,5 @@ export { getAmonunt } from './helper';
|
|
|
3
3
|
export { default as Payo } from './payo';
|
|
4
4
|
export { default as Windcave } from './windcave/windcave';
|
|
5
5
|
export { default as Tyro } from './tyro';
|
|
6
|
+
export { default as Linkly } from './linkly';
|
|
6
7
|
export declare const getInitState: (type: string, params?: any) => State;
|
|
@@ -2,10 +2,12 @@ import { EftposEnum } from "./const";
|
|
|
2
2
|
import getPayoInitState from "./payo/const";
|
|
3
3
|
import getTyroInitState from "./tyro/const";
|
|
4
4
|
import getWindcaveInitState from "./windcave/const";
|
|
5
|
+
import getLinklyInitState from "./linkly/const";
|
|
5
6
|
export { getAmonunt } from "./helper";
|
|
6
7
|
export { default as Payo } from "./payo";
|
|
7
8
|
export { default as Windcave } from "./windcave/windcave";
|
|
8
9
|
export { default as Tyro } from "./tyro";
|
|
10
|
+
export { default as Linkly } from "./linkly";
|
|
9
11
|
export var getInitState = function getInitState(type, params) {
|
|
10
12
|
switch (type) {
|
|
11
13
|
case EftposEnum.Payo:
|
|
@@ -14,6 +16,8 @@ export var getInitState = function getInitState(type, params) {
|
|
|
14
16
|
return getWindcaveInitState(params);
|
|
15
17
|
case EftposEnum.Tyro:
|
|
16
18
|
return getTyroInitState(params);
|
|
19
|
+
case EftposEnum.Linkly:
|
|
20
|
+
return getLinklyInitState(params);
|
|
17
21
|
default:
|
|
18
22
|
throw new Error('未知的厂商类型');
|
|
19
23
|
}
|
|
@@ -6,7 +6,7 @@ import './index.less';
|
|
|
6
6
|
* @Author: hongbing.wang
|
|
7
7
|
* @Date: 2024-08-20 14:59
|
|
8
8
|
*/
|
|
9
|
-
declare const Pay: ({ api, onChange: onChangeStatus, className, terminal, net, isMobile, tyroUrl, tyroVersion, formatAmount, client }: PayProps & {
|
|
9
|
+
declare const Pay: ({ api, onChange: onChangeStatus, className, terminal, net, isMobile, tyroUrl, tyroVersion, formatAmount, client, }: PayProps & {
|
|
10
10
|
terminal: {
|
|
11
11
|
network: boolean;
|
|
12
12
|
};
|
|
@@ -10,7 +10,7 @@ import { getPayParams } from "./helper";
|
|
|
10
10
|
import Manual from "./component/manual";
|
|
11
11
|
import Signature from "./component/signature";
|
|
12
12
|
import { StatusEnum, PayRouteEnum, ClientEnum } from "./const";
|
|
13
|
-
import { Payo, Windcave, Tyro } from "./manufacturer";
|
|
13
|
+
import { Payo, Windcave, Tyro, Linkly } from "./manufacturer";
|
|
14
14
|
import { useContextData, useDispatch, updateStatus, backUpProduction, updateComponent, backUpFree, updateState } from "./store";
|
|
15
15
|
import "./index.less";
|
|
16
16
|
|
|
@@ -150,7 +150,7 @@ var Pay = function Pay(_ref) {
|
|
|
150
150
|
}
|
|
151
151
|
};
|
|
152
152
|
}, []);
|
|
153
|
-
|
|
153
|
+
console.log('data =>>>>>> ', data);
|
|
154
154
|
return /*#__PURE__*/React.createElement(React.Fragment, null, data.render ? /*#__PURE__*/React.createElement("div", {
|
|
155
155
|
className: "pisell-lowcode__eft-pay-box ".concat(className),
|
|
156
156
|
style: data.type === 'step' ? {} : {
|
|
@@ -178,6 +178,10 @@ var Pay = function Pay(_ref) {
|
|
|
178
178
|
onChange: onChange,
|
|
179
179
|
key: data.key,
|
|
180
180
|
formatAmount: formatAmount
|
|
181
|
+
}) : null, data.eftpos === 'linkly' ? /*#__PURE__*/React.createElement(Linkly, {
|
|
182
|
+
key: data.key,
|
|
183
|
+
api: api,
|
|
184
|
+
onChange: onChange
|
|
181
185
|
}) : null) : null, data.type === PayRouteEnum.Unset && Comm ? /*#__PURE__*/React.createElement(Comm, {
|
|
182
186
|
onChange: onChange,
|
|
183
187
|
api: api,
|
|
@@ -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: "loading" | "success" | "warn" | "fail" | "question";
|
|
178
178
|
};
|
|
179
179
|
};
|
|
180
180
|
/**
|
|
@@ -295,20 +295,20 @@ export declare const backUpFree: (payload: Partial<State>) => {
|
|
|
295
295
|
name?: string | undefined;
|
|
296
296
|
symbol?: string | undefined;
|
|
297
297
|
amount?: string | number | undefined;
|
|
298
|
-
mode?: "
|
|
298
|
+
mode?: "pay" | "fullPay" | "refund" | "query" | undefined;
|
|
299
299
|
order_id?: string | number | undefined;
|
|
300
|
-
eftpos?: "tyro" | "windcave" | "stripe" | "
|
|
301
|
-
action?: "amount" | "
|
|
300
|
+
eftpos?: "payo" | "tyro" | "windcave" | "stripe" | "linkly" | undefined;
|
|
301
|
+
action?: "amount" | "deviceList" | "pay" | undefined;
|
|
302
302
|
key?: number | undefined;
|
|
303
303
|
step?: number | undefined;
|
|
304
304
|
title?: string | undefined;
|
|
305
305
|
subTitle?: string | undefined;
|
|
306
|
-
type?: "
|
|
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?: "loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
|
|
312
312
|
warn?: string | undefined;
|
|
313
313
|
steps?: {
|
|
314
314
|
/** 用于重置当前步骤 */
|
|
@@ -16,7 +16,7 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
|
16
16
|
import React, { useMemo, useState } from 'react';
|
|
17
17
|
import { locales } from '@pisell/utils';
|
|
18
18
|
import { Button, PisellToast } from '@pisell/materials';
|
|
19
|
-
import { useCart, useHolder, useStep, useCheckout, useSales, useCustomer } from "../../../../../Sales";
|
|
19
|
+
import { useCart, useHolder, useStep, useCheckout, useSales, useCustomer, useSummary } from "../../../../../Sales";
|
|
20
20
|
import { formatValues, getFormParams } from "../../../../../Sales/Checkout/utils";
|
|
21
21
|
import OrderProductModal from "../../OrderProductModal/index";
|
|
22
22
|
import EmptyHolderModal from "../../EmptyHolderModal";
|
|
@@ -24,6 +24,7 @@ import { getProductPrice } from "../../../../../Sales/Event/serve";
|
|
|
24
24
|
import { useRequest } from 'ahooks';
|
|
25
25
|
import useEngineContext from "../../../../../../hooks/useEngineContext";
|
|
26
26
|
import "./index.less";
|
|
27
|
+
import { Toast } from "../../../../../appointmentBooking/utils";
|
|
27
28
|
var ContinueButton = function ContinueButton() {
|
|
28
29
|
var _context$appHelper, _cartData$cartItems;
|
|
29
30
|
var _useSales = useSales(),
|
|
@@ -43,10 +44,14 @@ var ContinueButton = function ContinueButton() {
|
|
|
43
44
|
onCheckout = _useCheckout.onCheckout,
|
|
44
45
|
createBooking = _useCheckout.createBooking,
|
|
45
46
|
onCheckBeforeBooking = _useCheckout.onCheckBeforeBooking,
|
|
46
|
-
checkBeforeBooking = _useCheckout.checkBeforeBooking
|
|
47
|
+
checkBeforeBooking = _useCheckout.checkBeforeBooking,
|
|
48
|
+
freePay = _useCheckout.freePay;
|
|
47
49
|
var _useCustomer = useCustomer(),
|
|
48
50
|
openLoginModal = _useCustomer.openLoginModal,
|
|
49
51
|
isLogin = _useCustomer.isLogin;
|
|
52
|
+
var _useSummary = useSummary(),
|
|
53
|
+
deposit = _useSummary.deposit,
|
|
54
|
+
isAgreeDepositPolicy = _useSummary.isAgreeDepositPolicy;
|
|
50
55
|
|
|
51
56
|
// 下单之前是否检测失败
|
|
52
57
|
var _useState = useState(false),
|
|
@@ -384,41 +389,48 @@ var ContinueButton = function ContinueButton() {
|
|
|
384
389
|
*/
|
|
385
390
|
var handleContinue = /*#__PURE__*/function () {
|
|
386
391
|
var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6() {
|
|
387
|
-
var value, checkRes, emptyHolders;
|
|
392
|
+
var _deposit$protocols, value, checkRes, emptyHolders;
|
|
388
393
|
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
389
394
|
while (1) switch (_context6.prev = _context6.next) {
|
|
390
395
|
case 0:
|
|
391
396
|
if (!isLastStep) {
|
|
392
|
-
_context6.next =
|
|
397
|
+
_context6.next = 17;
|
|
398
|
+
break;
|
|
399
|
+
}
|
|
400
|
+
value = formatValues(data); // 如果未同意定金政策,则提示
|
|
401
|
+
if (!(deposit !== null && deposit !== void 0 && deposit.hasDeposit && (deposit === null || deposit === void 0 || (_deposit$protocols = deposit.protocols) === null || _deposit$protocols === void 0 ? void 0 : _deposit$protocols.length) > 0 && !isAgreeDepositPolicy)) {
|
|
402
|
+
_context6.next = 5;
|
|
393
403
|
break;
|
|
394
404
|
}
|
|
395
|
-
|
|
396
|
-
_context6.
|
|
405
|
+
Toast(locales.getText('pisell2.appointment.deposit.agree.policy'));
|
|
406
|
+
return _context6.abrupt("return");
|
|
407
|
+
case 5:
|
|
408
|
+
_context6.next = 7;
|
|
397
409
|
return onCheckBeforeBooking(value);
|
|
398
|
-
case
|
|
410
|
+
case 7:
|
|
399
411
|
checkRes = _context6.sent;
|
|
400
412
|
if (!((checkRes === null || checkRes === void 0 ? void 0 : checkRes.result) === false)) {
|
|
401
|
-
_context6.next =
|
|
413
|
+
_context6.next = 12;
|
|
402
414
|
break;
|
|
403
415
|
}
|
|
404
416
|
setCheckedNumber(checkRes === null || checkRes === void 0 ? void 0 : checkRes.num);
|
|
405
417
|
setOpenCheckout(true);
|
|
406
418
|
return _context6.abrupt("return");
|
|
407
|
-
case
|
|
419
|
+
case 12:
|
|
408
420
|
// 验证holder是否为空
|
|
409
421
|
emptyHolders = getWithoutCartItemsHolderNames();
|
|
410
422
|
if (!((emptyHolders === null || emptyHolders === void 0 ? void 0 : emptyHolders.length) > 0)) {
|
|
411
|
-
_context6.next =
|
|
423
|
+
_context6.next = 15;
|
|
412
424
|
break;
|
|
413
425
|
}
|
|
414
426
|
return _context6.abrupt("return", setOpenEmptyHolder(true));
|
|
415
|
-
case
|
|
427
|
+
case 15:
|
|
416
428
|
// 关闭购物车弹窗
|
|
417
429
|
onCloseCart();
|
|
418
430
|
return _context6.abrupt("return", handleCheckout());
|
|
419
|
-
case
|
|
431
|
+
case 17:
|
|
420
432
|
if (isLogin()) {
|
|
421
|
-
_context6.next =
|
|
433
|
+
_context6.next = 20;
|
|
422
434
|
break;
|
|
423
435
|
}
|
|
424
436
|
onCloseCart();
|
|
@@ -448,9 +460,9 @@ var ContinueButton = function ContinueButton() {
|
|
|
448
460
|
return callback;
|
|
449
461
|
}()
|
|
450
462
|
}));
|
|
451
|
-
case
|
|
463
|
+
case 20:
|
|
452
464
|
handleHolder();
|
|
453
|
-
case
|
|
465
|
+
case 21:
|
|
454
466
|
case "end":
|
|
455
467
|
return _context6.stop();
|
|
456
468
|
}
|
|
@@ -487,8 +499,8 @@ var ContinueButton = function ContinueButton() {
|
|
|
487
499
|
*/
|
|
488
500
|
var confirmLoading = useMemo(function () {
|
|
489
501
|
if (!isLastStep) return false;
|
|
490
|
-
return (createBooking === null || createBooking === void 0 ? void 0 : createBooking.loading) || (checkBeforeBooking === null || checkBeforeBooking === void 0 ? void 0 : checkBeforeBooking.loading);
|
|
491
|
-
}, [isLastStep, createBooking === null || createBooking === void 0 ? void 0 : createBooking.loading, checkBeforeBooking === null || checkBeforeBooking === void 0 ? void 0 : checkBeforeBooking.loading]);
|
|
502
|
+
return (createBooking === null || createBooking === void 0 ? void 0 : createBooking.loading) || (checkBeforeBooking === null || checkBeforeBooking === void 0 ? void 0 : checkBeforeBooking.loading) || (freePay === null || freePay === void 0 ? void 0 : freePay.loading);
|
|
503
|
+
}, [isLastStep, createBooking === null || createBooking === void 0 ? void 0 : createBooking.loading, checkBeforeBooking === null || checkBeforeBooking === void 0 ? void 0 : checkBeforeBooking.loading, freePay === null || freePay === void 0 ? void 0 : freePay.loading]);
|
|
492
504
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Button, {
|
|
493
505
|
disabled: !(cartData !== null && cartData !== void 0 && (_cartData$cartItems = cartData.cartItems) !== null && _cartData$cartItems !== void 0 && _cartData$cartItems.length),
|
|
494
506
|
size: "large",
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { useSummary } from "../../../../../Sales";
|
|
3
|
+
import { DepositContent } from "../../../../../appointmentBooking/components/Deposit";
|
|
4
|
+
var Deposit = function Deposit() {
|
|
5
|
+
var _useSummary = useSummary(),
|
|
6
|
+
deposit = _useSummary.deposit,
|
|
7
|
+
isAgreeDepositPolicy = _useSummary.isAgreeDepositPolicy,
|
|
8
|
+
setIsAgreeDepositPolicy = _useSummary.setIsAgreeDepositPolicy,
|
|
9
|
+
getDepositProtocol = _useSummary.getDepositProtocol;
|
|
10
|
+
return /*#__PURE__*/React.createElement(DepositContent, {
|
|
11
|
+
isAgreeDepositPolicy: !!isAgreeDepositPolicy,
|
|
12
|
+
setIsAgreeDepositPolicy: setIsAgreeDepositPolicy,
|
|
13
|
+
deposit: deposit,
|
|
14
|
+
depositProtocolRequest: getDepositProtocol
|
|
15
|
+
});
|
|
16
|
+
};
|
|
17
|
+
export default Deposit;
|
|
@@ -5,21 +5,25 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { locales } from '@pisell/utils';
|
|
7
7
|
import { PisellText } from '@pisell/materials';
|
|
8
|
-
import { useSummary } from "../../../../../Sales";
|
|
8
|
+
import { useCart, useSummary } from "../../../../../Sales";
|
|
9
9
|
import useEngineContext from "../../../../../../hooks/useEngineContext";
|
|
10
10
|
import "./index.less";
|
|
11
11
|
import classNames from 'classnames';
|
|
12
12
|
var Total = function Total(_ref) {
|
|
13
|
-
var _context$appHelper, _context$appHelper$ge, _context$appHelper2, _context$appHelper2$g;
|
|
13
|
+
var _context$appHelper, _context$appHelper$ge, _cartData$cartItems, _cartData$cartItems2, _context$appHelper2, _context$appHelper2$g;
|
|
14
14
|
var className = _ref.className,
|
|
15
15
|
isFooter = _ref.isFooter;
|
|
16
|
+
var _useCart = useCart(),
|
|
17
|
+
cartData = _useCart.cartData;
|
|
16
18
|
var _useSummary = useSummary(),
|
|
17
19
|
taxTitle = _useSummary.taxTitle,
|
|
18
20
|
totalTaxFee = _useSummary.totalTaxFee,
|
|
19
21
|
isPriceIncludeTax = _useSummary.isPriceIncludeTax,
|
|
20
|
-
total = _useSummary.total
|
|
22
|
+
total = _useSummary.total,
|
|
23
|
+
deposit = _useSummary.deposit;
|
|
21
24
|
var context = useEngineContext();
|
|
22
|
-
console.log(taxTitle, isPriceIncludeTax, totalTaxFee, total, context === null || context === void 0 || (_context$appHelper = context.appHelper) === null || _context$appHelper === void 0 || (_context$appHelper = _context$appHelper.utils) === null || _context$appHelper === void 0 || (_context$appHelper$ge = _context$appHelper.getSymbolic) === null || _context$appHelper$ge === void 0 ? void 0 : _context$appHelper$ge.call(_context$appHelper), 'wh97978');
|
|
25
|
+
console.log(taxTitle, isPriceIncludeTax, totalTaxFee, total, context === null || context === void 0 || (_context$appHelper = context.appHelper) === null || _context$appHelper === void 0 || (_context$appHelper = _context$appHelper.utils) === null || _context$appHelper === void 0 || (_context$appHelper$ge = _context$appHelper.getSymbolic) === null || _context$appHelper$ge === void 0 ? void 0 : _context$appHelper$ge.call(_context$appHelper), deposit, 'wh97978');
|
|
26
|
+
var showDeposit = (cartData === null || cartData === void 0 || (_cartData$cartItems = cartData.cartItems) === null || _cartData$cartItems === void 0 ? void 0 : _cartData$cartItems.length) > 0 && (deposit === null || deposit === void 0 ? void 0 : deposit.hasDeposit);
|
|
23
27
|
return /*#__PURE__*/React.createElement("div", {
|
|
24
28
|
className: "event-total-wrap ".concat(className)
|
|
25
29
|
}, !isPriceIncludeTax && Number(totalTaxFee) > 0 ? /*#__PURE__*/React.createElement("div", {
|
|
@@ -31,8 +35,8 @@ var Total = function Total(_ref) {
|
|
|
31
35
|
className: classNames('event-total', _defineProperty({}, ['total-gst-wrap'], !isPriceIncludeTax && Number(totalTaxFee) > 0))
|
|
32
36
|
}, /*#__PURE__*/React.createElement("div", {
|
|
33
37
|
className: "left"
|
|
34
|
-
}, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("span", null, locales.getText('pisell2.event.total'), isFooter ? ': ' : ''), isFooter ? /*#__PURE__*/React.createElement(PisellText.Amount, {
|
|
35
|
-
value: total,
|
|
38
|
+
}, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("span", null, isFooter && showDeposit ? locales.getText('pisell2.appointment.deposit') : locales.getText('pisell2.event.total'), isFooter ? ': ' : ''), isFooter ? /*#__PURE__*/React.createElement(PisellText.Amount, {
|
|
39
|
+
value: (cartData === null || cartData === void 0 || (_cartData$cartItems2 = cartData.cartItems) === null || _cartData$cartItems2 === void 0 ? void 0 : _cartData$cartItems2.length) > 0 && deposit !== null && deposit !== void 0 && deposit.hasDeposit ? deposit === null || deposit === void 0 ? void 0 : deposit.total : total,
|
|
36
40
|
showCurrencySymbol: true,
|
|
37
41
|
className: "event-amount"
|
|
38
42
|
}) : null), isPriceIncludeTax && Number(totalTaxFee) > 0 ? /*#__PURE__*/React.createElement("span", {
|