@pisell/private-materials 6.0.23 → 6.0.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 +29 -13
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +12 -27
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +18 -33
- package/es/businessModel/SalesModel/Sales/index.d.ts +24 -0
- package/es/businessModel/SalesModel/Sales/index.js +69 -0
- package/es/businessModel/SalesModel/hooks/index.d.ts +1 -0
- package/es/businessModel/SalesModel/hooks/index.js +7 -0
- package/es/businessModel/SalesModel/index.d.ts +4 -0
- package/es/businessModel/SalesModel/index.js +18 -0
- package/es/businessModel/index.d.ts +0 -0
- package/es/businessModel/index.js +0 -0
- package/es/components/Sales/Cart/index.d.ts +53 -0
- package/es/components/Sales/Cart/index.js +590 -0
- package/es/components/Sales/Cart/serve.d.ts +2 -0
- package/es/components/Sales/Cart/serve.js +11 -0
- package/es/components/Sales/Cart/types.d.ts +19 -0
- package/es/components/Sales/Cart/types.js +1 -0
- package/es/components/Sales/Checkout/index.d.ts +33 -0
- package/es/components/Sales/Checkout/index.js +152 -0
- package/es/components/Sales/Checkout/serve.d.ts +2 -0
- package/es/components/Sales/Checkout/serve.js +11 -0
- package/es/components/Sales/Checkout/utils.d.ts +27 -0
- package/es/components/Sales/Checkout/utils.js +104 -0
- package/es/components/Sales/Customer/index.d.ts +24 -0
- package/es/components/Sales/Customer/index.js +59 -0
- package/es/components/Sales/Event/Detail.d.ts +27 -0
- package/es/components/Sales/Event/Detail.js +246 -0
- package/es/components/Sales/Event/index.d.ts +30 -0
- package/es/components/Sales/Event/index.js +123 -0
- package/es/components/Sales/Event/serve.d.ts +26 -0
- package/es/components/Sales/Event/serve.js +33 -0
- package/es/components/Sales/Holder/index.d.ts +33 -0
- package/es/components/Sales/Holder/index.js +229 -0
- package/es/components/Sales/Holder/serve.d.ts +8 -0
- package/es/components/Sales/Holder/serve.js +20 -0
- package/es/components/Sales/Init/index.d.ts +24 -0
- package/es/components/Sales/Init/index.js +117 -0
- package/es/components/Sales/Init/serve.d.ts +3 -0
- package/es/components/Sales/Init/serve.js +11 -0
- package/es/components/Sales/Resource/index.d.ts +26 -0
- package/es/components/Sales/Resource/index.js +128 -0
- package/es/components/Sales/Resource/serve.d.ts +5 -0
- package/es/components/Sales/Resource/serve.js +8 -0
- package/es/components/Sales/Step/index.d.ts +37 -0
- package/es/components/Sales/Step/index.js +195 -0
- package/es/components/Sales/Summary/index.d.ts +25 -0
- package/es/components/Sales/Summary/index.js +50 -0
- package/es/components/Sales/Summary/serve.d.ts +0 -0
- package/es/components/Sales/Summary/serve.js +0 -0
- package/es/components/Sales/Summary/utils.d.ts +36 -0
- package/es/components/Sales/Summary/utils.js +63 -0
- package/es/components/Sales/hooks/index.d.ts +1 -0
- package/es/components/Sales/hooks/index.js +3 -0
- package/es/components/Sales/index.d.ts +20 -0
- package/es/components/Sales/index.js +26 -0
- package/es/components/Sales/utils/index.d.ts +1 -0
- package/es/components/Sales/utils/index.js +18 -0
- package/es/components/booking/components/customSelect/index.d.ts +1 -0
- package/es/components/booking/components/customSelect/index.js +6 -2
- package/es/components/booking/components/footer/AppointmentProductModal/index.d.ts +3 -0
- package/es/components/booking/components/footer/AppointmentProductModal/index.js +38 -0
- package/es/components/booking/components/footer/AppointmentProductModal/index.less +0 -0
- package/es/components/booking/components/footer/amount.js +46 -22
- package/es/components/booking/components/footer/index.js +116 -79
- package/es/components/booking/components/footer/serve.d.ts +2 -0
- package/es/components/booking/components/footer/serve.js +44 -0
- package/es/components/booking/components/footer/utils.js +280 -35
- package/es/components/booking/info/Provider.d.ts +0 -0
- package/es/components/booking/info/Provider.js +54 -0
- package/es/components/booking/info/addServiceVariant/index.js +8 -1
- package/es/components/booking/info/clientVariant/vertical/SelectDrawer.d.ts +1 -0
- package/es/components/booking/info/clientVariant/vertical/SelectDrawer.js +14 -13
- package/es/components/booking/info/clientVariant/vertical/index.js +131 -15
- package/es/components/booking/info/dateRange/index.d.ts +4 -0
- package/es/components/booking/info/dateRange/index.js +98 -0
- package/es/components/booking/info/dateRange/index.less +21 -0
- package/es/components/booking/info/main.js +44 -28
- package/es/components/booking/info/model.js +3 -0
- package/es/components/booking/info/pet/ChangePetModal/index.d.ts +4 -0
- package/es/components/booking/info/pet/ChangePetModal/index.js +134 -0
- package/es/components/booking/info/pet/ChangePetModal/index.less +4 -0
- package/es/components/booking/info/pet/index.d.ts +1 -1
- package/es/components/booking/info/pet/index.js +93 -34
- package/es/components/booking/info/service/addService/index.d.ts +0 -1
- package/es/components/booking/info/service/addService/index.js +195 -104
- package/es/components/booking/info/service/addService/index.less +13 -3
- package/es/components/booking/info/service/addService/utils.d.ts +12 -2
- package/es/components/booking/info/service/addService/utils.js +103 -26
- package/es/components/booking/info/service/addTimeModal/index.d.ts +0 -1
- package/es/components/booking/info/service/editService/BookingList/index.d.ts +4 -0
- package/es/components/booking/info/service/editService/BookingList/index.js +39 -0
- package/es/components/booking/info/service/editService/EditTabs/index.d.ts +3 -0
- package/es/components/booking/info/service/editService/EditTabs/index.js +35 -0
- package/es/components/booking/info/service/editService/index.js +449 -141
- package/es/components/booking/info/service/editService/index.less +18 -13
- package/es/components/booking/info/service/serve.d.ts +10 -0
- package/es/components/booking/info/service/serve.js +28 -0
- package/es/components/booking/info/service/serviceManager/distributeDiscount.d.ts +11 -0
- package/es/components/booking/info/service/serviceManager/distributeDiscount.js +55 -0
- package/es/components/booking/info/service/serviceManager/index.d.ts +20 -0
- package/es/components/booking/info/service/serviceManager/index.js +281 -0
- package/es/components/booking/info/service/serviceManager/utils.d.ts +0 -0
- package/es/components/booking/info/service/serviceManager/utils.js +0 -0
- package/es/components/booking/info/service2/Group/utils.d.ts +14 -0
- package/es/components/booking/info/service2/Group/utils.js +146 -0
- package/es/components/booking/info/service2/Lists.d.ts +3 -0
- package/es/components/booking/info/service2/Lists.js +153 -0
- package/es/components/booking/info/service2/hooks/useSelectPet.d.ts +6 -0
- package/es/components/booking/info/service2/hooks/useSelectPet.js +54 -0
- package/es/components/booking/info/service2/index.d.ts +6 -0
- package/es/components/booking/info/service2/index.js +57 -0
- package/es/components/booking/info/service2/status.d.ts +31 -0
- package/es/components/booking/info/service2/status.js +78 -0
- package/es/components/booking/info/service2/utils.d.ts +240 -0
- package/es/components/booking/info/service2/utils.js +1077 -0
- package/es/components/booking/info/utils.d.ts +20 -0
- package/es/components/booking/info/utils.js +38 -1
- package/es/components/booking/info2/utilsByBooking.js +0 -1
- package/es/components/booking/locales.d.ts +66 -0
- package/es/components/booking/locales.js +81 -3
- package/es/components/booking/materiels/contacts/index.d.ts +1 -0
- package/es/components/booking/materiels/holder/index.d.ts +7 -0
- package/es/components/booking/materiels/holder/index.js +51 -0
- package/es/components/booking/model.d.ts +5 -1
- package/es/components/booking/model.js +4 -2
- package/es/components/booking/utils.d.ts +12 -3
- package/es/components/booking/utils.js +143 -26
- package/es/components/eftpos/hooks.d.ts +4 -4
- package/es/components/eftpos/index.d.ts +1 -0
- 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/unknow.d.ts +0 -1
- package/es/components/eftposPay/component/step/index.d.ts +6 -6
- package/es/components/eftposPay/component/step/step.d.ts +4 -4
- package/es/components/eftposPay/hooks.d.ts +1 -1
- package/es/components/eftposPay/pay.d.ts +0 -1
- package/es/components/eftposPay/tyro/hooks.d.ts +2 -2
- package/es/components/eftposPay/windcave/helper.d.ts +1 -1
- package/es/components/eventBooking/assets/alert-circle.png +0 -0
- package/es/components/eventBooking/assets/calendar-heart.svg +5 -0
- package/es/components/eventBooking/assets/compass.svg +13 -0
- package/es/components/eventBooking/assets/image.svg +5 -0
- package/es/components/eventBooking/assets/phone.svg +5 -0
- package/es/components/eventBooking/assets/shopping-cart.svg +10 -0
- package/es/components/eventBooking/components/ErrorTip/index.d.ts +3 -0
- package/es/components/eventBooking/components/ErrorTip/index.js +14 -0
- package/es/components/eventBooking/components/ErrorTip/index.less +51 -0
- package/es/components/eventBooking/components/OpenCard/index.d.ts +4 -0
- package/es/components/eventBooking/components/OpenCard/index.js +65 -0
- package/es/components/eventBooking/components/OpenCard/index.less +52 -0
- package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +274 -0
- package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.less +0 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/Total.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/Total.js +46 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/index.js +63 -0
- package/es/components/eventBooking/components/Provider/Cart/Item/index.less +87 -0
- package/es/components/eventBooking/components/Provider/Cart/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Cart/index.js +30 -0
- package/es/components/eventBooking/components/Provider/Cart/index.less +2 -0
- package/es/components/eventBooking/components/Provider/Content/index.d.ts +4 -0
- package/es/components/eventBooking/components/Provider/Content/index.js +65 -0
- package/es/components/eventBooking/components/Provider/Content/index.less +31 -0
- package/es/components/eventBooking/components/Provider/EmptyHolderModal/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/EmptyHolderModal/index.js +34 -0
- package/es/components/eventBooking/components/Provider/EmptyHolderModal/index.less +17 -0
- package/es/components/eventBooking/components/Provider/Event/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Event/index.js +93 -0
- package/es/components/eventBooking/components/Provider/Event/index.less +20 -0
- package/es/components/eventBooking/components/Provider/Footer/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Footer/index.js +76 -0
- package/es/components/eventBooking/components/Provider/Footer/index.less +64 -0
- package/es/components/eventBooking/components/Provider/Header/index.d.ts +4 -0
- package/es/components/eventBooking/components/Provider/Header/index.js +75 -0
- package/es/components/eventBooking/components/Provider/Header/index.less +2 -0
- package/es/components/eventBooking/components/Provider/Information/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Information/index.js +178 -0
- package/es/components/eventBooking/components/Provider/Information/index.less +92 -0
- package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.js +34 -0
- package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.less +27 -0
- package/es/components/eventBooking/components/Provider/OrderProductModal/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/OrderProductModal/index.js +27 -0
- package/es/components/eventBooking/components/Provider/OrderProductModal/index.less +32 -0
- package/es/components/eventBooking/components/Provider/RemoveOptionConfirmModal.d.ts +2 -0
- package/es/components/eventBooking/components/Provider/RemoveOptionConfirmModal.js +31 -0
- package/es/components/eventBooking/components/Provider/Resource/index.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/Resource/index.js +79 -0
- package/es/components/eventBooking/components/Provider/Resource/index.less +46 -0
- package/es/components/eventBooking/components/Provider/SelectHolderModal.d.ts +3 -0
- package/es/components/eventBooking/components/Provider/SelectHolderModal.js +90 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +4 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.js +26 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.less +25 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +10 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.js +65 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.less +32 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +3 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.js +69 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.less +12 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +12 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.js +152 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.less +35 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +4 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.js +20 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.less +28 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +5 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.js +38 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.less +87 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +4 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.js +28 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.less +25 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/index.d.ts +4 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/index.js +269 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/index.less +119 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/state.d.ts +63 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/state.js +256 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.d.ts +4 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.js +173 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.less +4 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/index.d.ts +14 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/index.js +36 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/index.less +2 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/utils.d.ts +34 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/utils.js +70 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/BookingOptions.d.ts +2 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/BookingOptions.js +38 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +3 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Resource.js +33 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +3 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.js +30 -0
- package/es/components/eventBooking/components/bookingDetailModal/index.d.ts +7 -0
- package/es/components/eventBooking/components/bookingDetailModal/index.js +337 -0
- package/es/components/eventBooking/components/bookingDetailModal/index.less +82 -0
- package/es/components/eventBooking/components/bookingServiceList/index.d.ts +17 -0
- package/es/components/eventBooking/components/bookingServiceList/index.js +52 -0
- package/es/components/eventBooking/components/bookingServiceList/index.less +6 -0
- package/es/components/eventBooking/components/eventCard/index.d.ts +14 -0
- package/es/components/eventBooking/components/eventCard/index.js +116 -0
- package/es/components/eventBooking/components/eventCard/index.less +81 -0
- package/es/components/eventBooking/components/productCard/index.d.ts +16 -0
- package/es/components/eventBooking/components/productCard/index.js +79 -0
- package/es/components/eventBooking/components/productCard/index.less +60 -0
- package/es/components/eventBooking/components/progressBar/index.d.ts +16 -0
- package/es/components/eventBooking/components/progressBar/index.js +93 -0
- package/es/components/eventBooking/components/progressBar/index.less +15 -0
- package/es/components/eventBooking/components/resourceDisplay/index.d.ts +23 -0
- package/es/components/eventBooking/components/resourceDisplay/index.js +148 -0
- package/es/components/eventBooking/components/resourceDisplay/index.less +95 -0
- package/es/components/eventBooking/components/resourceUsability/index.d.ts +12 -0
- package/es/components/eventBooking/components/resourceUsability/index.js +44 -0
- package/es/components/eventBooking/components/resourceUsability/index.less +40 -0
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +10 -0
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.js +37 -0
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.less +58 -0
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +11 -0
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.js +127 -0
- package/es/components/eventBooking/components/scheduleCalendar/index.d.ts +13 -0
- package/es/components/eventBooking/components/scheduleCalendar/index.js +142 -0
- package/es/components/eventBooking/components/scheduleCalendar/index.less +222 -0
- package/es/components/eventBooking/components/selectHolder/index.d.ts +22 -0
- package/es/components/eventBooking/components/selectHolder/index.js +118 -0
- package/es/components/eventBooking/components/selectHolder/index.less +70 -0
- package/es/components/eventBooking/components/timeResourceSelector/index.d.ts +20 -0
- package/es/components/eventBooking/components/timeResourceSelector/index.js +168 -0
- package/es/components/eventBooking/components/timeResourceSelector/index.less +74 -0
- package/es/components/eventBooking/index.d.ts +4 -0
- package/es/components/eventBooking/index.js +58 -0
- package/es/components/eventBooking/index.less +22 -0
- package/es/components/eventBooking/locales.d.ts +216 -0
- package/es/components/eventBooking/locales.js +251 -0
- package/es/components/eventBooking/mock.d.ts +627 -0
- package/es/components/eventBooking/mock.js +1172 -0
- package/es/components/eventBooking/status.d.ts +21 -0
- package/es/components/eventBooking/status.js +51 -0
- package/es/components/eventBooking/type.d.ts +17 -0
- package/es/components/eventBooking/type.js +1 -0
- package/es/components/eventBooking/utils.d.ts +45 -0
- package/es/components/eventBooking/utils.js +99 -0
- package/es/components/login/index.d.ts +1 -0
- package/es/components/productExtension/index.d.ts +1 -0
- package/es/components/shoppingCart/Provider.d.ts +3 -0
- package/es/components/shoppingCart/Provider.js +86 -0
- package/es/components/shoppingCart/components/Cart/Product.d.ts +3 -0
- package/es/components/shoppingCart/components/Cart/Product.js +71 -0
- package/es/components/shoppingCart/components/Cart/index.d.ts +3 -0
- package/es/components/shoppingCart/components/Cart/index.js +73 -0
- package/es/components/shoppingCart/components/Cart/index.less +68 -0
- package/es/components/shoppingCart/components/Empty/index.d.ts +4 -0
- package/es/components/shoppingCart/components/Empty/index.js +15 -0
- package/es/components/shoppingCart/components/Empty/index.less +19 -0
- package/es/components/shoppingCart/components/Render/index.d.ts +4 -0
- package/es/components/shoppingCart/components/Render/index.js +70 -0
- package/es/components/shoppingCart/components/Render/index.less +2 -0
- package/es/components/shoppingCart/components/SelectHolderModal/index.d.ts +4 -0
- package/es/components/shoppingCart/components/SelectHolderModal/index.js +132 -0
- package/es/components/shoppingCart/components/SelectHolderModal/index.less +32 -0
- package/es/components/shoppingCart/hooks/useAddService.d.ts +2 -0
- package/es/components/shoppingCart/hooks/useAddService.js +23 -0
- package/es/components/shoppingCart/hooks/useClearCart.d.ts +2 -0
- package/es/components/shoppingCart/hooks/useClearCart.js +59 -0
- package/es/components/shoppingCart/hooks/useContext.d.ts +1 -0
- package/es/components/shoppingCart/hooks/useContext.js +5 -0
- package/es/components/shoppingCart/index.d.ts +4 -0
- package/es/components/shoppingCart/index.js +24 -0
- package/es/components/shoppingCart/locales.d.ts +33 -0
- package/es/components/shoppingCart/locales.js +38 -0
- package/es/components/shoppingCart/mock.d.ts +40 -0
- package/es/components/shoppingCart/mock.js +40 -0
- package/es/components/shoppingCart/status.d.ts +2 -0
- package/es/components/shoppingCart/status.js +22 -0
- package/es/components/shoppingCart/type.d.ts +40 -0
- package/es/components/shoppingCart/type.js +1 -0
- package/es/components/shoppingCart/utils.d.ts +63 -0
- package/es/components/shoppingCart/utils.js +116 -0
- package/es/components/tabProduct/tabs/index.less +13 -3
- package/es/components/taxSelect/index.d.ts +1 -0
- package/es/components/wallet/hooks/useWalletCard.d.ts +1 -0
- package/es/components/workSpaceList/components/AppearanceEdit/IconPanel.js +1 -1
- package/es/components/workSpaceList/components/AppearanceEdit/constants.js +11 -1
- package/es/components/workSpaceList/components/Card/constants.js +2 -1
- package/es/components/workSpaceList/components/EditableString/index.js +1 -1
- package/es/components/workSpaceList/components/SearchBar/index.js +4 -1
- package/es/components/workSpaceList/components/SearchWorkspaceAndBase/index.js +1 -1
- package/es/components/workSpaceList/components/Sort/index.js +1 -1
- package/es/components/workSpaceList/components/WorkspaceItem/index.js +1 -1
- package/es/components/workSpaceList/server.d.ts +3 -3
- package/es/index.d.ts +13 -0
- package/es/index.js +14 -1
- package/lib/businessModel/SalesModel/Sales/index.d.ts +24 -0
- package/lib/businessModel/SalesModel/Sales/index.js +104 -0
- package/lib/businessModel/SalesModel/hooks/index.d.ts +1 -0
- package/lib/businessModel/SalesModel/hooks/index.js +34 -0
- package/lib/businessModel/SalesModel/index.d.ts +4 -0
- package/lib/businessModel/SalesModel/index.js +51 -0
- package/lib/businessModel/index.d.ts +0 -0
- package/lib/businessModel/index.js +0 -0
- package/lib/components/Sales/Cart/index.d.ts +53 -0
- package/lib/components/Sales/Cart/index.js +500 -0
- package/lib/components/Sales/Cart/serve.d.ts +2 -0
- package/lib/components/Sales/Cart/serve.js +37 -0
- package/lib/components/Sales/Cart/types.d.ts +19 -0
- package/lib/components/Sales/Cart/types.js +17 -0
- package/lib/components/Sales/Checkout/index.d.ts +33 -0
- package/lib/components/Sales/Checkout/index.js +130 -0
- package/lib/components/Sales/Checkout/serve.d.ts +2 -0
- package/lib/components/Sales/Checkout/serve.js +37 -0
- package/lib/components/Sales/Checkout/utils.d.ts +27 -0
- package/lib/components/Sales/Checkout/utils.js +88 -0
- package/lib/components/Sales/Customer/index.d.ts +24 -0
- package/lib/components/Sales/Customer/index.js +90 -0
- package/lib/components/Sales/Event/Detail.d.ts +27 -0
- package/lib/components/Sales/Event/Detail.js +224 -0
- package/lib/components/Sales/Event/index.d.ts +30 -0
- package/lib/components/Sales/Event/index.js +136 -0
- package/lib/components/Sales/Event/serve.d.ts +26 -0
- package/lib/components/Sales/Event/serve.js +54 -0
- package/lib/components/Sales/Holder/index.d.ts +33 -0
- package/lib/components/Sales/Holder/index.js +210 -0
- package/lib/components/Sales/Holder/serve.d.ts +8 -0
- package/lib/components/Sales/Holder/serve.js +37 -0
- package/lib/components/Sales/Init/index.d.ts +24 -0
- package/lib/components/Sales/Init/index.js +128 -0
- package/lib/components/Sales/Init/serve.d.ts +3 -0
- package/lib/components/Sales/Init/serve.js +34 -0
- package/lib/components/Sales/Resource/index.d.ts +26 -0
- package/lib/components/Sales/Resource/index.js +133 -0
- package/lib/components/Sales/Resource/serve.d.ts +5 -0
- package/lib/components/Sales/Resource/serve.js +32 -0
- package/lib/components/Sales/Step/index.d.ts +37 -0
- package/lib/components/Sales/Step/index.js +170 -0
- package/lib/components/Sales/Summary/index.d.ts +25 -0
- package/lib/components/Sales/Summary/index.js +83 -0
- package/lib/components/Sales/Summary/serve.d.ts +0 -0
- package/lib/components/Sales/Summary/serve.js +0 -0
- package/lib/components/Sales/Summary/utils.d.ts +36 -0
- package/lib/components/Sales/Summary/utils.js +80 -0
- package/lib/components/Sales/hooks/index.d.ts +1 -0
- package/lib/components/Sales/hooks/index.js +31 -0
- package/lib/components/Sales/index.d.ts +20 -0
- package/lib/components/Sales/index.js +79 -0
- package/lib/components/Sales/utils/index.d.ts +1 -0
- package/lib/components/Sales/utils/index.js +43 -0
- package/lib/components/booking/components/customSelect/index.d.ts +1 -0
- package/lib/components/booking/components/customSelect/index.js +6 -2
- package/lib/components/booking/components/footer/AppointmentProductModal/index.d.ts +3 -0
- package/lib/components/booking/components/footer/AppointmentProductModal/index.js +60 -0
- package/lib/components/booking/components/footer/AppointmentProductModal/index.less +0 -0
- package/lib/components/booking/components/footer/amount.js +27 -8
- package/lib/components/booking/components/footer/index.js +48 -55
- package/lib/components/booking/components/footer/serve.d.ts +2 -0
- package/lib/components/booking/components/footer/serve.js +12 -0
- package/lib/components/booking/components/footer/utils.js +168 -37
- package/lib/components/booking/info/Provider.d.ts +0 -0
- package/lib/components/booking/info/Provider.js +0 -0
- package/lib/components/booking/info/addServiceVariant/index.js +5 -0
- package/lib/components/booking/info/clientVariant/vertical/SelectDrawer.d.ts +1 -0
- package/lib/components/booking/info/clientVariant/vertical/SelectDrawer.js +8 -7
- package/lib/components/booking/info/clientVariant/vertical/index.js +96 -20
- package/lib/components/booking/info/dateRange/index.d.ts +4 -0
- package/lib/components/booking/info/dateRange/index.js +111 -0
- package/lib/components/booking/info/dateRange/index.less +21 -0
- package/lib/components/booking/info/main.js +33 -22
- package/lib/components/booking/info/model.js +3 -0
- package/lib/components/booking/info/pet/ChangePetModal/index.d.ts +4 -0
- package/lib/components/booking/info/pet/ChangePetModal/index.js +121 -0
- package/lib/components/booking/info/pet/ChangePetModal/index.less +4 -0
- package/lib/components/booking/info/pet/index.d.ts +1 -1
- package/lib/components/booking/info/pet/index.js +90 -44
- package/lib/components/booking/info/service/addService/index.d.ts +0 -1
- package/lib/components/booking/info/service/addService/index.js +131 -101
- package/lib/components/booking/info/service/addService/index.less +13 -3
- package/lib/components/booking/info/service/addService/utils.d.ts +12 -2
- package/lib/components/booking/info/service/addService/utils.js +57 -10
- package/lib/components/booking/info/service/addTimeModal/index.d.ts +0 -1
- package/lib/components/booking/info/service/editService/BookingList/index.d.ts +4 -0
- package/lib/components/booking/info/service/editService/BookingList/index.js +55 -0
- package/lib/components/booking/info/service/editService/EditTabs/index.d.ts +3 -0
- package/lib/components/booking/info/service/editService/EditTabs/index.js +75 -0
- package/lib/components/booking/info/service/editService/index.js +446 -197
- package/lib/components/booking/info/service/editService/index.less +18 -13
- package/lib/components/booking/info/service/serve.d.ts +10 -0
- package/lib/components/booking/info/service/serve.js +7 -2
- package/lib/components/booking/info/service/serviceManager/distributeDiscount.d.ts +11 -0
- package/lib/components/booking/info/service/serviceManager/distributeDiscount.js +70 -0
- package/lib/components/booking/info/service/serviceManager/index.d.ts +20 -0
- package/lib/components/booking/info/service/serviceManager/index.js +211 -0
- package/lib/components/booking/info/service/serviceManager/utils.d.ts +0 -0
- package/lib/components/booking/info/service/serviceManager/utils.js +0 -0
- package/lib/components/booking/info/service2/Group/utils.d.ts +14 -0
- package/lib/components/booking/info/service2/Group/utils.js +142 -0
- package/lib/components/booking/info/service2/Lists.d.ts +3 -0
- package/lib/components/booking/info/service2/Lists.js +116 -0
- package/lib/components/booking/info/service2/hooks/useSelectPet.d.ts +6 -0
- package/lib/components/booking/info/service2/hooks/useSelectPet.js +49 -0
- package/lib/components/booking/info/service2/index.d.ts +6 -0
- package/lib/components/booking/info/service2/index.js +75 -0
- package/lib/components/booking/info/service2/status.d.ts +31 -0
- package/lib/components/booking/info/service2/status.js +81 -0
- package/lib/components/booking/info/service2/utils.d.ts +240 -0
- package/lib/components/booking/info/service2/utils.js +686 -0
- package/lib/components/booking/info/utils.d.ts +20 -0
- package/lib/components/booking/info/utils.js +42 -1
- package/lib/components/booking/locales.d.ts +66 -0
- package/lib/components/booking/locales.js +69 -3
- package/lib/components/booking/materiels/contacts/index.d.ts +1 -0
- package/lib/components/booking/materiels/holder/index.d.ts +7 -0
- package/lib/components/booking/materiels/holder/index.js +64 -0
- package/lib/components/booking/model.d.ts +5 -1
- package/lib/components/booking/model.js +4 -2
- package/lib/components/booking/utils.d.ts +12 -3
- package/lib/components/booking/utils.js +89 -18
- package/lib/components/eftpos/hooks.d.ts +4 -4
- package/lib/components/eftpos/index.d.ts +1 -0
- 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/unknow.d.ts +0 -1
- package/lib/components/eftposPay/component/step/index.d.ts +6 -6
- package/lib/components/eftposPay/component/step/step.d.ts +4 -4
- package/lib/components/eftposPay/hooks.d.ts +1 -1
- package/lib/components/eftposPay/pay.d.ts +0 -1
- package/lib/components/eftposPay/tyro/hooks.d.ts +2 -2
- package/lib/components/eftposPay/windcave/helper.d.ts +1 -1
- package/lib/components/eventBooking/assets/alert-circle.png +0 -0
- package/lib/components/eventBooking/assets/calendar-heart.svg +5 -0
- package/lib/components/eventBooking/assets/compass.svg +13 -0
- package/lib/components/eventBooking/assets/image.svg +5 -0
- package/lib/components/eventBooking/assets/phone.svg +5 -0
- package/lib/components/eventBooking/assets/shopping-cart.svg +10 -0
- package/lib/components/eventBooking/components/ErrorTip/index.d.ts +3 -0
- package/lib/components/eventBooking/components/ErrorTip/index.js +30 -0
- package/lib/components/eventBooking/components/ErrorTip/index.less +51 -0
- package/lib/components/eventBooking/components/OpenCard/index.d.ts +4 -0
- package/lib/components/eventBooking/components/OpenCard/index.js +90 -0
- package/lib/components/eventBooking/components/OpenCard/index.less +52 -0
- package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +158 -0
- package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.less +0 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/Total.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/Total.js +82 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/index.js +92 -0
- package/lib/components/eventBooking/components/Provider/Cart/Item/index.less +87 -0
- package/lib/components/eventBooking/components/Provider/Cart/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Cart/index.js +59 -0
- package/lib/components/eventBooking/components/Provider/Cart/index.less +2 -0
- package/lib/components/eventBooking/components/Provider/Content/index.d.ts +4 -0
- package/lib/components/eventBooking/components/Provider/Content/index.js +90 -0
- package/lib/components/eventBooking/components/Provider/Content/index.less +31 -0
- package/lib/components/eventBooking/components/Provider/EmptyHolderModal/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/EmptyHolderModal/index.js +60 -0
- package/lib/components/eventBooking/components/Provider/EmptyHolderModal/index.less +17 -0
- package/lib/components/eventBooking/components/Provider/Event/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Event/index.js +100 -0
- package/lib/components/eventBooking/components/Provider/Event/index.less +20 -0
- package/lib/components/eventBooking/components/Provider/Footer/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Footer/index.js +87 -0
- package/lib/components/eventBooking/components/Provider/Footer/index.less +64 -0
- package/lib/components/eventBooking/components/Provider/Header/index.d.ts +4 -0
- package/lib/components/eventBooking/components/Provider/Header/index.js +80 -0
- package/lib/components/eventBooking/components/Provider/Header/index.less +2 -0
- package/lib/components/eventBooking/components/Provider/Information/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Information/index.js +151 -0
- package/lib/components/eventBooking/components/Provider/Information/index.less +92 -0
- package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.js +67 -0
- package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.less +27 -0
- package/lib/components/eventBooking/components/Provider/OrderProductModal/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/OrderProductModal/index.js +57 -0
- package/lib/components/eventBooking/components/Provider/OrderProductModal/index.less +32 -0
- package/lib/components/eventBooking/components/Provider/RemoveOptionConfirmModal.d.ts +2 -0
- package/lib/components/eventBooking/components/Provider/RemoveOptionConfirmModal.js +62 -0
- package/lib/components/eventBooking/components/Provider/Resource/index.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/Resource/index.js +90 -0
- package/lib/components/eventBooking/components/Provider/Resource/index.less +46 -0
- package/lib/components/eventBooking/components/Provider/SelectHolderModal.d.ts +3 -0
- package/lib/components/eventBooking/components/Provider/SelectHolderModal.js +97 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +4 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.js +55 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.less +25 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +10 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.js +78 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.less +32 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +3 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.js +86 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.less +12 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +12 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.js +121 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.less +35 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +4 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.js +37 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.less +28 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +5 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.js +58 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.less +87 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +4 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.js +55 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.less +25 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/index.d.ts +4 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/index.js +196 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/index.less +119 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/state.d.ts +63 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/state.js +198 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.d.ts +4 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.js +122 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.less +4 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/index.d.ts +14 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/index.js +70 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/index.less +2 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/utils.d.ts +34 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/utils.js +70 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/BookingOptions.d.ts +2 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/BookingOptions.js +75 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Resource.d.ts +3 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Resource.js +66 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +3 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.js +69 -0
- package/lib/components/eventBooking/components/bookingDetailModal/index.d.ts +7 -0
- package/lib/components/eventBooking/components/bookingDetailModal/index.js +248 -0
- package/lib/components/eventBooking/components/bookingDetailModal/index.less +82 -0
- package/lib/components/eventBooking/components/bookingServiceList/index.d.ts +17 -0
- package/lib/components/eventBooking/components/bookingServiceList/index.js +79 -0
- package/lib/components/eventBooking/components/bookingServiceList/index.less +6 -0
- package/lib/components/eventBooking/components/eventCard/index.d.ts +14 -0
- package/lib/components/eventBooking/components/eventCard/index.js +124 -0
- package/lib/components/eventBooking/components/eventCard/index.less +81 -0
- package/lib/components/eventBooking/components/productCard/index.d.ts +16 -0
- package/lib/components/eventBooking/components/productCard/index.js +77 -0
- package/lib/components/eventBooking/components/productCard/index.less +60 -0
- package/lib/components/eventBooking/components/progressBar/index.d.ts +16 -0
- package/lib/components/eventBooking/components/progressBar/index.js +100 -0
- package/lib/components/eventBooking/components/progressBar/index.less +15 -0
- package/lib/components/eventBooking/components/resourceDisplay/index.d.ts +23 -0
- package/lib/components/eventBooking/components/resourceDisplay/index.js +116 -0
- package/lib/components/eventBooking/components/resourceDisplay/index.less +95 -0
- package/lib/components/eventBooking/components/resourceUsability/index.d.ts +12 -0
- package/lib/components/eventBooking/components/resourceUsability/index.js +76 -0
- package/lib/components/eventBooking/components/resourceUsability/index.less +40 -0
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +10 -0
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.js +73 -0
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.less +58 -0
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +11 -0
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.js +135 -0
- package/lib/components/eventBooking/components/scheduleCalendar/index.d.ts +13 -0
- package/lib/components/eventBooking/components/scheduleCalendar/index.js +125 -0
- package/lib/components/eventBooking/components/scheduleCalendar/index.less +222 -0
- package/lib/components/eventBooking/components/selectHolder/index.d.ts +22 -0
- package/lib/components/eventBooking/components/selectHolder/index.js +106 -0
- package/lib/components/eventBooking/components/selectHolder/index.less +70 -0
- package/lib/components/eventBooking/components/timeResourceSelector/index.d.ts +20 -0
- package/lib/components/eventBooking/components/timeResourceSelector/index.js +146 -0
- package/lib/components/eventBooking/components/timeResourceSelector/index.less +74 -0
- package/lib/components/eventBooking/index.d.ts +4 -0
- package/lib/components/eventBooking/index.js +78 -0
- package/lib/components/eventBooking/index.less +22 -0
- package/lib/components/eventBooking/locales.d.ts +216 -0
- package/lib/components/eventBooking/locales.js +239 -0
- package/lib/components/eventBooking/mock.d.ts +627 -0
- package/lib/components/eventBooking/mock.js +1352 -0
- package/lib/components/eventBooking/status.d.ts +21 -0
- package/lib/components/eventBooking/status.js +70 -0
- package/lib/components/eventBooking/type.d.ts +17 -0
- package/lib/components/eventBooking/type.js +17 -0
- package/lib/components/eventBooking/utils.d.ts +45 -0
- package/lib/components/eventBooking/utils.js +90 -0
- package/lib/components/login/index.d.ts +1 -0
- package/lib/components/productExtension/index.d.ts +1 -0
- package/lib/components/shoppingCart/Provider.d.ts +3 -0
- package/lib/components/shoppingCart/Provider.js +110 -0
- package/lib/components/shoppingCart/components/Cart/Product.d.ts +3 -0
- package/lib/components/shoppingCart/components/Cart/Product.js +72 -0
- package/lib/components/shoppingCart/components/Cart/index.d.ts +3 -0
- package/lib/components/shoppingCart/components/Cart/index.js +85 -0
- package/lib/components/shoppingCart/components/Cart/index.less +68 -0
- package/lib/components/shoppingCart/components/Empty/index.d.ts +4 -0
- package/lib/components/shoppingCart/components/Empty/index.js +43 -0
- package/lib/components/shoppingCart/components/Empty/index.less +19 -0
- package/lib/components/shoppingCart/components/Render/index.d.ts +4 -0
- package/lib/components/shoppingCart/components/Render/index.js +75 -0
- package/lib/components/shoppingCart/components/Render/index.less +2 -0
- package/lib/components/shoppingCart/components/SelectHolderModal/index.d.ts +4 -0
- package/lib/components/shoppingCart/components/SelectHolderModal/index.js +124 -0
- package/lib/components/shoppingCart/components/SelectHolderModal/index.less +32 -0
- package/lib/components/shoppingCart/hooks/useAddService.d.ts +2 -0
- package/lib/components/shoppingCart/hooks/useAddService.js +55 -0
- package/lib/components/shoppingCart/hooks/useClearCart.d.ts +2 -0
- package/lib/components/shoppingCart/hooks/useClearCart.js +66 -0
- package/lib/components/shoppingCart/hooks/useContext.d.ts +1 -0
- package/lib/components/shoppingCart/hooks/useContext.js +31 -0
- package/lib/components/shoppingCart/index.d.ts +4 -0
- package/lib/components/shoppingCart/index.js +60 -0
- package/lib/components/shoppingCart/locales.d.ts +33 -0
- package/lib/components/shoppingCart/locales.js +56 -0
- package/lib/components/shoppingCart/mock.d.ts +40 -0
- package/lib/components/shoppingCart/mock.js +76 -0
- package/lib/components/shoppingCart/status.d.ts +2 -0
- package/lib/components/shoppingCart/status.js +60 -0
- package/lib/components/shoppingCart/type.d.ts +40 -0
- package/lib/components/shoppingCart/type.js +17 -0
- package/lib/components/shoppingCart/utils.d.ts +63 -0
- package/lib/components/shoppingCart/utils.js +83 -0
- package/lib/components/tabProduct/tabs/index.less +13 -3
- package/lib/components/taxSelect/index.d.ts +1 -0
- package/lib/components/wallet/hooks/useWalletCard.d.ts +1 -0
- package/lib/components/workSpaceList/components/AppearanceEdit/IconPanel.js +2 -2
- package/lib/components/workSpaceList/components/AppearanceEdit/constants.js +32 -12
- package/lib/components/workSpaceList/components/Card/constants.js +4 -3
- package/lib/components/workSpaceList/components/EditableString/index.js +2 -2
- package/lib/components/workSpaceList/components/SearchBar/index.js +8 -5
- package/lib/components/workSpaceList/components/SearchWorkspaceAndBase/index.js +2 -2
- package/lib/components/workSpaceList/components/Sort/index.js +2 -2
- package/lib/components/workSpaceList/components/WorkspaceItem/index.js +2 -2
- package/lib/components/workSpaceList/server.d.ts +3 -3
- package/lib/index.d.ts +13 -0
- package/lib/index.js +39 -0
- package/lowcode/event-booking/meta.ts +69 -0
- package/lowcode/event-booking-availability-calendar/meta.ts +53 -0
- package/lowcode/event-booking-detail-modal/meta.ts +39 -0
- package/lowcode/event-booking-service-list/meta.ts +77 -0
- package/lowcode/event-card/meta.ts +77 -0
- package/lowcode/event-product-card/meta.ts +79 -0
- package/lowcode/event-progress-bar/meta.ts +65 -0
- package/lowcode/event-resource-display/meta.ts +169 -0
- package/lowcode/event-resource-usability/meta.ts +67 -0
- package/lowcode/event-schedule-calendar/meta.ts +56 -0
- package/lowcode/event-select-holder/meta.ts +84 -0
- package/lowcode/event-time-resource-selector/meta.ts +69 -0
- package/lowcode/shopping-cart/meta.ts +98 -0
- package/package.json +4 -4
@@ -0,0 +1,686 @@
|
|
1
|
+
var __create = Object.create;
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
7
|
+
var __export = (target, all) => {
|
8
|
+
for (var name in all)
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
10
|
+
};
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
13
|
+
for (let key of __getOwnPropNames(from))
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
16
|
+
}
|
17
|
+
return to;
|
18
|
+
};
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
20
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
21
|
+
// file that has been converted to a CommonJS file using a Babel-
|
22
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
23
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
24
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
25
|
+
mod
|
26
|
+
));
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
28
|
+
|
29
|
+
// src/components/booking/info/service2/utils.ts
|
30
|
+
var utils_exports = {};
|
31
|
+
__export(utils_exports, {
|
32
|
+
disabledDate: () => disabledDate,
|
33
|
+
formItems: () => formItems,
|
34
|
+
formatActiveKey: () => formatActiveKey,
|
35
|
+
formatDateTime: () => formatDateTime,
|
36
|
+
formatDayDate: () => formatDayDate,
|
37
|
+
formatDayTime: () => formatDayTime,
|
38
|
+
formatHolderLists: () => formatHolderLists,
|
39
|
+
formatProducts: () => formatProducts,
|
40
|
+
getAppointmentService: () => getAppointmentService,
|
41
|
+
getDayProducts: () => getDayProducts,
|
42
|
+
getErrorMessage: () => getErrorMessage,
|
43
|
+
getPets: () => getPets,
|
44
|
+
getResourceItem: () => getResourceItem,
|
45
|
+
holderId: () => holderId,
|
46
|
+
initDate: () => initDate,
|
47
|
+
isAppointmentProduct: () => isAppointmentProduct,
|
48
|
+
isBookingProduct: () => isBookingProduct,
|
49
|
+
isDayBooking: () => isDayBooking,
|
50
|
+
isDayBookingProduct: () => isDayBookingProduct,
|
51
|
+
isDaysBooking: () => isDaysBooking,
|
52
|
+
isEventBooking: () => isEventBooking,
|
53
|
+
isHasDayAppointmentProduct: () => isHasDayAppointmentProduct,
|
54
|
+
isOpenDeletePet: () => isOpenDeletePet,
|
55
|
+
isTerminalDayBooking: () => isTerminalDayBooking,
|
56
|
+
updateAppointmentServicePrice: () => updateAppointmentServicePrice,
|
57
|
+
updateNormalBundlePrice: () => updateNormalBundlePrice,
|
58
|
+
updateServicePrice: () => updateServicePrice,
|
59
|
+
updateServices: () => updateServices
|
60
|
+
});
|
61
|
+
module.exports = __toCommonJS(utils_exports);
|
62
|
+
var import_mock = require("../../mock");
|
63
|
+
var import_utils = require("../../utils");
|
64
|
+
var import_utils2 = require("@pisell/utils");
|
65
|
+
var import_dayjs = __toESM(require("dayjs"));
|
66
|
+
var import_status = require("./status");
|
67
|
+
var import_serve = require("../service/serve");
|
68
|
+
var import_locales = __toESM(require("../../locales"));
|
69
|
+
var import_utils3 = require("./Group/utils");
|
70
|
+
import_utils2.locales.init(import_locales.default, localStorage.getItem("umi_locale") || "en");
|
71
|
+
var formatActiveKey = (lists, platform, isEdit) => {
|
72
|
+
var _a;
|
73
|
+
if (!(lists == null ? void 0 : lists.length)) return [];
|
74
|
+
if (lists.length === 1 && isEdit) {
|
75
|
+
return [];
|
76
|
+
}
|
77
|
+
if (platform === "shop") {
|
78
|
+
return [(_a = lists[lists.length - 1]) == null ? void 0 : _a.key];
|
79
|
+
}
|
80
|
+
return lists == null ? void 0 : lists.map((cart) => cart == null ? void 0 : cart.key);
|
81
|
+
};
|
82
|
+
var getResourceItem = (id, state) => {
|
83
|
+
var _a;
|
84
|
+
if (id === 0) {
|
85
|
+
return (0, import_mock.getNoResource)();
|
86
|
+
}
|
87
|
+
return (_a = state.service.resources) == null ? void 0 : _a.find((d) => d.form_record_id === id);
|
88
|
+
};
|
89
|
+
var errorTypes = {
|
90
|
+
product: import_utils2.locales.getText("pisell2.text.status.service-error-1"),
|
91
|
+
time: import_utils2.locales.getText("pisell2.text.status.service-error-2"),
|
92
|
+
maxLimit: import_utils2.locales.getText("pisell2.text.status.service-error-3"),
|
93
|
+
limit: import_utils2.locales.getText("pisell2.text.status.service-error-3")
|
94
|
+
};
|
95
|
+
var getErrorMessage = (service, resourceItem, isDay) => {
|
96
|
+
const errorList = (0, import_utils.getErrorList)(resourceItem, service, isDay);
|
97
|
+
let errorMessage = "";
|
98
|
+
if (!service.id) {
|
99
|
+
return errorList[0].label;
|
100
|
+
}
|
101
|
+
if (errorList.length) {
|
102
|
+
if (errorList.length > 1) {
|
103
|
+
errorMessage = `${errorList.length} ${import_utils2.locales.getText(
|
104
|
+
"pisell2.text.warnings"
|
105
|
+
)}`;
|
106
|
+
} else {
|
107
|
+
errorMessage = (resourceItem == null ? void 0 : resourceItem.labelText) + " " + errorTypes[errorList[0].type];
|
108
|
+
}
|
109
|
+
}
|
110
|
+
return errorMessage;
|
111
|
+
};
|
112
|
+
var formatHolderLists = (lists) => {
|
113
|
+
const isOpenGroup = true;
|
114
|
+
const _lists = lists == null ? void 0 : lists.map((item) => {
|
115
|
+
return {
|
116
|
+
...item,
|
117
|
+
id: (item == null ? void 0 : item.id) || (item == null ? void 0 : item.form_record_id),
|
118
|
+
key: (item == null ? void 0 : item.id) || (item == null ? void 0 : item.form_record_id),
|
119
|
+
label: import_utils2.locales.getText("pisell2.text.cart.of")(item == null ? void 0 : item.main_field)
|
120
|
+
};
|
121
|
+
});
|
122
|
+
if (isOpenGroup) {
|
123
|
+
const defaults = [
|
124
|
+
{
|
125
|
+
key: 0,
|
126
|
+
id: 0,
|
127
|
+
label: import_utils2.locales.getText("pisell2.text.open.items"),
|
128
|
+
main_field: import_utils2.locales.getText("pisell2.text.open.items")
|
129
|
+
}
|
130
|
+
];
|
131
|
+
return defaults.concat(_lists);
|
132
|
+
}
|
133
|
+
return _lists;
|
134
|
+
};
|
135
|
+
var getHolderLists = (state) => {
|
136
|
+
var _a, _b, _c, _d, _e, _f;
|
137
|
+
const form_id = ((_d = (_c = (_b = (_a = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _a.config) == null ? void 0 : _b.basic) == null ? void 0 : _c.appointment_subject) == null ? void 0 : _d.form_id) || 0;
|
138
|
+
const petLists = ((_f = (_e = state == null ? void 0 : state.pet) == null ? void 0 : _e.value) == null ? void 0 : _f[form_id]) || [];
|
139
|
+
const _lists = formatHolderLists(petLists);
|
140
|
+
return _lists;
|
141
|
+
};
|
142
|
+
var getHolderName = (state, id) => {
|
143
|
+
const holderLists = getHolderLists(state);
|
144
|
+
if (!holderLists.length || !id) return "";
|
145
|
+
const resource = holderLists.find((d) => (d == null ? void 0 : d.id) === id);
|
146
|
+
return resource == null ? void 0 : resource.main_field;
|
147
|
+
};
|
148
|
+
var isBookingProduct = (extension_type, bol) => {
|
149
|
+
return import_status.appointmentTypes.includes(extension_type) || bol;
|
150
|
+
};
|
151
|
+
var isDayBookingProduct = (item, state) => {
|
152
|
+
return isBookingProduct(item == null ? void 0 : item.extension_type) && state.renderType === "dayBooking";
|
153
|
+
};
|
154
|
+
var updateServices = (state, currentItem, type, other) => {
|
155
|
+
var _a;
|
156
|
+
let products = ((_a = state == null ? void 0 : state.service) == null ? void 0 : _a.value) || [];
|
157
|
+
const isGroup = (0, import_utils3.isGroupBooking)(currentItem._id);
|
158
|
+
if (type === "delete") {
|
159
|
+
let deleteIds = [];
|
160
|
+
if (isGroup) {
|
161
|
+
deleteIds = (0, import_utils3.getProductByGroupId)(currentItem._id, products);
|
162
|
+
} else {
|
163
|
+
deleteIds = [currentItem._id];
|
164
|
+
}
|
165
|
+
products = products == null ? void 0 : products.filter((item) => !deleteIds.includes(item == null ? void 0 : item._id));
|
166
|
+
}
|
167
|
+
if (type === "delete_holders") {
|
168
|
+
products = products == null ? void 0 : products.filter((item) => {
|
169
|
+
var _a2;
|
170
|
+
return ((_a2 = item == null ? void 0 : item._extend) == null ? void 0 : _a2.holder_id) !== other;
|
171
|
+
});
|
172
|
+
}
|
173
|
+
if (type === "update_holders") {
|
174
|
+
products = products == null ? void 0 : products.map((item) => {
|
175
|
+
var _a2;
|
176
|
+
const ids = currentItem.map((d) => d._id);
|
177
|
+
if (ids == null ? void 0 : ids.includes(item == null ? void 0 : item._id)) {
|
178
|
+
let _extend = item._extend || {};
|
179
|
+
if (Array.isArray(other)) {
|
180
|
+
_extend.holder_id = (_a2 = other.find((other2) => (other2 == null ? void 0 : other2._id) === (item == null ? void 0 : item._id))) == null ? void 0 : _a2.holder_id;
|
181
|
+
} else {
|
182
|
+
_extend.holder_id = other;
|
183
|
+
}
|
184
|
+
return item;
|
185
|
+
}
|
186
|
+
return item;
|
187
|
+
});
|
188
|
+
} else {
|
189
|
+
products = products == null ? void 0 : products.map((item) => {
|
190
|
+
let updateIds = [];
|
191
|
+
if (isGroup) {
|
192
|
+
updateIds = (0, import_utils3.getProductByGroupId)(currentItem._id, products);
|
193
|
+
} else {
|
194
|
+
updateIds = [currentItem._id];
|
195
|
+
}
|
196
|
+
if (updateIds.includes(item._id)) {
|
197
|
+
if (type === "like") {
|
198
|
+
let _extend = item._extend || {};
|
199
|
+
_extend.like_status = other == null ? void 0 : other.like_status;
|
200
|
+
} else {
|
201
|
+
item = {
|
202
|
+
...item,
|
203
|
+
...other
|
204
|
+
};
|
205
|
+
}
|
206
|
+
return item;
|
207
|
+
}
|
208
|
+
return item;
|
209
|
+
});
|
210
|
+
}
|
211
|
+
return products;
|
212
|
+
};
|
213
|
+
var formatBundle = (bundle) => {
|
214
|
+
if (!(bundle == null ? void 0 : bundle.length)) return [];
|
215
|
+
return bundle.map((item) => {
|
216
|
+
return {
|
217
|
+
id: item == null ? void 0 : item.id,
|
218
|
+
title: item == null ? void 0 : item.title,
|
219
|
+
num: item == null ? void 0 : item.num,
|
220
|
+
price: item == null ? void 0 : item.price,
|
221
|
+
total: item == null ? void 0 : item.price,
|
222
|
+
price_type: item == null ? void 0 : item.price_type,
|
223
|
+
bundle_sum_price: item == null ? void 0 : item.bundle_sum_price,
|
224
|
+
bundle_sum_type: item == null ? void 0 : item.bundle_sum_type,
|
225
|
+
options: formatOptions(item == null ? void 0 : item.option)
|
226
|
+
};
|
227
|
+
});
|
228
|
+
};
|
229
|
+
var formatOptions = (options) => {
|
230
|
+
if (!(options == null ? void 0 : options.length)) return [];
|
231
|
+
return options.map((item) => {
|
232
|
+
return {
|
233
|
+
id: item == null ? void 0 : item.id,
|
234
|
+
name: item == null ? void 0 : item.name,
|
235
|
+
num: item == null ? void 0 : item.num,
|
236
|
+
price: item == null ? void 0 : item.price,
|
237
|
+
total: item == null ? void 0 : item.price,
|
238
|
+
origin_total: item == null ? void 0 : item.original_price
|
239
|
+
};
|
240
|
+
});
|
241
|
+
};
|
242
|
+
var formItems = (items) => {
|
243
|
+
return items.map((d) => {
|
244
|
+
return {
|
245
|
+
...d,
|
246
|
+
start_date: d._extend.start_date,
|
247
|
+
end_date: d._extend.end_date,
|
248
|
+
num: d == null ? void 0 : d._extend.quantity,
|
249
|
+
total: d._extend.total,
|
250
|
+
origin_total: d._extend.origin_total
|
251
|
+
};
|
252
|
+
});
|
253
|
+
};
|
254
|
+
var formatProducts = (lists, state, isRenderGroup = true) => {
|
255
|
+
if (!(lists == null ? void 0 : lists.length)) return [];
|
256
|
+
const normalList = [];
|
257
|
+
const groupList = [];
|
258
|
+
const formItem = (item) => {
|
259
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
|
260
|
+
const _isDayBookingProduct = isDayBookingProduct(item, state);
|
261
|
+
const clientTitle = getHolderName(state, (_a = item == null ? void 0 : item._extend) == null ? void 0 : _a.holder_id);
|
262
|
+
const options = formatOptions((_c = (_b = item == null ? void 0 : item._extend) == null ? void 0 : _b.other) == null ? void 0 : _c.option);
|
263
|
+
const bundle = formatBundle((_e = (_d = item == null ? void 0 : item._extend) == null ? void 0 : _d.other) == null ? void 0 : _e.bundle);
|
264
|
+
const isNormalProduct = !import_status.appointmentTypes.includes(item == null ? void 0 : item.extension_type) || (state == null ? void 0 : state.renderType) === "eventBooking";
|
265
|
+
let resourceItem = {};
|
266
|
+
let errorMessage = "";
|
267
|
+
if (_isDayBookingProduct) {
|
268
|
+
resourceItem = getResourceItem((_f = item == null ? void 0 : item._extend) == null ? void 0 : _f.resource, state);
|
269
|
+
errorMessage = getErrorMessage(item, resourceItem, isDayBooking(state));
|
270
|
+
}
|
271
|
+
return {
|
272
|
+
id: item == null ? void 0 : item.id,
|
273
|
+
_id: item == null ? void 0 : item._id,
|
274
|
+
name: item == null ? void 0 : item.title,
|
275
|
+
price: (_g = item == null ? void 0 : item._extend) == null ? void 0 : _g.price,
|
276
|
+
total: (_h = item == null ? void 0 : item._extend) == null ? void 0 : _h.total,
|
277
|
+
origin_total: (_i = item == null ? void 0 : item._extend) == null ? void 0 : _i.origin_total,
|
278
|
+
num: item == null ? void 0 : item._extend.quantity,
|
279
|
+
image: item == null ? void 0 : item.cover,
|
280
|
+
isShowNote: true,
|
281
|
+
note: item == null ? void 0 : item.note,
|
282
|
+
like_status: (_j = item == null ? void 0 : item._extend) == null ? void 0 : _j.like_status,
|
283
|
+
bundle,
|
284
|
+
options,
|
285
|
+
errorMessage,
|
286
|
+
product_option_string: (_l = (_k = item == null ? void 0 : item._extend) == null ? void 0 : _k.other) == null ? void 0 : _l.product_option_string,
|
287
|
+
discount_reason: (_m = item == null ? void 0 : item._extend) == null ? void 0 : _m.discount_reason,
|
288
|
+
resource_id: isNormalProduct ? 0 : (_n = item == null ? void 0 : item._extend) == null ? void 0 : _n.resource,
|
289
|
+
relation_form_name: isNormalProduct ? "" : (resourceItem == null ? void 0 : resourceItem.labelText) || item.relation_form_name,
|
290
|
+
holder_title: clientTitle,
|
291
|
+
start_date: !isNormalProduct ? (_o = item == null ? void 0 : item._extend) == null ? void 0 : _o.start_date : "",
|
292
|
+
end_date: !isNormalProduct ? (_p = item == null ? void 0 : item._extend) == null ? void 0 : _p.end_date : "",
|
293
|
+
holder_id: ((_q = item == null ? void 0 : item._extend) == null ? void 0 : _q.holder_id) || 0,
|
294
|
+
isNormalProduct,
|
295
|
+
locale: state.locale,
|
296
|
+
symbol: state.amountSymbol,
|
297
|
+
items: isEventBooking(state) ? [] : formItems(((_r = item == null ? void 0 : item._extend) == null ? void 0 : _r.items) || []),
|
298
|
+
_origin: item
|
299
|
+
};
|
300
|
+
};
|
301
|
+
lists.forEach((item) => {
|
302
|
+
var _a;
|
303
|
+
if (!((_a = item == null ? void 0 : item._extend) == null ? void 0 : _a.groupId)) {
|
304
|
+
normalList.push(formItem(item));
|
305
|
+
} else {
|
306
|
+
groupList.push(item);
|
307
|
+
}
|
308
|
+
});
|
309
|
+
let groups = groupList.reduce((prev, item) => {
|
310
|
+
var _a;
|
311
|
+
const groupId = (_a = item == null ? void 0 : item._extend) == null ? void 0 : _a.groupId;
|
312
|
+
if (!prev[groupId]) {
|
313
|
+
prev[groupId] = [];
|
314
|
+
}
|
315
|
+
prev[groupId].push(item);
|
316
|
+
return prev;
|
317
|
+
}, {});
|
318
|
+
if (isRenderGroup) {
|
319
|
+
return Object.values(groups).map((d) => formItem((0, import_utils3.concatBookings)(d))).concat(normalList);
|
320
|
+
} else {
|
321
|
+
return lists == null ? void 0 : lists.map((item) => formItem(item));
|
322
|
+
}
|
323
|
+
};
|
324
|
+
var disabledDate = (current, position, currentDate) => {
|
325
|
+
if (!(0, import_dayjs.default)(currentDate).isValid()) return;
|
326
|
+
if (position === "start") {
|
327
|
+
return false;
|
328
|
+
}
|
329
|
+
if (position === "end" && current.endOf("day") && currentDate) {
|
330
|
+
const endDisabled = currentDate.add(8, "months").format("YYYY-MM-DD");
|
331
|
+
return (0, import_dayjs.default)(endDisabled) < current.startOf("day") || current.startOf("day") <= currentDate;
|
332
|
+
}
|
333
|
+
return current && current <= currentDate;
|
334
|
+
};
|
335
|
+
var isDayBooking = (state) => {
|
336
|
+
return (state == null ? void 0 : state.renderType) === "dayBooking" || (state == null ? void 0 : state.renderType) === "eventBooking";
|
337
|
+
};
|
338
|
+
var isDaysBooking = (state) => {
|
339
|
+
return (state == null ? void 0 : state.renderType) === "dayBooking";
|
340
|
+
};
|
341
|
+
var isEventBooking = (state) => {
|
342
|
+
return state.renderType === "eventBooking";
|
343
|
+
};
|
344
|
+
var isAppointmentProduct = (item) => {
|
345
|
+
return import_status.appointmentTypes.includes(item.extension_type);
|
346
|
+
};
|
347
|
+
var isTerminalDayBooking = (state) => {
|
348
|
+
return state.isTerminalDayBookingPage;
|
349
|
+
};
|
350
|
+
var formatDayDate = (_extend) => {
|
351
|
+
let startDate = (0, import_dayjs.default)(_extend == null ? void 0 : _extend.start_date).startOf("day");
|
352
|
+
let endDate = (0, import_dayjs.default)(_extend == null ? void 0 : _extend.end_date).startOf("day");
|
353
|
+
return {
|
354
|
+
..._extend,
|
355
|
+
start_date: startDate,
|
356
|
+
end_date: endDate
|
357
|
+
};
|
358
|
+
};
|
359
|
+
var formatDayTime = ({ startDate, endDate }) => {
|
360
|
+
const shopOpeningTime = localStorage.getItem("shopOpeningHours") || "00:00";
|
361
|
+
let start_date = (0, import_dayjs.default)(startDate).format("YYYY-MM-DD");
|
362
|
+
let end_date = (0, import_dayjs.default)(endDate).format("YYYY-MM-DD");
|
363
|
+
const result = {
|
364
|
+
startDateTime: (0, import_dayjs.default)(`${start_date}T${shopOpeningTime}:00`),
|
365
|
+
// 结束日期根据营业日时间减去一分钟
|
366
|
+
endDateTime: (0, import_dayjs.default)(`${end_date}T${shopOpeningTime}:00`).subtract(1, "minute")
|
367
|
+
};
|
368
|
+
return result;
|
369
|
+
};
|
370
|
+
var formatDateTime = (start_date, end_date) => {
|
371
|
+
const _openingTime = (0, import_status.openingTime)();
|
372
|
+
const startDate = `${start_date} ${_openingTime}`;
|
373
|
+
let endDate = `${end_date} ${_openingTime}`;
|
374
|
+
const date = {
|
375
|
+
value: (0, import_dayjs.default)(startDate),
|
376
|
+
end_date: (0, import_dayjs.default)(endDate).subtract(1, "minute")
|
377
|
+
};
|
378
|
+
return date;
|
379
|
+
};
|
380
|
+
var initDate = () => {
|
381
|
+
const startDate = (0, import_dayjs.default)().format("YYYY-MM-DD");
|
382
|
+
let endDate = (0, import_dayjs.default)().add(1, "days").format("YYYY-MM-DD");
|
383
|
+
const date = formatDateTime(startDate, endDate);
|
384
|
+
return date;
|
385
|
+
};
|
386
|
+
var isHasDayAppointmentProduct = (state) => {
|
387
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
388
|
+
const form_id = ((_d = (_c = (_b = (_a = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _a.config) == null ? void 0 : _b.basic) == null ? void 0 : _c.appointment_subject) == null ? void 0 : _d.form_id) || 0;
|
389
|
+
const services = ((_e = state.service) == null ? void 0 : _e.value) || [];
|
390
|
+
const pets = ((_g = (_f = state.pet) == null ? void 0 : _f.value) == null ? void 0 : _g[form_id]) || [];
|
391
|
+
if (!pets.length) return true;
|
392
|
+
const checkType = (extension_type) => {
|
393
|
+
if (isEventBooking(state)) {
|
394
|
+
return true;
|
395
|
+
}
|
396
|
+
return import_status.appointmentTypes.includes(extension_type);
|
397
|
+
};
|
398
|
+
const appointmentServices = services.filter((d) => checkType(d.extension_type));
|
399
|
+
if (!appointmentServices.length) return true;
|
400
|
+
let _pets = pets == null ? void 0 : pets.map((d) => {
|
401
|
+
return {
|
402
|
+
...d,
|
403
|
+
// 如果该购物车中没选择任何商品,则不需要验证,所以直接用1来填充
|
404
|
+
// services: !holderProducts?.length ? [1] : holderProducts?.filter((d: any) => appointmentTypes.includes(d.extension_type))
|
405
|
+
services: services.filter((item) => {
|
406
|
+
var _a2;
|
407
|
+
return ((_a2 = item._extend) == null ? void 0 : _a2.holder_id) == d.form_record_id && checkType(item.extension_type);
|
408
|
+
})
|
409
|
+
};
|
410
|
+
});
|
411
|
+
_pets = _pets.filter((d) => !d.services.length);
|
412
|
+
return _pets.length > 0;
|
413
|
+
};
|
414
|
+
var getDayProducts = (holderId2, lists, isTerminal) => {
|
415
|
+
let _lists = lists || [];
|
416
|
+
if (!holderId2 && !isTerminal) {
|
417
|
+
_lists = _lists.filter((item) => !import_status.appointmentTypes.includes(item == null ? void 0 : item.extension_type));
|
418
|
+
} else {
|
419
|
+
_lists = _lists.filter((item) => {
|
420
|
+
var _a;
|
421
|
+
return !import_status.appointmentTypes.includes(item == null ? void 0 : item.extension_type) || import_status.appointmentTypes.includes(item == null ? void 0 : item.extension_type) && ((_a = item.duration) == null ? void 0 : _a.type) === "days";
|
422
|
+
});
|
423
|
+
}
|
424
|
+
return _lists;
|
425
|
+
};
|
426
|
+
var getPets = (state) => {
|
427
|
+
var _a, _b, _c, _d, _e, _f;
|
428
|
+
const form_id = ((_d = (_c = (_b = (_a = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _a.config) == null ? void 0 : _b.basic) == null ? void 0 : _c.appointment_subject) == null ? void 0 : _d.form_id) || 0;
|
429
|
+
const pets = ((_f = (_e = state == null ? void 0 : state.pet) == null ? void 0 : _e.value) == null ? void 0 : _f[form_id]) || [];
|
430
|
+
return pets;
|
431
|
+
};
|
432
|
+
var getAppointmentService = (state) => {
|
433
|
+
var _a;
|
434
|
+
const services = ((_a = state.service) == null ? void 0 : _a.value) || [];
|
435
|
+
let lists = services.filter((item) => import_status.appointmentTypes.includes(item.extension_type));
|
436
|
+
return lists;
|
437
|
+
};
|
438
|
+
var isOpenDeletePet = (state, newVal) => {
|
439
|
+
var _a, _b, _c, _d, _e, _f;
|
440
|
+
const form_id = ((_d = (_c = (_b = (_a = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _a.config) == null ? void 0 : _b.basic) == null ? void 0 : _c.appointment_subject) == null ? void 0 : _d.form_id) || 0;
|
441
|
+
const oldPets = ((_f = (_e = state == null ? void 0 : state.pet) == null ? void 0 : _e.value) == null ? void 0 : _f[form_id]) || [];
|
442
|
+
const newPets = (newVal == null ? void 0 : newVal[form_id]) || [];
|
443
|
+
const deletePets = oldPets.filter((item) => !newPets.some((newItem) => newItem.form_record_id === item.form_record_id));
|
444
|
+
const servicePets = deletePets.map((item) => {
|
445
|
+
var _a2, _b2;
|
446
|
+
return {
|
447
|
+
...item,
|
448
|
+
services: (_b2 = (_a2 = state.service) == null ? void 0 : _a2.value) == null ? void 0 : _b2.filter((d) => {
|
449
|
+
var _a3;
|
450
|
+
return ((_a3 = d._extend) == null ? void 0 : _a3.holder_id) == item.form_record_id;
|
451
|
+
})
|
452
|
+
};
|
453
|
+
});
|
454
|
+
const lists = servicePets.filter((item) => {
|
455
|
+
var _a2;
|
456
|
+
return ((_a2 = item.services) == null ? void 0 : _a2.length) > 0;
|
457
|
+
});
|
458
|
+
return {
|
459
|
+
ids: lists.map((item) => item.form_record_id),
|
460
|
+
lists
|
461
|
+
};
|
462
|
+
};
|
463
|
+
var holderId = (state) => {
|
464
|
+
var _a;
|
465
|
+
return Number(((_a = state == null ? void 0 : state.activeCartId) == null ? void 0 : _a[0]) || 0);
|
466
|
+
};
|
467
|
+
function calculateTotalPrice(data) {
|
468
|
+
const _price = data == null ? void 0 : data.reduce(
|
469
|
+
(total, item) => total + ((item == null ? void 0 : item.price) || (item == null ? void 0 : item.add_price)) * item.num,
|
470
|
+
0
|
471
|
+
);
|
472
|
+
return parseFloat(_price);
|
473
|
+
}
|
474
|
+
function updateSinglePrice(currentValue, single) {
|
475
|
+
const _single = [];
|
476
|
+
for (let index = 0; index < currentValue.length; index++) {
|
477
|
+
const item = currentValue[index];
|
478
|
+
const currentIndex = single.findIndex(
|
479
|
+
(_single2) => _single2.id === item.id
|
480
|
+
);
|
481
|
+
if (currentIndex !== -1) {
|
482
|
+
item.add_price = single[currentIndex].add_price;
|
483
|
+
item.name = single[currentIndex].name;
|
484
|
+
_single.push(item);
|
485
|
+
}
|
486
|
+
}
|
487
|
+
return _single;
|
488
|
+
}
|
489
|
+
function updateBundlePrice(currentValue, [bundle, single]) {
|
490
|
+
var _a;
|
491
|
+
const _bundle = [];
|
492
|
+
for (let index = 0; index < currentValue.length; index++) {
|
493
|
+
const item = currentValue[index];
|
494
|
+
const currentIndex = bundle.findIndex(
|
495
|
+
(_bundle2) => _bundle2.id === item.id
|
496
|
+
);
|
497
|
+
if (currentIndex !== -1 && bundle[currentIndex]) {
|
498
|
+
item.title = bundle[currentIndex].title;
|
499
|
+
item.price_type = bundle[currentIndex].price_type;
|
500
|
+
item._price = bundle[currentIndex].price;
|
501
|
+
const bundle_sum_price = parseFloat(
|
502
|
+
bundle[currentIndex].price_type === "markdown" ? bundle[currentIndex].price * -1 : bundle[currentIndex].price
|
503
|
+
).toFixed(2);
|
504
|
+
item.price = bundle_sum_price;
|
505
|
+
item.bundle_sum_price = bundle_sum_price;
|
506
|
+
if ((_a = item == null ? void 0 : item.option) == null ? void 0 : _a.length) {
|
507
|
+
const _option = JSON.parse(JSON.stringify(item.option));
|
508
|
+
item.option = updateSinglePrice(_option, single);
|
509
|
+
let optionPrice = 0;
|
510
|
+
optionPrice = calculateTotalPrice(item.option);
|
511
|
+
const bundle_sum_price2 = (parseFloat(
|
512
|
+
bundle[currentIndex].price_type === "markdown" ? bundle[currentIndex].price * -1 : bundle[currentIndex].price
|
513
|
+
) + optionPrice).toFixed(2);
|
514
|
+
item.price = bundle_sum_price2;
|
515
|
+
item.bundle_sum_price = bundle_sum_price2;
|
516
|
+
}
|
517
|
+
_bundle.push(item);
|
518
|
+
}
|
519
|
+
}
|
520
|
+
return _bundle;
|
521
|
+
}
|
522
|
+
function flatData(newPackageData) {
|
523
|
+
var _a, _b, _c;
|
524
|
+
let bundle = [];
|
525
|
+
let single = [];
|
526
|
+
for (const group of newPackageData) {
|
527
|
+
if ((_a = group == null ? void 0 : group.bundle_item) == null ? void 0 : _a.length) {
|
528
|
+
for (const item of group.bundle_item) {
|
529
|
+
bundle.push(item);
|
530
|
+
}
|
531
|
+
}
|
532
|
+
}
|
533
|
+
for (const bundleItem of bundle) {
|
534
|
+
if ((_b = bundleItem == null ? void 0 : bundleItem.option_group) == null ? void 0 : _b.length) {
|
535
|
+
for (const group of bundleItem.option_group) {
|
536
|
+
if ((_c = group == null ? void 0 : group.option_item) == null ? void 0 : _c.length) {
|
537
|
+
for (const item of group.option_item) {
|
538
|
+
single.push(item);
|
539
|
+
}
|
540
|
+
}
|
541
|
+
}
|
542
|
+
}
|
543
|
+
}
|
544
|
+
return [bundle, single];
|
545
|
+
}
|
546
|
+
function updateNormalBundlePrice(currentValue, newBundleData) {
|
547
|
+
const _currentValue = JSON.parse(JSON.stringify(currentValue));
|
548
|
+
const _flatData = flatData(newBundleData);
|
549
|
+
const newValue = updateBundlePrice(_currentValue, _flatData);
|
550
|
+
return newValue;
|
551
|
+
}
|
552
|
+
var normalServicePrice = async (ids, state) => {
|
553
|
+
var _a, _b, _c, _d;
|
554
|
+
const services = ((_a = state.service) == null ? void 0 : _a.value) || [];
|
555
|
+
const customerId = ((_c = (_b = state == null ? void 0 : state.client) == null ? void 0 : _b.value) == null ? void 0 : _c.id) || 0;
|
556
|
+
let data = await state.apis.getServices({
|
557
|
+
skip: 1,
|
558
|
+
num: 500,
|
559
|
+
ids,
|
560
|
+
customer_id: customerId,
|
561
|
+
open_quotation: 1,
|
562
|
+
open_bundle: 1,
|
563
|
+
with: ["bundleGroup.bundleItem", "optionGroup.optionItem"],
|
564
|
+
_config: { abort: true }
|
565
|
+
});
|
566
|
+
if (!((_d = data == null ? void 0 : data.list) == null ? void 0 : _d.length)) return;
|
567
|
+
const _lists = services.map((item) => {
|
568
|
+
var _a2, _b2, _c2, _d2;
|
569
|
+
let obj = { ...item };
|
570
|
+
if (!import_status.appointmentTypes.includes(obj.extension_type)) {
|
571
|
+
const product = data.list.find((p) => p.id === (item == null ? void 0 : item.product_id));
|
572
|
+
let _extend = (obj == null ? void 0 : obj._extend) || {};
|
573
|
+
const other = (_extend == null ? void 0 : _extend.other) || {};
|
574
|
+
if (product) {
|
575
|
+
if (((_a2 = product == null ? void 0 : product.variant) == null ? void 0 : _a2.length) && (other == null ? void 0 : other.product_variant_id)) {
|
576
|
+
const _variant = (_b2 = product == null ? void 0 : product.variant) == null ? void 0 : _b2.find((v) => v.id === (other == null ? void 0 : other.product_variant_id));
|
577
|
+
obj._extend.price = Number(_variant == null ? void 0 : _variant.price);
|
578
|
+
obj._extend.other.price = Number(_variant == null ? void 0 : _variant.price);
|
579
|
+
} else {
|
580
|
+
obj._extend.price = Number(product == null ? void 0 : product.price);
|
581
|
+
}
|
582
|
+
if (((_c2 = other == null ? void 0 : other.bundle) == null ? void 0 : _c2.length) && ((_d2 = product == null ? void 0 : product.bundle_group) == null ? void 0 : _d2.length)) {
|
583
|
+
let _bundle = updateNormalBundlePrice(other.bundle, product == null ? void 0 : product.bundle_group);
|
584
|
+
obj._extend.other = {
|
585
|
+
...other,
|
586
|
+
bundle: _bundle
|
587
|
+
};
|
588
|
+
}
|
589
|
+
obj._extend.total = (0, import_utils.getProductTotalPrice)(obj);
|
590
|
+
obj._extend.origin_total = (0, import_utils.getProductTotalPrice)(obj);
|
591
|
+
}
|
592
|
+
}
|
593
|
+
return obj;
|
594
|
+
});
|
595
|
+
return _lists;
|
596
|
+
};
|
597
|
+
var updateAppointmentServicePrice = async (state, { start_date, end_date, product_id }) => {
|
598
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
599
|
+
const defaultReturn = {
|
600
|
+
multiDayPrices: [],
|
601
|
+
price: Number((_c = (_b = (_a = state == null ? void 0 : state.service) == null ? void 0 : _a.cacheItem) == null ? void 0 : _b._extend) == null ? void 0 : _c.price) || 0
|
602
|
+
};
|
603
|
+
try {
|
604
|
+
const format = "YYYY-MM-DD";
|
605
|
+
const customer_id = ((_e = (_d = state == null ? void 0 : state.client) == null ? void 0 : _d.value) == null ? void 0 : _e.id) || 1;
|
606
|
+
const _product_id = product_id || ((_f = state.service.cacheItem) == null ? void 0 : _f.product_id) || 0;
|
607
|
+
let multi_day_price = null;
|
608
|
+
if (!product_id) {
|
609
|
+
console.log("updateAppointmentServicePrice", product_id);
|
610
|
+
return defaultReturn;
|
611
|
+
}
|
612
|
+
const startDate = (0, import_dayjs.default)(start_date).format(format);
|
613
|
+
const endDate = (0, import_dayjs.default)(end_date).subtract(1, "days").format(format);
|
614
|
+
const params = {
|
615
|
+
customer_id,
|
616
|
+
multi_day: { start: startDate, end: endDate }
|
617
|
+
};
|
618
|
+
const res = await (0, import_serve.postMultiDay)(_product_id, params);
|
619
|
+
const _prices = ((_g = res == null ? void 0 : res.data) == null ? void 0 : _g.multi_day_price) || [];
|
620
|
+
multi_day_price = _prices == null ? void 0 : _prices.map((p) => {
|
621
|
+
var _a2, _b2;
|
622
|
+
const startDate2 = (0, import_dayjs.default)((_a2 = p == null ? void 0 : p.multi_day) == null ? void 0 : _a2.start);
|
623
|
+
const endDate2 = (0, import_dayjs.default)((_b2 = p == null ? void 0 : p.multi_day) == null ? void 0 : _b2.end).add(1, "day");
|
624
|
+
let duration = (endDate2 == null ? void 0 : endDate2.diff(startDate2, "day")) || 1;
|
625
|
+
return {
|
626
|
+
total: Number(p == null ? void 0 : p.price),
|
627
|
+
origin_total: Number(p == null ? void 0 : p.price),
|
628
|
+
num: duration,
|
629
|
+
quotation_id: (p == null ? void 0 : p.quotation_id) || 0,
|
630
|
+
start_date: startDate2 == null ? void 0 : startDate2.format(format),
|
631
|
+
end_date: endDate2 == null ? void 0 : endDate2.format(format)
|
632
|
+
};
|
633
|
+
});
|
634
|
+
return {
|
635
|
+
multiDayPrices: multi_day_price,
|
636
|
+
price: Number((_h = res == null ? void 0 : res.data) == null ? void 0 : _h.price) || 0
|
637
|
+
};
|
638
|
+
} catch (error) {
|
639
|
+
console.log("updateAppointmentServicePrice", error);
|
640
|
+
}
|
641
|
+
return defaultReturn;
|
642
|
+
};
|
643
|
+
var updateServicePrice = (state) => {
|
644
|
+
var _a;
|
645
|
+
let services = ((_a = state.service) == null ? void 0 : _a.value) || [];
|
646
|
+
let normalServices = services == null ? void 0 : services.filter(
|
647
|
+
(item) => isEventBooking(state) ? true : !import_status.appointmentTypes.includes(item.extension_type)
|
648
|
+
);
|
649
|
+
let newNormalIds = normalServices == null ? void 0 : normalServices.map((item) => (item == null ? void 0 : item.product_id) || (item == null ? void 0 : item.id));
|
650
|
+
newNormalIds = [...new Set(newNormalIds)];
|
651
|
+
if (newNormalIds == null ? void 0 : newNormalIds.length) {
|
652
|
+
return normalServicePrice(newNormalIds, state);
|
653
|
+
}
|
654
|
+
return [];
|
655
|
+
};
|
656
|
+
// Annotate the CommonJS export names for ESM import in node:
|
657
|
+
0 && (module.exports = {
|
658
|
+
disabledDate,
|
659
|
+
formItems,
|
660
|
+
formatActiveKey,
|
661
|
+
formatDateTime,
|
662
|
+
formatDayDate,
|
663
|
+
formatDayTime,
|
664
|
+
formatHolderLists,
|
665
|
+
formatProducts,
|
666
|
+
getAppointmentService,
|
667
|
+
getDayProducts,
|
668
|
+
getErrorMessage,
|
669
|
+
getPets,
|
670
|
+
getResourceItem,
|
671
|
+
holderId,
|
672
|
+
initDate,
|
673
|
+
isAppointmentProduct,
|
674
|
+
isBookingProduct,
|
675
|
+
isDayBooking,
|
676
|
+
isDayBookingProduct,
|
677
|
+
isDaysBooking,
|
678
|
+
isEventBooking,
|
679
|
+
isHasDayAppointmentProduct,
|
680
|
+
isOpenDeletePet,
|
681
|
+
isTerminalDayBooking,
|
682
|
+
updateAppointmentServicePrice,
|
683
|
+
updateNormalBundlePrice,
|
684
|
+
updateServicePrice,
|
685
|
+
updateServices
|
686
|
+
});
|