@pisell/private-materials 3.2.22 → 3.2.25
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 +7 -7
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +8 -8
- package/es/components/appointmentBooking/assets/guests.svg +1 -0
- package/es/components/appointmentBooking/components/Cart/ContinueButton/index.js +134 -105
- package/es/components/appointmentBooking/components/Cart/Item/Total.js +2 -1
- package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -1
- package/es/components/appointmentBooking/components/Cart/Item/index.js +43 -21
- package/es/components/appointmentBooking/components/Cart/Item/index.less +14 -9
- package/es/components/appointmentBooking/components/Cart/index.js +3 -2
- package/es/components/appointmentBooking/components/Cart/index.less +1 -1
- package/es/components/appointmentBooking/components/Content/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Content/index.js +25 -13
- package/es/components/appointmentBooking/components/Content/index.less +15 -0
- package/es/components/appointmentBooking/components/Date/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Date/index.js +50 -33
- package/es/components/appointmentBooking/components/Date/index.less +11 -0
- package/es/components/appointmentBooking/components/Footer/index.js +7 -2
- package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +3 -0
- package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.js +50 -0
- package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.less +28 -0
- package/es/components/appointmentBooking/components/Guest/index.js +25 -18
- package/es/components/appointmentBooking/components/Guest/index.less +3 -3
- package/es/components/appointmentBooking/components/Header/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Header/index.js +50 -8
- package/es/components/appointmentBooking/components/Resource/index.d.ts +1 -1
- package/es/components/appointmentBooking/components/Resource/index.js +19 -29
- package/es/components/appointmentBooking/components/Resource/index.less +5 -1
- package/es/components/appointmentBooking/components/Services/index.js +7 -9
- package/es/components/appointmentBooking/components/TimeSlicing/index.d.ts +1 -1
- package/es/components/appointmentBooking/components/TimeSlicing/index.js +55 -35
- package/es/components/appointmentBooking/components/TimeSlicing/index.less +5 -0
- package/es/components/appointmentBooking/components/Voucher/index.js +38 -28
- package/es/components/appointmentBooking/context.d.ts +2 -0
- package/es/components/appointmentBooking/context.js +7 -1
- package/es/components/appointmentBooking/hooks.d.ts +49 -10
- package/es/components/appointmentBooking/hooks.js +191 -134
- package/es/components/appointmentBooking/index.d.ts +0 -1
- package/es/components/appointmentBooking/index.js +12 -8
- package/es/components/appointmentBooking/locales.d.ts +36 -0
- package/es/components/appointmentBooking/locales.js +36 -0
- package/es/components/appointmentBooking/utils.d.ts +28 -0
- package/es/components/appointmentBooking/utils.js +86 -2
- package/es/components/booking/components/TabProduct/index.d.ts +0 -1
- package/es/components/booking/components/TabProduct/productItem/index.d.ts +0 -1
- package/es/components/booking/components/TabProduct/selectProductItem/index.d.ts +0 -1
- package/es/components/booking/components/collapsibleList/utils.d.ts +0 -1
- package/es/components/booking/components/emptyBooking/index.d.ts +0 -1
- package/es/components/booking/components/footer/FooterMenus/index.d.ts +0 -1
- package/es/components/booking/components/footer/utils.js +15 -15
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +0 -1
- package/es/components/booking/components/voucher/index.d.ts +1 -1
- package/es/components/booking/components/voucher/index.js +39 -37
- package/es/components/booking/deposit/index.d.ts +0 -1
- package/es/components/booking/forms/single/index.d.ts +0 -1
- package/es/components/booking/forms/table/index.d.ts +0 -1
- package/es/components/booking/hooks/useIsBooking4Shop.d.ts +1 -0
- package/es/components/booking/hooks/useIsBooking4Shop.js +10 -0
- package/es/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useClientFn.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +0 -1
- package/es/components/booking/info/date/index.d.ts +0 -1
- package/es/components/booking/info/header/index.d.ts +0 -1
- package/es/components/booking/info/index.d.ts +0 -1
- package/es/components/booking/info/notes/index.d.ts +0 -1
- package/es/components/booking/info/service/actions/index.d.ts +0 -1
- package/es/components/booking/info/service/addService/index.d.ts +0 -1
- package/es/components/booking/info/service/addTimeModal/index.d.ts +0 -1
- package/es/components/booking/info/service/like/index.d.ts +0 -1
- package/es/components/booking/info/service/serviceList/index.d.ts +0 -1
- package/es/components/booking/info/service2/Lists.d.ts +0 -1
- package/es/components/booking/info/service2/utils.d.ts +1 -1
- package/es/components/booking/info2/service/actions/index.d.ts +0 -1
- package/es/components/booking/info2/service/addService/index.d.ts +0 -1
- package/es/components/booking/info2/service/addTimeModal/index.d.ts +0 -1
- package/es/components/booking/info2/service/serviceList/index.d.ts +0 -1
- package/es/components/booking/materiels/contacts/index.d.ts +0 -1
- package/es/components/booking/materiels/duration/index.d.ts +0 -1
- package/es/components/booking/materiels/holder/index.d.ts +0 -1
- package/es/components/booking/materiels/startTime/index.d.ts +0 -1
- package/es/components/booking/notes/NoteBlock/NoteItem/index.d.ts +0 -1
- package/es/components/booking/notes/NoteBlock/index.d.ts +0 -1
- package/es/components/booking/notes/addNote/index.d.ts +0 -1
- package/es/components/eftpos/deviceList/index.d.ts +0 -1
- package/es/components/eftpos/form/index.d.ts +0 -1
- package/es/components/eftpos/group/index.d.ts +0 -1
- package/es/components/eftpos/hooks.d.ts +0 -1
- package/es/components/eftpos/icon/apiKey.d.ts +0 -1
- package/es/components/eftpos/icon/device.d.ts +0 -1
- package/es/components/eftpos/index.d.ts +0 -1
- package/es/components/eftpos/pos.d.ts +0 -1
- package/es/components/eftpos/receipt/index.d.ts +0 -1
- package/es/components/eftpos/surcharge/index.d.ts +0 -1
- package/es/components/eftposPay/amount.d.ts +0 -1
- package/es/components/eftposPay/app.d.ts +0 -1
- package/es/components/eftposPay/component/alert/warn.d.ts +0 -1
- package/es/components/eftposPay/component/fail/failCustom.d.ts +0 -1
- package/es/components/eftposPay/component/fail/index.d.ts +0 -1
- package/es/components/eftposPay/component/fail/network.d.ts +0 -1
- package/es/components/eftposPay/component/fail/unknow.d.ts +0 -1
- package/es/components/eftposPay/component/header/titlebar.d.ts +0 -1
- package/es/components/eftposPay/component/manual/index.d.ts +0 -1
- package/es/components/eftposPay/component/signature/index.d.ts +0 -1
- package/es/components/eftposPay/component/step/index.d.ts +0 -1
- package/es/components/eftposPay/component/step/step.d.ts +0 -1
- package/es/components/eftposPay/device.d.ts +0 -1
- package/es/components/eftposPay/index.d.ts +0 -1
- package/es/components/eftposPay/pay.d.ts +0 -1
- package/es/components/eftposPay/payo/config.d.ts +0 -1
- package/es/components/eftposPay/store/index.d.ts +1 -1
- package/es/components/eftposPay/tip.d.ts +0 -1
- package/es/components/eftposPay/tyro/hooks.d.ts +0 -1
- package/es/components/eftposPay/windcave/receiptAction.d.ts +0 -1
- package/es/components/eftposPay/windcave/windcave.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Content/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Header/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -1
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +0 -1
- package/es/components/eventBooking/index.d.ts +0 -1
- package/es/components/login/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/BirthdayField/index.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/GenderField/index.d.ts +0 -1
- package/es/components/productExtension/fields/Actor/index.d.ts +0 -1
- package/es/components/productExtension/fields/Forms/index.d.ts +0 -1
- package/es/components/productExtension/fields/SelectProducts/ProductItem/index.d.ts +0 -1
- package/es/components/productExtension/fields/SelectProducts/ProductItemPreview/index.d.ts +0 -1
- package/es/components/ruleSetting/ruleBorder/index.d.ts +0 -1
- package/es/components/schedules/calendar/calendarItem.d.ts +0 -1
- package/es/components/schedules/calendar/index.d.ts +0 -1
- package/es/components/schedules/components/CurrentDay/index.d.ts +0 -1
- package/es/components/schedules/components/ScheduleDetailList/index.d.ts +0 -1
- package/es/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +0 -1
- package/es/components/schedules/components/ScheduleList/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/index.d.ts +0 -1
- package/es/components/schedules/products/index.d.ts +0 -1
- package/es/components/schedules/products/list/ProductItem/index.d.ts +0 -1
- package/es/components/schedules/products/list/index.d.ts +0 -1
- package/es/components/schedules/resources/index.d.ts +0 -1
- package/es/components/schedules/resources/list/index.d.ts +0 -1
- package/es/components/schedules/resources/relationProduct/index.d.ts +0 -1
- package/es/components/schedules/schedules/AllSchedules/index.d.ts +0 -1
- package/es/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +0 -1
- package/es/components/schedules/schedules/index.d.ts +0 -1
- package/es/components/schedules/utils.d.ts +1 -1
- package/es/components/shoppingCart/components/Cart/Product.js +3 -0
- package/es/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/es/components/shoppingCart/hooks/useClearCart.js +4 -3
- package/es/components/shoppingCart/index.d.ts +0 -1
- package/es/components/shoppingCart/type.d.ts +1 -0
- package/es/components/taxSelect/index.d.ts +0 -1
- package/es/utils/index.d.ts +1 -1
- package/lib/components/appointmentBooking/assets/guests.svg +1 -0
- package/lib/components/appointmentBooking/components/Cart/ContinueButton/index.js +68 -32
- package/lib/components/appointmentBooking/components/Cart/Item/Total.js +2 -1
- package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -1
- package/lib/components/appointmentBooking/components/Cart/Item/index.js +36 -13
- package/lib/components/appointmentBooking/components/Cart/Item/index.less +14 -9
- package/lib/components/appointmentBooking/components/Cart/index.js +3 -2
- package/lib/components/appointmentBooking/components/Cart/index.less +1 -1
- package/lib/components/appointmentBooking/components/Content/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Content/index.js +11 -7
- package/lib/components/appointmentBooking/components/Content/index.less +15 -0
- package/lib/components/appointmentBooking/components/Date/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Date/index.js +80 -68
- package/lib/components/appointmentBooking/components/Date/index.less +11 -0
- package/lib/components/appointmentBooking/components/Footer/index.js +5 -1
- package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +3 -0
- package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.js +74 -0
- package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.less +28 -0
- package/lib/components/appointmentBooking/components/Guest/index.js +24 -6
- package/lib/components/appointmentBooking/components/Guest/index.less +3 -3
- package/lib/components/appointmentBooking/components/Header/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Header/index.js +31 -4
- package/lib/components/appointmentBooking/components/Resource/index.d.ts +1 -1
- package/lib/components/appointmentBooking/components/Resource/index.js +16 -21
- package/lib/components/appointmentBooking/components/Resource/index.less +5 -1
- package/lib/components/appointmentBooking/components/Services/index.js +9 -2
- package/lib/components/appointmentBooking/components/TimeSlicing/index.d.ts +1 -1
- package/lib/components/appointmentBooking/components/TimeSlicing/index.js +33 -23
- package/lib/components/appointmentBooking/components/TimeSlicing/index.less +5 -0
- package/lib/components/appointmentBooking/components/Voucher/index.js +30 -24
- package/lib/components/appointmentBooking/context.d.ts +2 -0
- package/lib/components/appointmentBooking/context.js +4 -1
- package/lib/components/appointmentBooking/hooks.d.ts +49 -10
- package/lib/components/appointmentBooking/hooks.js +49 -50
- package/lib/components/appointmentBooking/index.d.ts +0 -1
- package/lib/components/appointmentBooking/index.js +11 -7
- package/lib/components/appointmentBooking/locales.d.ts +36 -0
- package/lib/components/appointmentBooking/locales.js +36 -0
- package/lib/components/appointmentBooking/utils.d.ts +28 -0
- package/lib/components/appointmentBooking/utils.js +48 -2
- package/lib/components/booking/components/TabProduct/index.d.ts +0 -1
- package/lib/components/booking/components/TabProduct/productItem/index.d.ts +0 -1
- package/lib/components/booking/components/TabProduct/selectProductItem/index.d.ts +0 -1
- package/lib/components/booking/components/collapsibleList/utils.d.ts +0 -1
- package/lib/components/booking/components/emptyBooking/index.d.ts +0 -1
- package/lib/components/booking/components/footer/FooterMenus/index.d.ts +0 -1
- package/lib/components/booking/components/footer/utils.js +1 -15
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +0 -1
- package/lib/components/booking/components/voucher/index.d.ts +1 -1
- package/lib/components/booking/components/voucher/index.js +31 -25
- package/lib/components/booking/deposit/index.d.ts +0 -1
- package/lib/components/booking/forms/single/index.d.ts +0 -1
- package/lib/components/booking/forms/table/index.d.ts +0 -1
- package/lib/components/booking/hooks/useIsBooking4Shop.d.ts +1 -0
- package/lib/components/booking/hooks/useIsBooking4Shop.js +51 -0
- package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useClientFn.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +0 -1
- package/lib/components/booking/info/date/index.d.ts +0 -1
- package/lib/components/booking/info/header/index.d.ts +0 -1
- package/lib/components/booking/info/index.d.ts +0 -1
- package/lib/components/booking/info/notes/index.d.ts +0 -1
- package/lib/components/booking/info/service/actions/index.d.ts +0 -1
- package/lib/components/booking/info/service/addService/index.d.ts +0 -1
- package/lib/components/booking/info/service/addTimeModal/index.d.ts +0 -1
- package/lib/components/booking/info/service/like/index.d.ts +0 -1
- package/lib/components/booking/info/service/serviceList/index.d.ts +0 -1
- package/lib/components/booking/info/service2/Lists.d.ts +0 -1
- package/lib/components/booking/info/service2/utils.d.ts +1 -1
- package/lib/components/booking/info2/service/actions/index.d.ts +0 -1
- package/lib/components/booking/info2/service/addService/index.d.ts +0 -1
- package/lib/components/booking/info2/service/addTimeModal/index.d.ts +0 -1
- package/lib/components/booking/info2/service/serviceList/index.d.ts +0 -1
- package/lib/components/booking/materiels/contacts/index.d.ts +0 -1
- package/lib/components/booking/materiels/duration/index.d.ts +0 -1
- package/lib/components/booking/materiels/holder/index.d.ts +0 -1
- package/lib/components/booking/materiels/startTime/index.d.ts +0 -1
- package/lib/components/booking/notes/NoteBlock/NoteItem/index.d.ts +0 -1
- package/lib/components/booking/notes/NoteBlock/index.d.ts +0 -1
- package/lib/components/booking/notes/addNote/index.d.ts +0 -1
- package/lib/components/eftpos/deviceList/index.d.ts +0 -1
- package/lib/components/eftpos/form/index.d.ts +0 -1
- package/lib/components/eftpos/group/index.d.ts +0 -1
- package/lib/components/eftpos/hooks.d.ts +0 -1
- package/lib/components/eftpos/icon/apiKey.d.ts +0 -1
- package/lib/components/eftpos/icon/device.d.ts +0 -1
- package/lib/components/eftpos/index.d.ts +0 -1
- package/lib/components/eftpos/pos.d.ts +0 -1
- package/lib/components/eftpos/receipt/index.d.ts +0 -1
- package/lib/components/eftpos/surcharge/index.d.ts +0 -1
- package/lib/components/eftposPay/amount.d.ts +0 -1
- package/lib/components/eftposPay/app.d.ts +0 -1
- package/lib/components/eftposPay/component/alert/warn.d.ts +0 -1
- package/lib/components/eftposPay/component/fail/failCustom.d.ts +0 -1
- package/lib/components/eftposPay/component/fail/index.d.ts +0 -1
- package/lib/components/eftposPay/component/fail/network.d.ts +0 -1
- package/lib/components/eftposPay/component/fail/unknow.d.ts +0 -1
- package/lib/components/eftposPay/component/header/titlebar.d.ts +0 -1
- package/lib/components/eftposPay/component/manual/index.d.ts +0 -1
- package/lib/components/eftposPay/component/signature/index.d.ts +0 -1
- package/lib/components/eftposPay/component/step/index.d.ts +0 -1
- package/lib/components/eftposPay/component/step/step.d.ts +0 -1
- package/lib/components/eftposPay/device.d.ts +0 -1
- package/lib/components/eftposPay/index.d.ts +0 -1
- package/lib/components/eftposPay/pay.d.ts +0 -1
- package/lib/components/eftposPay/payo/config.d.ts +0 -1
- package/lib/components/eftposPay/store/index.d.ts +1 -1
- package/lib/components/eftposPay/tip.d.ts +0 -1
- package/lib/components/eftposPay/tyro/hooks.d.ts +0 -1
- package/lib/components/eftposPay/windcave/receiptAction.d.ts +0 -1
- package/lib/components/eftposPay/windcave/windcave.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Content/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Header/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -1
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +0 -1
- package/lib/components/eventBooking/index.d.ts +0 -1
- package/lib/components/login/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/BirthdayField/index.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/GenderField/index.d.ts +0 -1
- package/lib/components/productExtension/fields/Actor/index.d.ts +0 -1
- package/lib/components/productExtension/fields/Forms/index.d.ts +0 -1
- package/lib/components/productExtension/fields/SelectProducts/ProductItem/index.d.ts +0 -1
- package/lib/components/productExtension/fields/SelectProducts/ProductItemPreview/index.d.ts +0 -1
- package/lib/components/ruleSetting/ruleBorder/index.d.ts +0 -1
- package/lib/components/schedules/calendar/calendarItem.d.ts +0 -1
- package/lib/components/schedules/calendar/index.d.ts +0 -1
- package/lib/components/schedules/components/CurrentDay/index.d.ts +0 -1
- package/lib/components/schedules/components/ScheduleDetailList/index.d.ts +0 -1
- package/lib/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +0 -1
- package/lib/components/schedules/components/ScheduleList/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/index.d.ts +0 -1
- package/lib/components/schedules/products/index.d.ts +0 -1
- package/lib/components/schedules/products/list/ProductItem/index.d.ts +0 -1
- package/lib/components/schedules/products/list/index.d.ts +0 -1
- package/lib/components/schedules/resources/index.d.ts +0 -1
- package/lib/components/schedules/resources/list/index.d.ts +0 -1
- package/lib/components/schedules/resources/relationProduct/index.d.ts +0 -1
- package/lib/components/schedules/schedules/AllSchedules/index.d.ts +0 -1
- package/lib/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +0 -1
- package/lib/components/schedules/schedules/index.d.ts +0 -1
- package/lib/components/schedules/utils.d.ts +1 -1
- package/lib/components/shoppingCart/components/Cart/Product.js +1 -0
- package/lib/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/lib/components/shoppingCart/hooks/useClearCart.js +3 -2
- package/lib/components/shoppingCart/index.d.ts +0 -1
- package/lib/components/shoppingCart/type.d.ts +1 -0
- package/lib/components/taxSelect/index.d.ts +0 -1
- package/lib/utils/index.d.ts +1 -1
- package/package.json +4 -4
|
@@ -1,25 +1,64 @@
|
|
|
1
1
|
export declare const useAppointmentBooking: () => any;
|
|
2
2
|
export declare const useShopDiscount: () => any;
|
|
3
|
+
/**
|
|
4
|
+
* @title: 监听步骤发生变化
|
|
5
|
+
* @description:
|
|
6
|
+
* @return {*}
|
|
7
|
+
* @Author: WangHan
|
|
8
|
+
* @Date: 2025-04-15 11:11
|
|
9
|
+
*/
|
|
3
10
|
export declare const useAppointmentBookingStep: () => void;
|
|
11
|
+
/**
|
|
12
|
+
* @title: 获取商品数据
|
|
13
|
+
* @description:
|
|
14
|
+
* @return {*}
|
|
15
|
+
* @Author: WangHan
|
|
16
|
+
* @Date: 2025-04-15 11:12
|
|
17
|
+
*/
|
|
4
18
|
export declare const useAppointmentBookingProduct: () => void;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
19
|
+
/**
|
|
20
|
+
* @title: 更新购物车数据
|
|
21
|
+
* @description:
|
|
22
|
+
* @return {*}
|
|
23
|
+
* @Author: WangHan
|
|
24
|
+
* @Date: 2025-04-15 11:12
|
|
25
|
+
*/
|
|
26
|
+
export declare const useAppointmentBookingCart: () => void;
|
|
27
|
+
/**
|
|
28
|
+
* @title: 获取登录状态
|
|
29
|
+
* @description:
|
|
30
|
+
* @return {*}
|
|
31
|
+
* @Author: WangHan
|
|
32
|
+
* @Date: 2025-04-15 11:14
|
|
33
|
+
*/
|
|
8
34
|
export declare const useAppointmentBookingLogin: () => {
|
|
9
35
|
isLogin: boolean;
|
|
10
36
|
openLoginModal: (params: {
|
|
11
37
|
callback: any;
|
|
12
38
|
}) => void;
|
|
13
39
|
};
|
|
40
|
+
/**
|
|
41
|
+
* @title: 获取账户
|
|
42
|
+
* @description:
|
|
43
|
+
* @return {*}
|
|
44
|
+
* @Author: WangHan
|
|
45
|
+
* @Date: 2025-04-15 11:15
|
|
46
|
+
*/
|
|
14
47
|
export declare const useAppointmentBookingAccount: () => {
|
|
15
|
-
currentUser: {
|
|
16
|
-
id: any;
|
|
17
|
-
username: string;
|
|
18
|
-
};
|
|
19
48
|
accountLists: any;
|
|
20
49
|
};
|
|
50
|
+
/**
|
|
51
|
+
* @title: 获取资源数据
|
|
52
|
+
* @description:
|
|
53
|
+
* @return {*}
|
|
54
|
+
* @Author: WangHan
|
|
55
|
+
* @Date: 2025-04-15 11:29
|
|
56
|
+
*/
|
|
21
57
|
export declare const useAppointmentBookingResource: () => {
|
|
22
|
-
getResourceTimeSlot: (
|
|
23
|
-
getResourceList: () =>
|
|
24
|
-
|
|
58
|
+
getResourceTimeSlot: (index?: number) => Promise<void>;
|
|
59
|
+
getResourceList: () => {
|
|
60
|
+
resources: any;
|
|
61
|
+
resourceCodes: any;
|
|
62
|
+
};
|
|
63
|
+
autoSelectAllProductResources: (index?: number) => Promise<any>;
|
|
25
64
|
};
|
|
@@ -39,11 +39,10 @@ __export(hooks_exports, {
|
|
|
39
39
|
useShopDiscount: () => useShopDiscount
|
|
40
40
|
});
|
|
41
41
|
module.exports = __toCommonJS(hooks_exports);
|
|
42
|
+
var import_react = require("react");
|
|
42
43
|
var import_useEngineContext = require("../../hooks/useEngineContext");
|
|
43
44
|
var import_useEngineContext2 = __toESM(require("../../hooks/useEngineContext"));
|
|
44
|
-
var import_utils = require("
|
|
45
|
-
var import_utils2 = require("./utils");
|
|
46
|
-
var import_react = require("react");
|
|
45
|
+
var import_utils = require("./utils");
|
|
47
46
|
var import_context = require("./context");
|
|
48
47
|
var useAppointmentBooking = () => {
|
|
49
48
|
const pisellOS = (0, import_useEngineContext.usePisellOS)();
|
|
@@ -58,14 +57,18 @@ var useAppointmentBookingStep = () => {
|
|
|
58
57
|
const pisellOS = (0, import_useEngineContext.usePisellOS)();
|
|
59
58
|
const { appointmentBooking, setCurrentStep, setIsLastStep } = (0, import_context.useAppointmentBookingContext)();
|
|
60
59
|
const stepList = ((_c = (_b = (_a = appointmentBooking == null ? void 0 : appointmentBooking.store) == null ? void 0 : _a.step) == null ? void 0 : _b.store) == null ? void 0 : _c.stepList) || [];
|
|
60
|
+
const getCurrentAndLastStep = () => {
|
|
61
|
+
const _currentStep = appointmentBooking.getCurrentStep();
|
|
62
|
+
setCurrentStep(_currentStep);
|
|
63
|
+
setIsLastStep((_currentStep == null ? void 0 : _currentStep.index) === stepList.length - 1);
|
|
64
|
+
};
|
|
61
65
|
(0, import_react.useEffect)(() => {
|
|
66
|
+
getCurrentAndLastStep();
|
|
62
67
|
pisellOS.effects.on(
|
|
63
68
|
"appointmentBooking_step:changed",
|
|
64
69
|
async (res) => {
|
|
65
70
|
if (res.path === "currentStep") {
|
|
66
|
-
|
|
67
|
-
setCurrentStep(_currentStep);
|
|
68
|
-
setIsLastStep((_currentStep == null ? void 0 : _currentStep.index) === stepList.length - 1);
|
|
71
|
+
getCurrentAndLastStep();
|
|
69
72
|
}
|
|
70
73
|
}
|
|
71
74
|
);
|
|
@@ -76,33 +79,29 @@ var useAppointmentBookingProduct = () => {
|
|
|
76
79
|
const { productModuleParams } = appointmentBooking.otherParams;
|
|
77
80
|
(0, import_react.useEffect)(() => {
|
|
78
81
|
appointmentBooking.loadProducts(productModuleParams).then((res) => {
|
|
79
|
-
console.log(res, "loadProductsloadProducts");
|
|
80
82
|
setProducts(res || []);
|
|
81
83
|
});
|
|
82
84
|
}, []);
|
|
83
85
|
};
|
|
84
86
|
var useAppointmentBookingCart = () => {
|
|
85
|
-
var _a, _b;
|
|
86
87
|
const pisellOS = (0, import_useEngineContext.usePisellOS)();
|
|
87
88
|
const { appointmentBooking, setCarts, setSummary } = (0, import_context.useAppointmentBookingContext)();
|
|
88
|
-
const
|
|
89
|
+
const getCartAndSummary = async () => {
|
|
90
|
+
const carts = await appointmentBooking.getCart();
|
|
91
|
+
setCarts(carts || []);
|
|
92
|
+
const summary = await appointmentBooking.getSummary();
|
|
93
|
+
setSummary(summary || {});
|
|
94
|
+
console.log(carts, summary, "appointmentBooking_cart:changed");
|
|
95
|
+
};
|
|
89
96
|
(0, import_react.useEffect)(() => {
|
|
90
|
-
|
|
97
|
+
getCartAndSummary();
|
|
91
98
|
pisellOS.effects.on(
|
|
92
99
|
"appointmentBooking_cart:changed",
|
|
93
|
-
async (
|
|
94
|
-
|
|
95
|
-
setCarts(carts || []);
|
|
96
|
-
const summary = await appointmentBooking.getSummary();
|
|
97
|
-
setSummary(summary || {});
|
|
98
|
-
console.log(carts, summary, "appointmentBooking_cart:changed");
|
|
100
|
+
async () => {
|
|
101
|
+
getCartAndSummary();
|
|
99
102
|
}
|
|
100
103
|
);
|
|
101
|
-
(_a2 = appointmentBooking == null ? void 0 : appointmentBooking.getCart) == null ? void 0 : _a2.call(appointmentBooking).then((data) => {
|
|
102
|
-
setCarts(data || []);
|
|
103
|
-
});
|
|
104
104
|
}, []);
|
|
105
|
-
return { cart };
|
|
106
105
|
};
|
|
107
106
|
var useAppointmentBookingLogin = () => {
|
|
108
107
|
var _a, _b;
|
|
@@ -113,71 +112,71 @@ var useAppointmentBookingLogin = () => {
|
|
|
113
112
|
const { callback } = params || {};
|
|
114
113
|
utils.action({
|
|
115
114
|
type: "pisell1.login",
|
|
116
|
-
data: {
|
|
115
|
+
data: {
|
|
116
|
+
type: "plugin"
|
|
117
|
+
},
|
|
117
118
|
callback
|
|
118
119
|
});
|
|
119
120
|
};
|
|
120
121
|
return { isLogin, openLoginModal };
|
|
121
122
|
};
|
|
122
123
|
var useAppointmentBookingAccount = () => {
|
|
123
|
-
var _a, _b;
|
|
124
124
|
const pisellOS = (0, import_useEngineContext.usePisellOS)();
|
|
125
|
-
const context = (0, import_useEngineContext2.default)();
|
|
126
|
-
const utils = context.appHelper.utils || {};
|
|
127
125
|
const appointmentBooking = useAppointmentBooking();
|
|
128
126
|
const [accountLists, setAccountLists] = (0, import_react.useState)([]);
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
currentUserName = (currentUserName == null ? void 0 : currentUserName.trim()) || (userInfo == null ? void 0 : userInfo.nickname) || "Me";
|
|
134
|
-
const currentUser = {
|
|
135
|
-
id: (userInfo == null ? void 0 : userInfo.id) || (0, import_utils.getUniqueId)(),
|
|
136
|
-
username: currentUserName
|
|
127
|
+
const getAccountLists = async () => {
|
|
128
|
+
const data = await appointmentBooking.getAccounts();
|
|
129
|
+
console.log("appointmentBooking_accountList:changed", data);
|
|
130
|
+
setAccountLists(data || []);
|
|
137
131
|
};
|
|
138
132
|
(0, import_react.useEffect)(() => {
|
|
133
|
+
getAccountLists();
|
|
139
134
|
pisellOS.effects.on(
|
|
140
135
|
"appointmentBooking_accountList:changed",
|
|
141
136
|
async (res) => {
|
|
142
137
|
if (res.path === "accounts") {
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
});
|
|
138
|
+
console.log("appointmentBooking_accountList:changed", res);
|
|
139
|
+
getAccountLists();
|
|
146
140
|
}
|
|
147
141
|
}
|
|
148
142
|
);
|
|
149
|
-
appointmentBooking.getAccounts().then((data) => {
|
|
150
|
-
setAccountLists(data || []);
|
|
151
|
-
});
|
|
152
143
|
}, []);
|
|
153
|
-
return {
|
|
144
|
+
return { accountLists };
|
|
154
145
|
};
|
|
155
146
|
var useAppointmentBookingResource = () => {
|
|
156
147
|
const { appointmentBooking, setResources, setTimes, setResourceOtherParams, resourceOtherParams } = (0, import_context.useAppointmentBookingContext)();
|
|
157
148
|
const { resourceSort } = (appointmentBooking == null ? void 0 : appointmentBooking.otherParams) || {};
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
const data = await appointmentBooking.getResourceTimeSlot(params);
|
|
161
|
-
setTimes(data || []);
|
|
162
|
-
};
|
|
163
|
-
const getResourceList = async () => {
|
|
149
|
+
const getResourceList = () => {
|
|
150
|
+
var _a;
|
|
164
151
|
let resources = appointmentBooking.getResourcesList();
|
|
165
152
|
resources = resources.map((item) => {
|
|
166
153
|
return {
|
|
167
154
|
...item,
|
|
168
|
-
resources: (0,
|
|
155
|
+
resources: (0, import_utils.sortResources)((item == null ? void 0 : item.resources) || [], resourceSort)
|
|
169
156
|
};
|
|
170
157
|
});
|
|
158
|
+
const _resources = ((_a = resources == null ? void 0 : resources[0]) == null ? void 0 : _a.resources) || [];
|
|
159
|
+
const resourceCodes = _resources.map((item) => item.code);
|
|
171
160
|
setResources(resources || []);
|
|
172
|
-
return resources;
|
|
161
|
+
return { resources, resourceCodes };
|
|
162
|
+
};
|
|
163
|
+
const getResourceTimeSlot = async (index) => {
|
|
164
|
+
const { resourceCodes } = getResourceList();
|
|
165
|
+
const code = resourceCodes == null ? void 0 : resourceCodes[index || 0];
|
|
166
|
+
const data = await appointmentBooking.getTimeSlotByAllResources(code);
|
|
167
|
+
setTimes(data || []);
|
|
173
168
|
};
|
|
174
|
-
const autoSelectAllProductResources = async (
|
|
169
|
+
const autoSelectAllProductResources = async (index) => {
|
|
170
|
+
const { resourceCodes } = getResourceList();
|
|
171
|
+
const code = resourceCodes == null ? void 0 : resourceCodes[index || 0];
|
|
172
|
+
const data = await appointmentBooking.getTimeSlotByAllResources(code);
|
|
175
173
|
let res = await appointmentBooking.autoSelectAllProductResources(code);
|
|
176
|
-
console.log(res, "autoSelectAllProductResources");
|
|
177
174
|
setResourceOtherParams({
|
|
178
175
|
...resourceOtherParams,
|
|
179
|
-
...res
|
|
176
|
+
...res,
|
|
177
|
+
resourceCodes
|
|
180
178
|
});
|
|
179
|
+
return res;
|
|
181
180
|
};
|
|
182
181
|
return { getResourceTimeSlot, getResourceList, autoSelectAllProductResources };
|
|
183
182
|
};
|
|
@@ -33,23 +33,27 @@ __export(appointmentBooking_exports, {
|
|
|
33
33
|
});
|
|
34
34
|
module.exports = __toCommonJS(appointmentBooking_exports);
|
|
35
35
|
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_Content = __toESM(require("./components/Content"));
|
|
37
36
|
var import_utils = require("@pisell/utils");
|
|
38
37
|
var import_useEngineContext = __toESM(require("../../hooks/useEngineContext"));
|
|
39
|
-
var import_index = require("./index.less");
|
|
40
|
-
var import_locales = __toESM(require("./locales"));
|
|
41
38
|
var import_context = require("./context");
|
|
39
|
+
var import_Content = __toESM(require("./components/Content"));
|
|
40
|
+
var import_locales = __toESM(require("./locales"));
|
|
42
41
|
var import_hooks = require("./hooks");
|
|
42
|
+
var import_utils2 = require("./utils");
|
|
43
|
+
var import_index = require("./index.less");
|
|
43
44
|
var AppointmentBooking = () => {
|
|
44
45
|
var _a;
|
|
45
46
|
const context = (0, import_useEngineContext.default)();
|
|
46
|
-
const appointmentBooking = (0, import_hooks.useAppointmentBooking)();
|
|
47
|
-
const appointmentBookingAccount = (0, import_hooks.useAppointmentBookingAccount)();
|
|
48
47
|
const utils = context.appHelper.utils || {};
|
|
49
48
|
import_utils.locales.init(import_locales.default, ((_a = utils == null ? void 0 : utils.storage) == null ? void 0 : _a.get("umi_locale")) || "en");
|
|
49
|
+
const appointmentBooking = (0, import_hooks.useAppointmentBooking)();
|
|
50
|
+
const currentUser = (0, import_utils2.formatCurrentUser)();
|
|
50
51
|
(0, import_react.useEffect)(() => {
|
|
51
|
-
|
|
52
|
-
|
|
52
|
+
appointmentBooking.getAccounts().then((data) => {
|
|
53
|
+
if (!data.length) {
|
|
54
|
+
appointmentBooking.addAccount([currentUser]);
|
|
55
|
+
}
|
|
56
|
+
});
|
|
53
57
|
}, []);
|
|
54
58
|
return /* @__PURE__ */ import_react.default.createElement(
|
|
55
59
|
"div",
|
|
@@ -70,11 +70,23 @@ declare const _default: {
|
|
|
70
70
|
'pisell2.event.capacity.limit.reached.title': string;
|
|
71
71
|
'pisell2.event.capacity.limit.reached.tip': string;
|
|
72
72
|
'pisell2.appointment.booking.empty.service': string;
|
|
73
|
+
'pisell2.appointment.booking.empty.time': string;
|
|
73
74
|
'pisell2.appointment.service.title': (val: number) => string;
|
|
74
75
|
'pisell2.appointment.add.guest': string;
|
|
75
76
|
'pisell2.appointment.edit.service': string;
|
|
76
77
|
'pisell2.appointment.remove.guest': string;
|
|
77
78
|
'pisell2.appointment.no.available.service': string;
|
|
79
|
+
'pisell2.appointment.max.guest': string;
|
|
80
|
+
'pisell2.appointment.no.available.time': string;
|
|
81
|
+
'pisell2.appointment.monday': string;
|
|
82
|
+
'pisell2.appointment.tuesday': string;
|
|
83
|
+
'pisell2.appointment.wednesday': string;
|
|
84
|
+
'pisell2.appointment.thursday': string;
|
|
85
|
+
'pisell2.appointment.friday': string;
|
|
86
|
+
'pisell2.appointment.saturday': string;
|
|
87
|
+
'pisell2.appointment.sunday': string;
|
|
88
|
+
'pisell2.appointment.any.professional': string;
|
|
89
|
+
'pisell2.appointment.for.maximum.availability': string;
|
|
78
90
|
'pisell2.text.apply': string;
|
|
79
91
|
'pisell2.text.goodpass': string;
|
|
80
92
|
'pisell2.text.goodpass.product-vouchers': string;
|
|
@@ -156,11 +168,23 @@ declare const _default: {
|
|
|
156
168
|
'pisell2.event.capacity.limit.reached.title': string;
|
|
157
169
|
'pisell2.event.capacity.limit.reached.tip': string;
|
|
158
170
|
'pisell2.appointment.booking.empty.service': string;
|
|
171
|
+
'pisell2.appointment.booking.empty.time': string;
|
|
159
172
|
'pisell2.appointment.service.title': (val: number) => string;
|
|
160
173
|
'pisell2.appointment.add.guest': string;
|
|
161
174
|
'pisell2.appointment.edit.service': string;
|
|
162
175
|
'pisell2.appointment.remove.guest': string;
|
|
163
176
|
'pisell2.appointment.no.available.service': string;
|
|
177
|
+
'pisell2.appointment.max.guest': string;
|
|
178
|
+
'pisell2.appointment.no.available.time': string;
|
|
179
|
+
'pisell2.appointment.monday': string;
|
|
180
|
+
'pisell2.appointment.tuesday': string;
|
|
181
|
+
'pisell2.appointment.wednesday': string;
|
|
182
|
+
'pisell2.appointment.thursday': string;
|
|
183
|
+
'pisell2.appointment.friday': string;
|
|
184
|
+
'pisell2.appointment.saturday': string;
|
|
185
|
+
'pisell2.appointment.sunday': string;
|
|
186
|
+
'pisell2.appointment.any.professional': string;
|
|
187
|
+
'pisell2.appointment.for.maximum.availability': string;
|
|
164
188
|
'pisell2.text.apply': string;
|
|
165
189
|
'pisell2.text.goodpass': string;
|
|
166
190
|
'pisell2.text.goodpass.product-vouchers': string;
|
|
@@ -242,11 +266,23 @@ declare const _default: {
|
|
|
242
266
|
'pisell2.event.capacity.limit.reached.title': string;
|
|
243
267
|
'pisell2.event.capacity.limit.reached.tip': string;
|
|
244
268
|
'pisell2.appointment.booking.empty.service': string;
|
|
269
|
+
'pisell2.appointment.booking.empty.time': string;
|
|
245
270
|
'pisell2.appointment.service.title': (val: number) => string;
|
|
246
271
|
'pisell2.appointment.add.guest': string;
|
|
247
272
|
'pisell2.appointment.edit.service': string;
|
|
248
273
|
'pisell2.appointment.remove.guest': string;
|
|
249
274
|
'pisell2.appointment.no.available.service': string;
|
|
275
|
+
'pisell2.appointment.max.guest': string;
|
|
276
|
+
'pisell2.appointment.no.available.time': string;
|
|
277
|
+
'pisell2.appointment.monday': string;
|
|
278
|
+
'pisell2.appointment.tuesday': string;
|
|
279
|
+
'pisell2.appointment.wednesday': string;
|
|
280
|
+
'pisell2.appointment.thursday': string;
|
|
281
|
+
'pisell2.appointment.friday': string;
|
|
282
|
+
'pisell2.appointment.saturday': string;
|
|
283
|
+
'pisell2.appointment.sunday': string;
|
|
284
|
+
'pisell2.appointment.any.professional': string;
|
|
285
|
+
'pisell2.appointment.for.maximum.availability': string;
|
|
250
286
|
'pisell2.text.apply': string;
|
|
251
287
|
'pisell2.text.goodpass': string;
|
|
252
288
|
'pisell2.text.goodpass.product-vouchers': string;
|
|
@@ -94,11 +94,23 @@ var locales_default = {
|
|
|
94
94
|
"pisell2.event.capacity.limit.reached.title": "Capacity limit reached",
|
|
95
95
|
"pisell2.event.capacity.limit.reached.tip": "One or more events in your cart are no longer available due to full capacity. Please remove unavailable events from your cart to complete checkout.",
|
|
96
96
|
"pisell2.appointment.booking.empty.service": "No service",
|
|
97
|
+
"pisell2.appointment.booking.empty.time": "No time",
|
|
97
98
|
"pisell2.appointment.service.title": (val) => `${val} ${val > 1 ? "services" : "service"}`,
|
|
98
99
|
"pisell2.appointment.add.guest": "Add guest",
|
|
99
100
|
"pisell2.appointment.edit.service": "Edit services",
|
|
100
101
|
"pisell2.appointment.remove.guest": "Remove guest",
|
|
101
102
|
"pisell2.appointment.no.available.service": "No available times for this service. Please choose another.",
|
|
103
|
+
"pisell2.appointment.max.guest": "Book a group appointment for up to 6 guests",
|
|
104
|
+
"pisell2.appointment.no.available.time": "No availability Try booking different time",
|
|
105
|
+
"pisell2.appointment.monday": "Mon",
|
|
106
|
+
"pisell2.appointment.tuesday": "Tue",
|
|
107
|
+
"pisell2.appointment.wednesday": "Wed",
|
|
108
|
+
"pisell2.appointment.thursday": "Thu",
|
|
109
|
+
"pisell2.appointment.friday": "Fri",
|
|
110
|
+
"pisell2.appointment.saturday": "Sat",
|
|
111
|
+
"pisell2.appointment.sunday": "Sun",
|
|
112
|
+
"pisell2.appointment.any.professional": "Any professional",
|
|
113
|
+
"pisell2.appointment.for.maximum.availability": "for maximum availability",
|
|
102
114
|
"pisell2.text.apply": "Apply",
|
|
103
115
|
"pisell2.text.goodpass": "GoodPass",
|
|
104
116
|
"pisell2.text.goodpass.product-vouchers": "Product Vouchers",
|
|
@@ -180,11 +192,23 @@ var locales_default = {
|
|
|
180
192
|
"pisell2.event.capacity.limit.reached.title": "活动名额已满",
|
|
181
193
|
"pisell2.event.capacity.limit.reached.tip": "购物车中有一个或多个活动已达预约上限,请将已满额的活动从购物车中移除后再完成结算。",
|
|
182
194
|
"pisell2.appointment.booking.empty.service": "暂无服务",
|
|
195
|
+
"pisell2.appointment.booking.empty.time": "暂无时间",
|
|
183
196
|
"pisell2.appointment.service.title": (val) => `${val}个服务`,
|
|
184
197
|
"pisell2.appointment.add.guest": "添加预约人",
|
|
185
198
|
"pisell2.appointment.edit.service": "编辑服务",
|
|
186
199
|
"pisell2.appointment.remove.guest": "移除预约人",
|
|
187
200
|
"pisell2.appointment.no.available.service": "此服务无可用时间,请选择其他服务。",
|
|
201
|
+
"pisell2.appointment.max.guest": "最多为6人预约",
|
|
202
|
+
"pisell2.appointment.no.available.time": "无可用 请选择其他时间",
|
|
203
|
+
"pisell2.appointment.monday": "周一",
|
|
204
|
+
"pisell2.appointment.tuesday": "周二",
|
|
205
|
+
"pisell2.appointment.wednesday": "周三",
|
|
206
|
+
"pisell2.appointment.thursday": "周四",
|
|
207
|
+
"pisell2.appointment.friday": "周五",
|
|
208
|
+
"pisell2.appointment.saturday": "周六",
|
|
209
|
+
"pisell2.appointment.sunday": "周日",
|
|
210
|
+
"pisell2.appointment.any.professional": "随机分配",
|
|
211
|
+
"pisell2.appointment.for.maximum.availability": "立即匹配",
|
|
188
212
|
"pisell2.text.apply": "应用",
|
|
189
213
|
"pisell2.text.goodpass": "商品券",
|
|
190
214
|
"pisell2.text.goodpass.product-vouchers": "商品兑换券",
|
|
@@ -266,11 +290,23 @@ var locales_default = {
|
|
|
266
290
|
"pisell2.event.capacity.limit.reached.title": "活動名額已滿",
|
|
267
291
|
"pisell2.event.capacity.limit.reached.tip": "購物車中有一個或多個活動已達預約上限,請將已滿額的活動從購物車中移除後再完成結算。",
|
|
268
292
|
"pisell2.appointment.booking.empty.service": "暫無服務",
|
|
293
|
+
"pisell2.appointment.booking.empty.time": "暫無時間",
|
|
269
294
|
"pisell2.appointment.service.title": (val) => `${val}个服務`,
|
|
270
295
|
"pisell2.appointment.add.guest": "添加預約人",
|
|
271
296
|
"pisell2.appointment.edit.service": "編輯服務",
|
|
272
297
|
"pisell2.appointment.remove.guest": "移除預約人",
|
|
273
298
|
"pisell2.appointment.no.available.service": "此服务无可用时间,请选择其他服务。",
|
|
299
|
+
"pisell2.appointment.max.guest": "最多为6人预约",
|
|
300
|
+
"pisell2.appointment.no.available.time": "無可用 請選擇其他時間",
|
|
301
|
+
"pisell2.appointment.monday": "周壹",
|
|
302
|
+
"pisell2.appointment.tuesday": "周二",
|
|
303
|
+
"pisell2.appointment.wednesday": "周三",
|
|
304
|
+
"pisell2.appointment.thursday": "周四",
|
|
305
|
+
"pisell2.appointment.friday": "周五",
|
|
306
|
+
"pisell2.appointment.saturday": "周六",
|
|
307
|
+
"pisell2.appointment.sunday": "周日",
|
|
308
|
+
"pisell2.appointment.any.professional": "隨機分配",
|
|
309
|
+
"pisell2.appointment.for.maximum.availability": "立即匹配",
|
|
274
310
|
"pisell2.text.apply": "應用",
|
|
275
311
|
"pisell2.text.goodpass": "商品券",
|
|
276
312
|
"pisell2.text.goodpass.product-vouchers": "商品兌換券",
|
|
@@ -56,3 +56,31 @@ export declare const formatCarts: (data: any[], resources: any[]) => any[];
|
|
|
56
56
|
* @Date: 2025-04-14 11:16
|
|
57
57
|
*/
|
|
58
58
|
export declare const sortResources: (resources: any[], resourceSort: any[]) => any[] | undefined;
|
|
59
|
+
export declare const getMeAccount: (val: any[]) => any;
|
|
60
|
+
export declare const formatCustomer: (val: any) => {
|
|
61
|
+
id: any;
|
|
62
|
+
username: string;
|
|
63
|
+
};
|
|
64
|
+
export declare const formatCurrentUser: () => {
|
|
65
|
+
id: any;
|
|
66
|
+
username: string;
|
|
67
|
+
};
|
|
68
|
+
/**
|
|
69
|
+
* @title: 检查是否有空的账户
|
|
70
|
+
* @description:
|
|
71
|
+
* @param {any} carts
|
|
72
|
+
* @param {any} accounts
|
|
73
|
+
* @return {*}
|
|
74
|
+
* @Author: WangHan
|
|
75
|
+
* @Date: 2025-04-15 17:05
|
|
76
|
+
*/
|
|
77
|
+
export declare const isEmptyGuest: (carts: any[], accounts: any[]) => boolean;
|
|
78
|
+
/**
|
|
79
|
+
* @title: 购物车中是否有空的资源数据
|
|
80
|
+
* @description:
|
|
81
|
+
* @param {any} carts
|
|
82
|
+
* @return {*}
|
|
83
|
+
* @Author: WangHan
|
|
84
|
+
* @Date: 2025-04-15 21:51
|
|
85
|
+
*/
|
|
86
|
+
export declare const isEmptyCartsResourceId: (carts: any[]) => boolean;
|
|
@@ -31,16 +31,22 @@ var utils_exports = {};
|
|
|
31
31
|
__export(utils_exports, {
|
|
32
32
|
formatBackgroundColors: () => formatBackgroundColors,
|
|
33
33
|
formatCarts: () => formatCarts,
|
|
34
|
+
formatCurrentUser: () => formatCurrentUser,
|
|
35
|
+
formatCustomer: () => formatCustomer,
|
|
34
36
|
formatGuest: () => formatGuest,
|
|
35
37
|
formatHolder: () => formatHolder,
|
|
36
38
|
formatMonthDisplay: () => formatMonthDisplay,
|
|
39
|
+
getMeAccount: () => getMeAccount,
|
|
37
40
|
getScheduleColors: () => getScheduleColors,
|
|
38
41
|
getUsableSchedules: () => getUsableSchedules,
|
|
42
|
+
isEmptyCartsResourceId: () => isEmptyCartsResourceId,
|
|
43
|
+
isEmptyGuest: () => isEmptyGuest,
|
|
39
44
|
resourceTitle: () => resourceTitle,
|
|
40
45
|
sortResources: () => sortResources
|
|
41
46
|
});
|
|
42
47
|
module.exports = __toCommonJS(utils_exports);
|
|
43
48
|
var import_dayjs = __toESM(require("dayjs"));
|
|
49
|
+
var import_utils = require("@pisell/utils");
|
|
44
50
|
var import_useEngineContext = __toESM(require("../../hooks/useEngineContext"));
|
|
45
51
|
var formatBackgroundColors = (colors) => {
|
|
46
52
|
let _colors = Array.from(new Set(colors.map((color) => color == null ? void 0 : color.toLocaleLowerCase()) || [])).filter((d) => !!d);
|
|
@@ -115,7 +121,7 @@ var formatCarts = (data, resources) => {
|
|
|
115
121
|
const utils = context.appHelper.utils || {};
|
|
116
122
|
const locale = ((_a = utils == null ? void 0 : utils.storage) == null ? void 0 : _a.get("umi_locale")) || "en-US";
|
|
117
123
|
const symbol = (utils == null ? void 0 : utils.getSymbolic()) || "$";
|
|
118
|
-
console.log(
|
|
124
|
+
console.log(data, resources, "formatCartsformatCarts");
|
|
119
125
|
return data == null ? void 0 : data.map((d) => {
|
|
120
126
|
var _a2, _b;
|
|
121
127
|
const currentResource = resources.find((r) => (d == null ? void 0 : d._id) === (r == null ? void 0 : r._id));
|
|
@@ -123,7 +129,7 @@ var formatCarts = (data, resources) => {
|
|
|
123
129
|
currentResources = currentResources == null ? void 0 : currentResources.map((d2) => {
|
|
124
130
|
return {
|
|
125
131
|
...d2,
|
|
126
|
-
label: d2 == null ? void 0 : d2.main_field
|
|
132
|
+
label: (d2 == null ? void 0 : d2.main_field) || (d2 == null ? void 0 : d2.id)
|
|
127
133
|
};
|
|
128
134
|
});
|
|
129
135
|
return {
|
|
@@ -168,15 +174,55 @@ var sortResources = (resources, resourceSort) => {
|
|
|
168
174
|
console.log(error, "wh2222");
|
|
169
175
|
}
|
|
170
176
|
};
|
|
177
|
+
var getMeAccount = (val) => {
|
|
178
|
+
return val == null ? void 0 : val.find((d) => !(d == null ? void 0 : d.isGuest));
|
|
179
|
+
};
|
|
180
|
+
var formatCustomer = (val) => {
|
|
181
|
+
let currentUserName = `${(val == null ? void 0 : val.first_name) || ""}${(val == null ? void 0 : val.last_name) ? ` ${val == null ? void 0 : val.last_name}` : ""}`;
|
|
182
|
+
currentUserName = currentUserName || (val == null ? void 0 : val.nickname) || "Me";
|
|
183
|
+
return {
|
|
184
|
+
id: (val == null ? void 0 : val.id) || (0, import_utils.getUniqueId)(),
|
|
185
|
+
username: currentUserName
|
|
186
|
+
};
|
|
187
|
+
};
|
|
188
|
+
var formatCurrentUser = () => {
|
|
189
|
+
var _a, _b;
|
|
190
|
+
const context = (0, import_useEngineContext.default)();
|
|
191
|
+
const utils = context.appHelper.utils || {};
|
|
192
|
+
let userInfo = (_b = (_a = utils.getStore().getState()) == null ? void 0 : _a.global) == null ? void 0 : _b.userInfo;
|
|
193
|
+
const localUserInfo = JSON.parse(utils.storage.get("customer") || "{}");
|
|
194
|
+
userInfo = (userInfo == null ? void 0 : userInfo.id) ? userInfo : localUserInfo;
|
|
195
|
+
const customer = formatCustomer(userInfo);
|
|
196
|
+
return customer;
|
|
197
|
+
};
|
|
198
|
+
var isEmptyGuest = (carts, accounts) => {
|
|
199
|
+
for (const item of accounts) {
|
|
200
|
+
const hasMatch = carts.some((firstItem) => firstItem.holder_id === item.id);
|
|
201
|
+
if (!hasMatch) {
|
|
202
|
+
return true;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
return false;
|
|
206
|
+
};
|
|
207
|
+
var isEmptyCartsResourceId = (carts) => {
|
|
208
|
+
const isEmptyResourceId = carts == null ? void 0 : carts.some((d) => !(d == null ? void 0 : d.resource_id));
|
|
209
|
+
console.log(isEmptyResourceId, "isEmptyResourceId");
|
|
210
|
+
return isEmptyResourceId;
|
|
211
|
+
};
|
|
171
212
|
// Annotate the CommonJS export names for ESM import in node:
|
|
172
213
|
0 && (module.exports = {
|
|
173
214
|
formatBackgroundColors,
|
|
174
215
|
formatCarts,
|
|
216
|
+
formatCurrentUser,
|
|
217
|
+
formatCustomer,
|
|
175
218
|
formatGuest,
|
|
176
219
|
formatHolder,
|
|
177
220
|
formatMonthDisplay,
|
|
221
|
+
getMeAccount,
|
|
178
222
|
getScheduleColors,
|
|
179
223
|
getUsableSchedules,
|
|
224
|
+
isEmptyCartsResourceId,
|
|
225
|
+
isEmptyGuest,
|
|
180
226
|
resourceTitle,
|
|
181
227
|
sortResources
|
|
182
228
|
});
|
|
@@ -188,26 +188,12 @@ var formatMetaData = (item) => {
|
|
|
188
188
|
}
|
|
189
189
|
return metadata;
|
|
190
190
|
};
|
|
191
|
-
var formatDiscountList = (list) => {
|
|
192
|
-
return list.map((item) => {
|
|
193
|
-
var _a, _b, _c, _d;
|
|
194
|
-
return {
|
|
195
|
-
amount: item.amount,
|
|
196
|
-
product_id: item.product_id || ((_a = item.discount) == null ? void 0 : _a.product_id),
|
|
197
|
-
resource_id: item.resource_id || ((_b = item.discount) == null ? void 0 : _b.resource_id),
|
|
198
|
-
title: item.title || ((_c = item.discount) == null ? void 0 : _c.title),
|
|
199
|
-
original_amount: item.original_amount || ((_d = item.discount) == null ? void 0 : _d.original_amount),
|
|
200
|
-
id: item.id,
|
|
201
|
-
type: item.type
|
|
202
|
-
};
|
|
203
|
-
});
|
|
204
|
-
};
|
|
205
191
|
var formatProducts = (item) => {
|
|
206
192
|
var _a, _b, _c, _d, _e, _f;
|
|
207
193
|
const total = Number(item._extend.total);
|
|
208
194
|
const origin_total = Number(item._extend.origin_total);
|
|
209
195
|
const discount_amount = origin_total - total;
|
|
210
|
-
const discount_list =
|
|
196
|
+
const discount_list = (item == null ? void 0 : item.discount_list) || [];
|
|
211
197
|
const discount_type = discount_amount < 0 ? "change_price" : "discount";
|
|
212
198
|
return {
|
|
213
199
|
"num": item._extend.quantity,
|