@pisell/private-materials 6.3.138 → 6.3.140
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +2 -2
- package/build/lowcode/preview.js +153 -426
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +8 -8
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +10 -10
- package/es/businessModel/SalesModel/index.d.ts +0 -1
- package/es/components/authentication/admin/ChannelAuthSetting/OnlineShopAuth/index.js +24 -5
- package/es/components/authentication/admin/ChannelAuthSetting/index.js +1 -1
- package/es/components/booking/addons/model.d.ts +10 -1
- package/es/components/booking/components/TabProduct/selectProductItem/index.d.ts +1 -0
- package/es/components/booking/components/collapsibleList/utils.d.ts +1 -0
- package/es/components/booking/components/emptyBooking/index.d.ts +1 -0
- package/es/components/booking/components/footer/FooterMenus/index.d.ts +1 -0
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/es/components/booking/components/reloadResourceModal/index.d.ts +1 -0
- package/es/components/booking/deposit/index.d.ts +0 -1
- package/es/components/booking/forms/model.d.ts +10 -1
- package/es/components/booking/forms/table/index.d.ts +1 -0
- package/es/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/es/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
- package/es/components/booking/info/index.d.ts +0 -1
- package/es/components/booking/info/model.d.ts +10 -1
- package/es/components/booking/info/service/Lists.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 +1 -0
- 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/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 +1 -0
- package/es/components/booking/model.d.ts +9 -1
- package/es/components/booking/notes/NoteBlock/NoteItem/index.d.ts +1 -0
- package/es/components/booking/notes/model.d.ts +10 -1
- package/es/components/booking/payments/model.d.ts +10 -1
- package/es/components/booking/utils.d.ts +2 -2
- package/es/components/ecocup/components/CupInfoCard/index.d.ts +1 -0
- package/es/components/ecocup/components/CustomerCard/index.d.ts +1 -0
- package/es/components/eftpos/deviceList/index.d.ts +1 -0
- package/es/components/eftpos/form/index.d.ts +1 -0
- package/es/components/eftpos/group/index.d.ts +1 -0
- package/es/components/eftpos/icon/apiKey.d.ts +1 -0
- package/es/components/eftpos/icon/device.d.ts +1 -0
- package/es/components/eftpos/pos.d.ts +1 -0
- package/es/components/eftpos/receipt/index.d.ts +1 -0
- package/es/components/eftposPay/app.d.ts +0 -1
- package/es/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/es/components/eftposPay/component/fail/failCustom.d.ts +0 -1
- package/es/components/eftposPay/component/fail/network.d.ts +1 -0
- package/es/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/es/components/eftposPay/component/header/titlebar.d.ts +1 -0
- package/es/components/eftposPay/component/signature/index.d.ts +1 -0
- package/es/components/eftposPay/component/step/index.d.ts +1 -0
- package/es/components/eftposPay/component/step/step.d.ts +1 -0
- package/es/components/eftposPay/device.d.ts +0 -1
- package/es/components/eftposPay/index.d.ts +0 -1
- package/es/components/eftposPay/linkly/index.d.ts +0 -1
- package/es/components/eftposPay/pay.d.ts +0 -1
- package/es/components/eftposPay/payo/config.d.ts +1 -0
- package/es/components/eftposPay/tip.d.ts +1 -0
- package/es/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/es/components/eftposPay/windcave/receiptAction.d.ts +1 -0
- package/es/components/eftposPay/windcave/windcave.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/Content/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
- package/es/components/eventBooking/index.d.ts +0 -1
- package/es/components/login/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +7 -5
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
- package/es/components/pay/toC/model.d.ts +9 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/BirthdayField/index.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/GenderField/index.d.ts +1 -0
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/index.d.ts +0 -1
- package/es/components/productExtension/fields/SelectProducts/ProductItemPreview/index.d.ts +1 -0
- package/es/components/productExtension/index.d.ts +0 -1
- package/es/components/ruleSetting/index.d.ts +0 -1
- package/es/components/ruleSetting/ruleBorder/index.d.ts +1 -0
- package/es/components/scanOrder/components/Cart/index.d.ts +2 -0
- package/es/components/scanOrder/components/Cart/index.js +181 -76
- package/es/components/scanOrder/components/Cart/index.less +72 -13
- package/es/components/scanOrder/components/Check/index.js +261 -75
- package/es/components/scanOrder/components/Check/index.less +30 -0
- package/es/components/scanOrder/components/Content/index.js +382 -144
- package/es/components/scanOrder/components/Footer/index.d.ts +2 -0
- package/es/components/scanOrder/components/Footer/index.js +4 -2
- package/es/components/scanOrder/components/Footer/index.less +16 -7
- package/es/components/scanOrder/components/FulfillmentMode/index.d.ts +11 -0
- package/es/components/scanOrder/components/FulfillmentMode/index.js +90 -0
- package/es/components/scanOrder/components/FulfillmentMode/index.less +40 -0
- package/es/components/scanOrder/components/ManualPickupRefModal/index.d.ts +16 -0
- package/es/components/scanOrder/components/ManualPickupRefModal/index.js +87 -0
- package/es/components/scanOrder/components/ManualPickupRefModal/index.less +61 -0
- package/es/components/scanOrder/components/Menu/index.d.ts +11 -0
- package/es/components/scanOrder/components/Menu/index.js +140 -169
- package/es/components/scanOrder/components/Voucher/index.d.ts +8 -0
- package/es/components/scanOrder/components/Voucher/index.js +250 -0
- package/es/components/scanOrder/context.js +123 -3
- package/es/components/scanOrder/hooks.js +4 -1
- package/es/components/scanOrder/locales.d.ts +120 -0
- package/es/components/scanOrder/locales.js +120 -0
- package/es/components/scanOrder/types.d.ts +33 -0
- package/es/components/scanOrder/utils/toShoppingCartProducts.d.ts +1 -0
- package/es/components/scanOrder/utils/toShoppingCartProducts.js +137 -9
- package/es/components/scanOrder/utils/transformProductDetail.js +21 -4
- package/es/components/schedules/calendar/calendarItem.d.ts +1 -0
- package/es/components/schedules/calendar/index.d.ts +1 -0
- package/es/components/schedules/components/CurrentDay/index.d.ts +1 -0
- package/es/components/schedules/components/ScheduleDetailList/index.d.ts +1 -0
- package/es/components/schedules/components/ScheduleList/index.d.ts +1 -0
- package/es/components/schedules/model.d.ts +9 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
- package/es/components/schedules/products/index.d.ts +1 -0
- package/es/components/schedules/products/list/ProductItem/index.d.ts +1 -0
- package/es/components/schedules/products/list/index.d.ts +1 -0
- package/es/components/schedules/resources/index.d.ts +1 -0
- package/es/components/schedules/resources/list/index.d.ts +1 -0
- package/es/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/es/components/schedules/schedules/AllSchedules/index.d.ts +1 -0
- package/es/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +1 -0
- package/es/components/schedules/schedules/index.d.ts +1 -0
- package/es/components/systemSettings/registry/components/GroupModal.js +8 -1
- package/es/components/systemSettings/registry/components/ItemModal.js +3 -0
- package/es/components/systemSettings/registry/index.js +3 -1
- package/es/components/systemSettings/registry/services.d.ts +2 -0
- package/es/components/systemSettings/registry/types.d.ts +3 -0
- package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
- package/es/components/venueBooking/components/Addons/index.js +42 -33
- package/es/components/venueBooking/components/Cart/index.js +26 -14
- package/es/components/venueBooking/components/VenueSelection/components/TimeGrid.js +129 -17
- package/es/components/venueBooking/context.js +6 -6
- package/es/components/venueBooking/hooks.d.ts +16 -3
- package/es/components/venueBooking/hooks.js +16 -4
- package/es/components/venueBooking/types.d.ts +19 -2
- package/es/hooks/usePaymentLogger.d.ts +1 -0
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/plus/clientName/index.d.ts +1 -0
- package/es/plus/clinetSearch/Add/BirthdayField/index.d.ts +1 -0
- package/es/plus/clinetSearch/Add/GenderField/index.d.ts +1 -0
- package/es/plus/pisellReservation/floorRoomCard/views/RoomCardIcons.d.ts +1 -0
- package/es/plus/pisellSalesManagement/hooks/useSalesGridData.d.ts +1 -0
- package/es/plus/saasCreateOrganization/components/Header.d.ts +1 -0
- package/es/plus/saasRegister/components/EntryEmail.d.ts +1 -0
- package/es/plus/saasRegister/components/EntryInfo.d.ts +1 -0
- package/es/plus/saasRegister/components/GoLogin.d.ts +1 -0
- package/es/plus/saasRegister/components/Header.d.ts +1 -0
- package/es/plus/saasRegister/components/VerifyError.d.ts +1 -0
- package/es/plus/saasRegister/components/VerifyingLink.d.ts +1 -0
- package/es/plus/skuOptionsSelection/components/NormalCard/index.d.ts +1 -0
- package/es/plus/skuOptionsSelection/components/TitleExtra/index.d.ts +1 -0
- package/es/plus/skuOptionsSelection/components/VariantCard/index.d.ts +1 -0
- package/es/plus/walletEditor/components/relationProduct/index.d.ts +1 -0
- package/es/pro/Selector/demo.d.ts +1 -0
- package/lib/businessModel/SalesModel/index.d.ts +0 -1
- package/lib/components/authentication/admin/ChannelAuthSetting/OnlineShopAuth/index.js +19 -4
- package/lib/components/authentication/admin/ChannelAuthSetting/index.js +1 -1
- package/lib/components/booking/addons/model.d.ts +10 -1
- package/lib/components/booking/components/TabProduct/selectProductItem/index.d.ts +1 -0
- package/lib/components/booking/components/collapsibleList/utils.d.ts +1 -0
- package/lib/components/booking/components/emptyBooking/index.d.ts +1 -0
- package/lib/components/booking/components/footer/FooterMenus/index.d.ts +1 -0
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/lib/components/booking/components/reloadResourceModal/index.d.ts +1 -0
- package/lib/components/booking/deposit/index.d.ts +0 -1
- package/lib/components/booking/forms/model.d.ts +10 -1
- package/lib/components/booking/forms/table/index.d.ts +1 -0
- package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/lib/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
- package/lib/components/booking/info/index.d.ts +0 -1
- package/lib/components/booking/info/model.d.ts +10 -1
- package/lib/components/booking/info/service/Lists.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 +1 -0
- 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/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 +1 -0
- package/lib/components/booking/model.d.ts +9 -1
- package/lib/components/booking/notes/NoteBlock/NoteItem/index.d.ts +1 -0
- package/lib/components/booking/notes/model.d.ts +10 -1
- package/lib/components/booking/payments/model.d.ts +10 -1
- package/lib/components/booking/utils.d.ts +2 -2
- package/lib/components/ecocup/components/CupInfoCard/index.d.ts +1 -0
- package/lib/components/ecocup/components/CustomerCard/index.d.ts +1 -0
- package/lib/components/eftpos/deviceList/index.d.ts +1 -0
- package/lib/components/eftpos/form/index.d.ts +1 -0
- package/lib/components/eftpos/group/index.d.ts +1 -0
- package/lib/components/eftpos/icon/apiKey.d.ts +1 -0
- package/lib/components/eftpos/icon/device.d.ts +1 -0
- package/lib/components/eftpos/pos.d.ts +1 -0
- package/lib/components/eftpos/receipt/index.d.ts +1 -0
- package/lib/components/eftposPay/app.d.ts +0 -1
- package/lib/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/failCustom.d.ts +0 -1
- package/lib/components/eftposPay/component/fail/network.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/lib/components/eftposPay/component/header/titlebar.d.ts +1 -0
- package/lib/components/eftposPay/component/signature/index.d.ts +1 -0
- package/lib/components/eftposPay/component/step/index.d.ts +1 -0
- package/lib/components/eftposPay/component/step/step.d.ts +1 -0
- package/lib/components/eftposPay/device.d.ts +0 -1
- package/lib/components/eftposPay/index.d.ts +0 -1
- package/lib/components/eftposPay/linkly/index.d.ts +0 -1
- package/lib/components/eftposPay/pay.d.ts +0 -1
- package/lib/components/eftposPay/payo/config.d.ts +1 -0
- package/lib/components/eftposPay/tip.d.ts +1 -0
- package/lib/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/lib/components/eftposPay/windcave/receiptAction.d.ts +1 -0
- package/lib/components/eftposPay/windcave/windcave.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/Content/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/ProductItem/index.d.ts +1 -0
- package/lib/components/eventBooking/index.d.ts +0 -1
- package/lib/components/login/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +2 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
- package/lib/components/pay/toC/model.d.ts +9 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/BirthdayField/index.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/GenderField/index.d.ts +1 -0
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/index.d.ts +0 -1
- package/lib/components/productExtension/fields/SelectProducts/ProductItemPreview/index.d.ts +1 -0
- package/lib/components/productExtension/index.d.ts +0 -1
- package/lib/components/ruleSetting/index.d.ts +0 -1
- package/lib/components/ruleSetting/ruleBorder/index.d.ts +1 -0
- package/lib/components/scanOrder/components/Cart/index.d.ts +2 -0
- package/lib/components/scanOrder/components/Cart/index.js +117 -28
- package/lib/components/scanOrder/components/Cart/index.less +72 -13
- package/lib/components/scanOrder/components/Check/index.js +109 -15
- package/lib/components/scanOrder/components/Check/index.less +30 -0
- package/lib/components/scanOrder/components/Content/index.js +175 -48
- package/lib/components/scanOrder/components/Footer/index.d.ts +2 -0
- package/lib/components/scanOrder/components/Footer/index.js +2 -2
- package/lib/components/scanOrder/components/Footer/index.less +16 -7
- package/lib/components/scanOrder/components/FulfillmentMode/index.d.ts +11 -0
- package/lib/components/scanOrder/components/FulfillmentMode/index.js +96 -0
- package/lib/components/scanOrder/components/FulfillmentMode/index.less +40 -0
- package/lib/components/scanOrder/components/ManualPickupRefModal/index.d.ts +16 -0
- package/lib/components/scanOrder/components/ManualPickupRefModal/index.js +116 -0
- package/lib/components/scanOrder/components/ManualPickupRefModal/index.less +61 -0
- package/lib/components/scanOrder/components/Menu/index.d.ts +11 -0
- package/lib/components/scanOrder/components/Menu/index.js +23 -36
- package/lib/components/scanOrder/components/Voucher/index.d.ts +8 -0
- package/lib/components/scanOrder/components/Voucher/index.js +162 -0
- package/lib/components/scanOrder/context.js +91 -2
- package/lib/components/scanOrder/hooks.js +4 -1
- package/lib/components/scanOrder/locales.d.ts +120 -0
- package/lib/components/scanOrder/locales.js +120 -0
- package/lib/components/scanOrder/types.d.ts +33 -0
- package/lib/components/scanOrder/utils/toShoppingCartProducts.d.ts +1 -0
- package/lib/components/scanOrder/utils/toShoppingCartProducts.js +88 -6
- package/lib/components/scanOrder/utils/transformProductDetail.js +10 -3
- package/lib/components/schedules/calendar/calendarItem.d.ts +1 -0
- package/lib/components/schedules/calendar/index.d.ts +1 -0
- package/lib/components/schedules/components/CurrentDay/index.d.ts +1 -0
- package/lib/components/schedules/components/ScheduleDetailList/index.d.ts +1 -0
- package/lib/components/schedules/components/ScheduleList/index.d.ts +1 -0
- package/lib/components/schedules/model.d.ts +9 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/MaxParticipantsModule/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/ResourcesModule/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/index.d.ts +1 -0
- package/lib/components/schedules/products/index.d.ts +1 -0
- package/lib/components/schedules/products/list/ProductItem/index.d.ts +1 -0
- package/lib/components/schedules/products/list/index.d.ts +1 -0
- package/lib/components/schedules/resources/index.d.ts +1 -0
- package/lib/components/schedules/resources/list/index.d.ts +1 -0
- package/lib/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/lib/components/schedules/schedules/AllSchedules/index.d.ts +1 -0
- package/lib/components/schedules/schedules/ScheduleDetailDrawer/index.d.ts +1 -0
- package/lib/components/schedules/schedules/index.d.ts +1 -0
- package/lib/components/systemSettings/registry/components/GroupModal.js +71 -72
- package/lib/components/systemSettings/registry/components/ItemModal.js +2 -1
- package/lib/components/systemSettings/registry/index.js +3 -1
- package/lib/components/systemSettings/registry/services.d.ts +2 -0
- package/lib/components/systemSettings/registry/types.d.ts +3 -0
- package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
- package/lib/components/venueBooking/components/Addons/index.js +15 -8
- package/lib/components/venueBooking/components/Cart/index.js +8 -2
- package/lib/components/venueBooking/components/VenueSelection/components/TimeGrid.js +118 -18
- package/lib/components/venueBooking/context.js +2 -1
- package/lib/components/venueBooking/hooks.d.ts +16 -3
- package/lib/components/venueBooking/hooks.js +8 -2
- package/lib/components/venueBooking/types.d.ts +19 -2
- package/lib/hooks/usePaymentLogger.d.ts +1 -0
- package/lib/index.d.ts +1 -1
- package/lib/index.js +2 -0
- package/lib/plus/clientName/index.d.ts +1 -0
- package/lib/plus/clinetSearch/Add/BirthdayField/index.d.ts +1 -0
- package/lib/plus/clinetSearch/Add/GenderField/index.d.ts +1 -0
- package/lib/plus/pisellReservation/floorRoomCard/views/RoomCardIcons.d.ts +1 -0
- package/lib/plus/pisellSalesManagement/hooks/useSalesGridData.d.ts +1 -0
- package/lib/plus/saasCreateOrganization/components/Header.d.ts +1 -0
- package/lib/plus/saasRegister/components/EntryEmail.d.ts +1 -0
- package/lib/plus/saasRegister/components/EntryInfo.d.ts +1 -0
- package/lib/plus/saasRegister/components/GoLogin.d.ts +1 -0
- package/lib/plus/saasRegister/components/Header.d.ts +1 -0
- package/lib/plus/saasRegister/components/VerifyError.d.ts +1 -0
- package/lib/plus/saasRegister/components/VerifyingLink.d.ts +1 -0
- package/lib/plus/skuOptionsSelection/components/NormalCard/index.d.ts +1 -0
- package/lib/plus/skuOptionsSelection/components/TitleExtra/index.d.ts +1 -0
- package/lib/plus/skuOptionsSelection/components/VariantCard/index.d.ts +1 -0
- package/lib/plus/walletEditor/components/relationProduct/index.d.ts +1 -0
- package/lib/pro/Selector/demo.d.ts +1 -0
- package/lowcode/admin-auth-channel-auth/meta.ts +116 -0
- package/lowcode/admin-auth-online-shop-auth/meta.ts +81 -5
- package/package.json +1 -1
|
@@ -9,6 +9,8 @@ interface CartProps {
|
|
|
9
9
|
embedded?: boolean;
|
|
10
10
|
confirmLoading?: boolean;
|
|
11
11
|
extraContent?: React.ReactNode;
|
|
12
|
+
/** 视觉禁用:按钮仍会触发 onNext,由父级自行拦截(用于弹 toast 等反馈) */
|
|
13
|
+
disabled?: boolean;
|
|
12
14
|
}
|
|
13
15
|
export default function Cart(props: CartProps): JSX.Element | null;
|
|
14
16
|
export {};
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
3
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
4
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
5
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
2
6
|
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
3
7
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
4
8
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
@@ -8,15 +12,17 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
8
12
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
9
13
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
10
14
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
11
|
-
import React, { useEffect, useMemo, useState } from 'react';
|
|
15
|
+
import React, { useEffect, useMemo, useState, useCallback } from 'react';
|
|
12
16
|
import { Button } from '@pisell/materials';
|
|
13
17
|
import { locales } from '@pisell/utils';
|
|
14
18
|
import ShoppingCart from "../../../shoppingCart";
|
|
15
19
|
import { useScanOrderContext } from "../../context";
|
|
20
|
+
import useEngineContext from "../../../../hooks/useEngineContext";
|
|
16
21
|
import SubTotal from "../../../subTotal";
|
|
22
|
+
import VoucherCard from "../Voucher";
|
|
17
23
|
import "./index.less";
|
|
18
24
|
export default function Cart(props) {
|
|
19
|
-
var
|
|
25
|
+
var _engineContext$appHel, _engineContext$engine, _businessUtils$getApp, _businessUtils$getApp2;
|
|
20
26
|
var open = props.open,
|
|
21
27
|
onCancel = props.onCancel,
|
|
22
28
|
onNext = props.onNext,
|
|
@@ -26,10 +32,20 @@ export default function Cart(props) {
|
|
|
26
32
|
embedded = _props$embedded === void 0 ? false : _props$embedded,
|
|
27
33
|
_props$confirmLoading = props.confirmLoading,
|
|
28
34
|
confirmLoading = _props$confirmLoading === void 0 ? false : _props$confirmLoading,
|
|
29
|
-
extraContent = props.extraContent
|
|
35
|
+
extraContent = props.extraContent,
|
|
36
|
+
_props$disabled = props.disabled,
|
|
37
|
+
disabled = _props$disabled === void 0 ? false : _props$disabled;
|
|
30
38
|
var _useScanOrderContext = useScanOrderContext(),
|
|
31
39
|
runModuleAction = _useScanOrderContext.runModuleAction,
|
|
32
|
-
refreshViewModel = _useScanOrderContext.refreshViewModel
|
|
40
|
+
refreshViewModel = _useScanOrderContext.refreshViewModel,
|
|
41
|
+
scanOrderModule = _useScanOrderContext.scanOrderModule;
|
|
42
|
+
var engineContext = useEngineContext();
|
|
43
|
+
var businessUtils = engineContext === null || engineContext === void 0 || (_engineContext$appHel = engineContext.appHelper) === null || _engineContext$appHel === void 0 || (_engineContext$appHel = _engineContext$appHel.utils) === null || _engineContext$appHel === void 0 ? void 0 : _engineContext$appHel.businessUtils;
|
|
44
|
+
var locale = (engineContext === null || engineContext === void 0 || (_engineContext$engine = engineContext.engine) === null || _engineContext$engine === void 0 || (_engineContext$engine = _engineContext$engine.props) === null || _engineContext$engine === void 0 ? void 0 : _engineContext$engine.locale) || 'en';
|
|
45
|
+
// 是否安装商品券/折扣卡应用(与 venueBooking Cart 保持一致的判定)
|
|
46
|
+
var hasGoodPassApp = !!(businessUtils !== null && businessUtils !== void 0 && (_businessUtils$getApp = businessUtils.getAppByModal) !== null && _businessUtils$getApp !== void 0 && _businessUtils$getApp.call(businessUtils, 'goodpass'));
|
|
47
|
+
var hasDiscountCardApp = !!(businessUtils !== null && businessUtils !== void 0 && (_businessUtils$getApp2 = businessUtils.getAppByModal) !== null && _businessUtils$getApp2 !== void 0 && _businessUtils$getApp2.call(businessUtils, 'discountcard'));
|
|
48
|
+
var showVoucher = hasGoodPassApp || hasDiscountCardApp;
|
|
33
49
|
var isVisible = embedded || open;
|
|
34
50
|
if (!isVisible) return null;
|
|
35
51
|
var _useState = useState(null),
|
|
@@ -37,116 +53,189 @@ export default function Cart(props) {
|
|
|
37
53
|
dineInConfig = _useState2[0],
|
|
38
54
|
setDineInConfig = _useState2[1];
|
|
39
55
|
// 去读 pisellos 内的配置
|
|
40
|
-
var getConfig = /*#__PURE__*/function () {
|
|
41
|
-
var
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
};
|
|
63
|
-
}();
|
|
64
|
-
getConfig();
|
|
56
|
+
var getConfig = useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
57
|
+
var _otherParams$dineInCo;
|
|
58
|
+
var otherParams, dineInConfig;
|
|
59
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
60
|
+
while (1) switch (_context.prev = _context.next) {
|
|
61
|
+
case 0:
|
|
62
|
+
_context.next = 2;
|
|
63
|
+
return runModuleAction('getOtherParams');
|
|
64
|
+
case 2:
|
|
65
|
+
otherParams = _context.sent;
|
|
66
|
+
console.log('otherParams >>>>> ', otherParams);
|
|
67
|
+
dineInConfig = (_otherParams$dineInCo = otherParams === null || otherParams === void 0 ? void 0 : otherParams.dineInConfig) !== null && _otherParams$dineInCo !== void 0 ? _otherParams$dineInCo : {};
|
|
68
|
+
setDineInConfig(dineInConfig);
|
|
69
|
+
case 6:
|
|
70
|
+
case "end":
|
|
71
|
+
return _context.stop();
|
|
72
|
+
}
|
|
73
|
+
}, _callee);
|
|
74
|
+
})), [runModuleAction]);
|
|
75
|
+
useEffect(function () {
|
|
76
|
+
getConfig();
|
|
77
|
+
}, []);
|
|
65
78
|
|
|
66
79
|
// 是否显示给商品添加备注
|
|
67
80
|
var isShowNote = useMemo(function () {
|
|
68
81
|
return dineInConfig === null || dineInConfig === void 0 ? void 0 : dineInConfig['sale.allow_item_notes'];
|
|
69
82
|
}, [dineInConfig]);
|
|
70
|
-
|
|
83
|
+
|
|
84
|
+
/** 与 scanOrder Footer 同一套汇总字段与展示格式 */
|
|
85
|
+
var totalDisplayAmount = useMemo(function () {
|
|
86
|
+
var _ref2, _ref3, _ref4, _ref5, _ref6, _summary$total_amount;
|
|
87
|
+
var rawAmount = (_ref2 = (_ref3 = (_ref4 = (_ref5 = (_ref6 = (_summary$total_amount = summary === null || summary === void 0 ? void 0 : summary.total_amount) !== null && _summary$total_amount !== void 0 ? _summary$total_amount : summary === null || summary === void 0 ? void 0 : summary.expect_amount) !== null && _ref6 !== void 0 ? _ref6 : summary === null || summary === void 0 ? void 0 : summary.amount) !== null && _ref5 !== void 0 ? _ref5 : summary === null || summary === void 0 ? void 0 : summary.total) !== null && _ref4 !== void 0 ? _ref4 : summary === null || summary === void 0 ? void 0 : summary.totalAmount) !== null && _ref3 !== void 0 ? _ref3 : summary === null || summary === void 0 ? void 0 : summary.payable_amount) !== null && _ref2 !== void 0 ? _ref2 : 0;
|
|
88
|
+
var parsed = Number(rawAmount);
|
|
89
|
+
if (Number.isNaN(parsed)) return '0.00';
|
|
90
|
+
return parsed.toFixed(2);
|
|
91
|
+
}, [summary]);
|
|
71
92
|
var confirmOrderText = String(locales.getText('pisell2.scan.order.action.confirm.order') || locales.getText('pisell2.event.confirm') || 'Confirm');
|
|
72
93
|
var subTotalList = useMemo(function () {
|
|
73
|
-
var _summary$product_amou, _summary$tax_fee,
|
|
94
|
+
var _summary$product_amou, _summary$tax_fee, _ref7, _summary$total_amount2, _scanOrderModule$getT, _tempSummary$tax_rate, _ref8, _tempSummary$is_price;
|
|
74
95
|
var subTotal = Number((_summary$product_amou = summary === null || summary === void 0 ? void 0 : summary.product_amount) !== null && _summary$product_amou !== void 0 ? _summary$product_amou : 0);
|
|
75
96
|
var totalTaxFee = Number((_summary$tax_fee = summary === null || summary === void 0 ? void 0 : summary.tax_fee) !== null && _summary$tax_fee !== void 0 ? _summary$tax_fee : 0);
|
|
76
|
-
var total = Number((
|
|
97
|
+
var total = Number((_ref7 = (_summary$total_amount2 = summary === null || summary === void 0 ? void 0 : summary.total_amount) !== null && _summary$total_amount2 !== void 0 ? _summary$total_amount2 : summary === null || summary === void 0 ? void 0 : summary.expect_amount) !== null && _ref7 !== void 0 ? _ref7 : 0);
|
|
98
|
+
var tempOrder = scanOrderModule === null || scanOrderModule === void 0 || (_scanOrderModule$getT = scanOrderModule.getTempOrder) === null || _scanOrderModule$getT === void 0 ? void 0 : _scanOrderModule$getT.call(scanOrderModule);
|
|
99
|
+
var tempSummary = (tempOrder === null || tempOrder === void 0 ? void 0 : tempOrder.summary) || {};
|
|
100
|
+
var taxTitle = String((tempSummary === null || tempSummary === void 0 ? void 0 : tempSummary.tax_title) || (summary === null || summary === void 0 ? void 0 : summary.tax_title) || 'GST/Tax');
|
|
101
|
+
var rawTaxRate = Number((_tempSummary$tax_rate = tempSummary === null || tempSummary === void 0 ? void 0 : tempSummary.tax_rate) !== null && _tempSummary$tax_rate !== void 0 ? _tempSummary$tax_rate : summary === null || summary === void 0 ? void 0 : summary.tax_rate);
|
|
102
|
+
var normalizedTaxRate = Number.isNaN(rawTaxRate) ? 0 : rawTaxRate > 1 ? rawTaxRate / 100 : rawTaxRate;
|
|
103
|
+
var isPriceIncludeTax = Boolean((_ref8 = (_tempSummary$is_price = tempSummary === null || tempSummary === void 0 ? void 0 : tempSummary.is_price_include_tax) !== null && _tempSummary$is_price !== void 0 ? _tempSummary$is_price : tempSummary === null || tempSummary === void 0 ? void 0 : tempSummary.isPriceIncludeTax) !== null && _ref8 !== void 0 ? _ref8 : summary === null || summary === void 0 ? void 0 : summary.is_price_include_tax);
|
|
104
|
+
|
|
105
|
+
/** 将 surcharges 数组映射为 SubTotalItem,amount > 0 才展示(与 venueBooking Cart 一致) */
|
|
106
|
+
var surchargeItems = ((summary === null || summary === void 0 ? void 0 : summary.surcharges) || []).filter(function (s) {
|
|
107
|
+
return Number(s === null || s === void 0 ? void 0 : s.amount) > 0;
|
|
108
|
+
}).map(function (s) {
|
|
109
|
+
var labelObj = (s === null || s === void 0 ? void 0 : s.label) || (s === null || s === void 0 ? void 0 : s.name) || {};
|
|
110
|
+
var label = labelObj[locale] || labelObj.en || labelObj.original || (s === null || s === void 0 ? void 0 : s.key) || '';
|
|
111
|
+
return {
|
|
112
|
+
key: (s === null || s === void 0 ? void 0 : s.key) || "surcharge_".concat(s === null || s === void 0 ? void 0 : s.surcharge_id),
|
|
113
|
+
label: label,
|
|
114
|
+
value: Number(s === null || s === void 0 ? void 0 : s.amount)
|
|
115
|
+
};
|
|
116
|
+
});
|
|
77
117
|
return [{
|
|
78
118
|
key: 'sub_total',
|
|
79
119
|
value: Number.isNaN(subTotal) ? 0 : subTotal
|
|
80
|
-
}, {
|
|
120
|
+
}].concat(_toConsumableArray(surchargeItems), [{
|
|
81
121
|
key: 'tax',
|
|
82
122
|
value: Number.isNaN(totalTaxFee) ? 0 : totalTaxFee,
|
|
83
|
-
hidden: Number.isNaN(totalTaxFee) ? true : totalTaxFee <= 0
|
|
123
|
+
hidden: Number.isNaN(totalTaxFee) ? true : totalTaxFee <= 0,
|
|
124
|
+
tax: {
|
|
125
|
+
title: taxTitle,
|
|
126
|
+
rate: normalizedTaxRate,
|
|
127
|
+
is_price_include_tax: isPriceIncludeTax
|
|
128
|
+
}
|
|
84
129
|
}, {
|
|
85
130
|
key: 'custom_total',
|
|
86
131
|
value: Number.isNaN(total) ? 0 : total,
|
|
87
132
|
label: locales.getText('pisell2.event.total'),
|
|
88
133
|
bold: true
|
|
89
|
-
}];
|
|
90
|
-
}, [summary]);
|
|
134
|
+
}]);
|
|
135
|
+
}, [summary, scanOrderModule, locale]);
|
|
91
136
|
var handleCartChange = /*#__PURE__*/function () {
|
|
92
|
-
var
|
|
93
|
-
var
|
|
94
|
-
var productId, productVariantId, identityKey;
|
|
137
|
+
var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(item, type) {
|
|
138
|
+
var _ref10, _item$product_id, _item$product_variant, productId, productVariantId, identityKey, identity, _item$note, _ref11, _item$product_id2, _item$product_variant2, _productId, _productVariantId, _identityKey;
|
|
95
139
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
96
140
|
while (1) switch (_context2.prev = _context2.next) {
|
|
97
141
|
case 0:
|
|
98
|
-
if (!(type
|
|
99
|
-
_context2.next =
|
|
142
|
+
if (!(type === 'note')) {
|
|
143
|
+
_context2.next = 21;
|
|
100
144
|
break;
|
|
101
145
|
}
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
identityKey = (item === null || item === void 0 ? void 0 : item.identity_key) || (item === null || item === void 0 ? void 0 : item.rowKey) || undefined;
|
|
146
|
+
productId = (_ref10 = (_item$product_id = item === null || item === void 0 ? void 0 : item.product_id) !== null && _item$product_id !== void 0 ? _item$product_id : item === null || item === void 0 ? void 0 : item.id) !== null && _ref10 !== void 0 ? _ref10 : null;
|
|
147
|
+
productVariantId = Number((_item$product_variant = item === null || item === void 0 ? void 0 : item.product_variant_id) !== null && _item$product_variant !== void 0 ? _item$product_variant : 0); // 不透明 identity 契约:UI 行级操作只信任 SDK 回灌的 identity_key,
|
|
148
|
+
// 禁用 rowKey 等回退路径,避免误命中其它 SKU/选项相同的行。
|
|
149
|
+
identityKey = item === null || item === void 0 ? void 0 : item.identity_key;
|
|
107
150
|
if (!(productId === null && Number.isNaN(productVariantId))) {
|
|
108
|
-
_context2.next =
|
|
151
|
+
_context2.next = 6;
|
|
109
152
|
break;
|
|
110
153
|
}
|
|
111
154
|
return _context2.abrupt("return");
|
|
112
|
-
case
|
|
113
|
-
|
|
114
|
-
_context2.next = 10;
|
|
115
|
-
return runModuleAction('removeProductFromOrder', {
|
|
155
|
+
case 6:
|
|
156
|
+
identity = {
|
|
116
157
|
product_id: productId,
|
|
117
|
-
product_variant_id: Number.isNaN(productVariantId) ? 0 : productVariantId
|
|
118
|
-
|
|
158
|
+
product_variant_id: Number.isNaN(productVariantId) ? 0 : productVariantId
|
|
159
|
+
};
|
|
160
|
+
if (typeof identityKey === 'string' && identityKey.length > 0) {
|
|
161
|
+
identity.identity_key = identityKey;
|
|
162
|
+
}
|
|
163
|
+
_context2.prev = 8;
|
|
164
|
+
_context2.next = 11;
|
|
165
|
+
return runModuleAction('setOrderProductLineNote', identity, String((_item$note = item === null || item === void 0 ? void 0 : item.note) !== null && _item$note !== void 0 ? _item$note : ''));
|
|
166
|
+
case 11:
|
|
167
|
+
_context2.next = 13;
|
|
168
|
+
return refreshViewModel();
|
|
169
|
+
case 13:
|
|
170
|
+
_context2.next = 18;
|
|
171
|
+
break;
|
|
172
|
+
case 15:
|
|
173
|
+
_context2.prev = 15;
|
|
174
|
+
_context2.t0 = _context2["catch"](8);
|
|
175
|
+
console.error('[scanOrder] setOrderProductLineNote failed', {
|
|
176
|
+
error: _context2.t0,
|
|
177
|
+
item: item
|
|
119
178
|
});
|
|
120
|
-
case
|
|
121
|
-
_context2.
|
|
179
|
+
case 18:
|
|
180
|
+
return _context2.abrupt("return");
|
|
181
|
+
case 21:
|
|
182
|
+
if (!(type === 'delete')) {
|
|
183
|
+
_context2.next = 40;
|
|
184
|
+
break;
|
|
185
|
+
}
|
|
186
|
+
_productId = (_ref11 = (_item$product_id2 = item === null || item === void 0 ? void 0 : item.product_id) !== null && _item$product_id2 !== void 0 ? _item$product_id2 : item === null || item === void 0 ? void 0 : item.id) !== null && _ref11 !== void 0 ? _ref11 : null;
|
|
187
|
+
_productVariantId = Number((_item$product_variant2 = item === null || item === void 0 ? void 0 : item.product_variant_id) !== null && _item$product_variant2 !== void 0 ? _item$product_variant2 : 0);
|
|
188
|
+
_identityKey = item === null || item === void 0 ? void 0 : item.identity_key;
|
|
189
|
+
if (!(_productId === null && Number.isNaN(_productVariantId))) {
|
|
190
|
+
_context2.next = 27;
|
|
191
|
+
break;
|
|
192
|
+
}
|
|
193
|
+
return _context2.abrupt("return");
|
|
194
|
+
case 27:
|
|
195
|
+
if (!(typeof _identityKey !== 'string' || _identityKey.length === 0)) {
|
|
196
|
+
_context2.next = 30;
|
|
197
|
+
break;
|
|
198
|
+
}
|
|
199
|
+
console.error('[scanOrder] removeProductFromOrder skipped: missing identity_key', {
|
|
200
|
+
item: item
|
|
201
|
+
});
|
|
202
|
+
return _context2.abrupt("return");
|
|
203
|
+
case 30:
|
|
204
|
+
_context2.prev = 30;
|
|
205
|
+
_context2.next = 33;
|
|
206
|
+
return runModuleAction('removeProductFromOrder', {
|
|
207
|
+
product_id: _productId,
|
|
208
|
+
product_variant_id: Number.isNaN(_productVariantId) ? 0 : _productVariantId,
|
|
209
|
+
identity_key: _identityKey
|
|
210
|
+
});
|
|
211
|
+
case 33:
|
|
212
|
+
_context2.next = 35;
|
|
122
213
|
return refreshViewModel();
|
|
123
|
-
case
|
|
124
|
-
_context2.next =
|
|
214
|
+
case 35:
|
|
215
|
+
_context2.next = 40;
|
|
125
216
|
break;
|
|
126
|
-
case
|
|
127
|
-
_context2.prev =
|
|
128
|
-
_context2.
|
|
217
|
+
case 37:
|
|
218
|
+
_context2.prev = 37;
|
|
219
|
+
_context2.t1 = _context2["catch"](30);
|
|
129
220
|
console.error('[scanOrder] removeProductFromOrder failed', {
|
|
130
|
-
error: _context2.
|
|
221
|
+
error: _context2.t1,
|
|
131
222
|
item: item
|
|
132
223
|
});
|
|
133
|
-
case
|
|
224
|
+
case 40:
|
|
134
225
|
case "end":
|
|
135
226
|
return _context2.stop();
|
|
136
227
|
}
|
|
137
|
-
}, _callee2, null, [[
|
|
228
|
+
}, _callee2, null, [[8, 15], [30, 37]]);
|
|
138
229
|
}));
|
|
139
230
|
return function handleCartChange(_x, _x2) {
|
|
140
|
-
return
|
|
231
|
+
return _ref9.apply(this, arguments);
|
|
141
232
|
};
|
|
142
233
|
}();
|
|
143
234
|
useEffect(function () {
|
|
144
235
|
if (!isVisible) return;
|
|
145
236
|
refreshViewModel();
|
|
146
237
|
}, [isVisible]);
|
|
147
|
-
var
|
|
148
|
-
className: "pisell-scan-order-cart-body"
|
|
149
|
-
}, /*#__PURE__*/React.createElement(ShoppingCart, {
|
|
238
|
+
var cartLineItems = /*#__PURE__*/React.createElement(ShoppingCart, {
|
|
150
239
|
productParams: {
|
|
151
240
|
products: items || [],
|
|
152
241
|
hideAddBtn: true,
|
|
@@ -163,7 +252,8 @@ export default function Cart(props) {
|
|
|
163
252
|
isOpenGroup: false,
|
|
164
253
|
isHideClearCart: true,
|
|
165
254
|
onChange: handleCartChange
|
|
166
|
-
})
|
|
255
|
+
});
|
|
256
|
+
var cartSubtotalSection = /*#__PURE__*/React.createElement(React.Fragment, null, showVoucher ? /*#__PURE__*/React.createElement(VoucherCard, null) : null, /*#__PURE__*/React.createElement(SubTotal, {
|
|
167
257
|
list: subTotalList,
|
|
168
258
|
style: {
|
|
169
259
|
padding: 0
|
|
@@ -171,6 +261,10 @@ export default function Cart(props) {
|
|
|
171
261
|
}), extraContent ? /*#__PURE__*/React.createElement("div", {
|
|
172
262
|
className: "pisell-scan-order-cart-extra-content"
|
|
173
263
|
}, extraContent) : null);
|
|
264
|
+
var cartBodyClassName = embedded ? 'pisell-scan-order-cart-body pisell-scan-order-cart-body-embedded' : 'pisell-scan-order-cart-body';
|
|
265
|
+
var cartBodyContent = /*#__PURE__*/React.createElement("div", {
|
|
266
|
+
className: cartBodyClassName
|
|
267
|
+
}, cartLineItems, cartSubtotalSection);
|
|
174
268
|
if (embedded) {
|
|
175
269
|
return /*#__PURE__*/React.createElement(React.Fragment, null, cartBodyContent, /*#__PURE__*/React.createElement("div", {
|
|
176
270
|
className: "pisell-scan-order-cart-embedded-footer"
|
|
@@ -178,7 +272,8 @@ export default function Cart(props) {
|
|
|
178
272
|
type: "primary",
|
|
179
273
|
block: true,
|
|
180
274
|
onClick: onNext,
|
|
181
|
-
loading: confirmLoading
|
|
275
|
+
loading: confirmLoading,
|
|
276
|
+
className: disabled ? 'pisell-scan-order-cart-embedded-confirm-disabled' : undefined
|
|
182
277
|
}, confirmOrderText)));
|
|
183
278
|
}
|
|
184
279
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
@@ -188,16 +283,26 @@ export default function Cart(props) {
|
|
|
188
283
|
className: "pisell-scan-order-cart-drawer"
|
|
189
284
|
}, /*#__PURE__*/React.createElement("div", {
|
|
190
285
|
className: "pisell-scan-order-cart-header"
|
|
191
|
-
}, /*#__PURE__*/React.createElement("
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
},
|
|
286
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
287
|
+
className: "pisell-scan-order-cart-sheet-handle-wrap",
|
|
288
|
+
"aria-hidden": true
|
|
289
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
290
|
+
className: "pisell-scan-order-cart-sheet-handle"
|
|
291
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
292
|
+
className: "pisell-scan-order-cart-list-scroll"
|
|
293
|
+
}, cartLineItems), /*#__PURE__*/React.createElement("div", {
|
|
294
|
+
className: "pisell-scan-order-cart-bottom-panel"
|
|
295
|
+
}, cartSubtotalSection, /*#__PURE__*/React.createElement("div", {
|
|
195
296
|
className: "pisell-scan-order-cart-footer"
|
|
196
297
|
}, /*#__PURE__*/React.createElement("div", {
|
|
197
|
-
className: "pisell-scan-order-cart-total"
|
|
198
|
-
},
|
|
298
|
+
className: "pisell-scan-order-cart-footer-total-col"
|
|
299
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
300
|
+
className: "pisell-scan-order-cart-footer-total-label"
|
|
301
|
+
}, locales.getText('pisell2.event.total')), /*#__PURE__*/React.createElement("div", {
|
|
302
|
+
className: "pisell-scan-order-cart-footer-total-amount"
|
|
303
|
+
}, "$", totalDisplayAmount)), /*#__PURE__*/React.createElement(Button, {
|
|
199
304
|
type: "primary",
|
|
200
305
|
onClick: onNext,
|
|
201
306
|
loading: confirmLoading
|
|
202
|
-
}, locales.getText('pisell2.event.continue')))));
|
|
307
|
+
}, locales.getText('pisell2.event.continue'))))));
|
|
203
308
|
}
|
|
@@ -11,19 +11,51 @@
|
|
|
11
11
|
right: 0;
|
|
12
12
|
bottom: 0;
|
|
13
13
|
z-index: 91;
|
|
14
|
-
max-height:
|
|
15
|
-
|
|
14
|
+
max-height: 95vh;
|
|
15
|
+
max-height: 95dvh;
|
|
16
|
+
min-height: 0;
|
|
17
|
+
border-radius: 12px 12px 0 0;
|
|
16
18
|
background: #fff;
|
|
17
19
|
display: flex;
|
|
18
20
|
flex-direction: column;
|
|
21
|
+
overflow: hidden;
|
|
22
|
+
box-shadow: 0 -8px 40px rgba(16, 24, 40, 0.12);
|
|
19
23
|
}
|
|
20
24
|
|
|
25
|
+
/* 顶栏仅保留居中拖动手柄横线 */
|
|
21
26
|
.pisell-scan-order-cart-header {
|
|
27
|
+
flex-shrink: 0;
|
|
28
|
+
padding: 0;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.pisell-scan-order-cart-sheet-handle-wrap {
|
|
32
|
+
width: 100%;
|
|
22
33
|
display: flex;
|
|
23
|
-
justify-content:
|
|
34
|
+
justify-content: center;
|
|
24
35
|
align-items: center;
|
|
25
|
-
padding:
|
|
26
|
-
|
|
36
|
+
padding: 10px 0 8px;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.pisell-scan-order-cart-sheet-handle {
|
|
40
|
+
width: 36px;
|
|
41
|
+
height: 5px;
|
|
42
|
+
border-radius: 100px;
|
|
43
|
+
background: #d0d5dd;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.pisell-scan-order-cart-list-scroll {
|
|
47
|
+
flex: 1;
|
|
48
|
+
min-height: 0;
|
|
49
|
+
overflow-y: auto;
|
|
50
|
+
-webkit-overflow-scrolling: touch;
|
|
51
|
+
padding: 8px 16px 12px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.pisell-scan-order-cart-bottom-panel {
|
|
55
|
+
flex-shrink: 0;
|
|
56
|
+
border-top: 1px solid #eaecf0;
|
|
57
|
+
background: #fff;
|
|
58
|
+
padding: 12px 16px 0;
|
|
27
59
|
}
|
|
28
60
|
|
|
29
61
|
.pisell-scan-order-cart-body {
|
|
@@ -49,14 +81,30 @@
|
|
|
49
81
|
justify-content: space-between;
|
|
50
82
|
align-items: center;
|
|
51
83
|
gap: 12px;
|
|
52
|
-
|
|
84
|
+
margin-top: 12px;
|
|
85
|
+
padding: 12px 0 calc(16px + env(safe-area-inset-bottom, 0px));
|
|
53
86
|
border-top: 1px solid #eaecf0;
|
|
54
87
|
}
|
|
55
88
|
|
|
56
|
-
|
|
89
|
+
/* 与 pisell-scan-order-footer 左侧合计样式一致 */
|
|
90
|
+
.pisell-scan-order-cart-footer-total-col {
|
|
91
|
+
display: flex;
|
|
92
|
+
flex-direction: column;
|
|
93
|
+
justify-content: center;
|
|
94
|
+
min-width: 0;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.pisell-scan-order-cart-footer-total-label {
|
|
57
98
|
color: #101828;
|
|
58
99
|
font-size: 14px;
|
|
59
|
-
|
|
100
|
+
line-height: 20px;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.pisell-scan-order-cart-footer-total-amount {
|
|
104
|
+
color: #e77d75;
|
|
105
|
+
font-size: 24px;
|
|
106
|
+
font-weight: 600;
|
|
107
|
+
line-height: 1;
|
|
60
108
|
}
|
|
61
109
|
|
|
62
110
|
.pisell-scan-order-cart-embedded-footer {
|
|
@@ -65,16 +113,27 @@
|
|
|
65
113
|
background: #fff;
|
|
66
114
|
}
|
|
67
115
|
|
|
116
|
+
.pisell-scan-order-cart-embedded-confirm-disabled {
|
|
117
|
+
opacity: 0.45;
|
|
118
|
+
cursor: not-allowed;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
/* 移动端:结算内嵌卡 — 与 pisell-scan-order-content-mobile-wrap 的底部留白配合;
|
|
122
|
+
* 不再在 cart-body 上重复 96px,否则与外层叠加会出现大块空白,sticky 在整页滚动时也会与内容同步位移 */
|
|
68
123
|
.pisell-scan-order-content-mobile-wrap {
|
|
69
|
-
.pisell-scan-order-cart-body {
|
|
70
|
-
padding-bottom:
|
|
124
|
+
.pisell-scan-order-cart-body-embedded {
|
|
125
|
+
padding-bottom: 16px;
|
|
71
126
|
}
|
|
72
127
|
|
|
73
128
|
.pisell-scan-order-cart-embedded-footer {
|
|
74
|
-
position:
|
|
129
|
+
position: fixed;
|
|
130
|
+
left: 0;
|
|
131
|
+
right: 0;
|
|
75
132
|
bottom: 0;
|
|
76
|
-
z-index:
|
|
77
|
-
padding
|
|
133
|
+
z-index: 28;
|
|
134
|
+
padding: 12px 16px calc(20px + env(safe-area-inset-bottom, 0px));
|
|
135
|
+
border-top: 1px solid #eaecf0;
|
|
136
|
+
background: #fff;
|
|
78
137
|
box-shadow: 0 -4px 10px rgba(16, 24, 40, 0.06);
|
|
79
138
|
}
|
|
80
139
|
}
|