@pisell/private-materials 6.4.59 → 6.4.60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +2 -2
- package/build/lowcode/preview.js +7 -7
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +7 -7
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +7 -7
- package/es/components/booking/components/actionButtons/index.js +7 -15
- package/es/components/booking/components/footer/index.d.ts +0 -1
- package/es/components/booking/components/footer/index.js +2 -2
- package/es/components/booking/components/voucher/index.js +19 -23
- package/es/components/booking/info/service2/utils.d.ts +1 -1
- package/es/components/booking/info2/cartClientCard/index.js +3 -7
- package/es/components/booking/utils.d.ts +2 -2
- package/es/components/checkout/PaymentModal.js +12 -17
- package/es/components/checkout/hooks/useWalletPass.js +21 -36
- package/es/components/eftposPay/amount.d.ts +1 -1
- package/es/components/eftposPay/device.d.ts +1 -1
- package/es/components/eftposPay/hooks.d.ts +1 -1
- package/es/components/eftposPay/linkly/index.d.ts +1 -0
- package/es/components/eftposPay/store/index.d.ts +4 -4
- package/es/components/pay/toB/store/hooks.js +5 -19
- package/es/components/ticketBooking/components/addServiceVariant/addService.d.ts +0 -20
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +12 -47
- package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -2
- package/es/components/ticketBooking/components/addServiceVariant/index.js +2 -4
- package/es/components/ticketBooking/components/menuBar/index.d.ts +1 -5
- package/es/components/ticketBooking/components/menuBar/index.js +21 -45
- package/es/components/ticketBooking/components/menuBar/index.less +1 -32
- package/es/components/ticketBooking/components/ticketBooking/index.d.ts +1 -6
- package/es/components/ticketBooking/components/ticketBooking/index.js +23 -66
- package/es/components/ticketBooking/components/timeBar/index.d.ts +1 -0
- package/es/components/ticketBooking/components/timeBar/index.less +0 -1
- package/es/components/ticketBooking/hooks/pisellos/bookingTicket.d.ts +0 -5
- package/es/components/ticketBooking/hooks/pisellos/bookingTicket.js +1 -13
- package/es/components/ticketBooking/hooks/pisellos/index.d.ts +0 -1
- package/es/components/ticketBooking/hooks/pisellos/index.js +1 -2
- package/es/components/ticketBooking/hooks/pisellos/useCustomer.js +4 -12
- package/es/components/ticketBooking/hooks/pisellos/useProducts.d.ts +1 -1
- package/es/components/ticketBooking/hooks/pisellos/useProducts.js +10 -52
- package/es/components/ticketBooking/hooks/pisellos/useScanCustomer.js +2 -5
- package/es/components/ticketBooking/hooks/pisellos/useScanGlobal.js +2 -7
- package/es/components/ticketBooking/index.d.ts +0 -6
- package/es/components/ticketBooking/index.js +11 -86
- package/es/components/ticketBooking/utils/index.d.ts +2 -30
- package/es/components/ticketBooking/utils/index.js +1 -50
- package/es/index.d.ts +0 -2
- package/es/index.js +1 -3
- package/es/plus/productSelect/components/pisellPriceText/index.d.ts +0 -2
- package/es/plus/productSelect/components/pisellPriceText/index.js +5 -7
- package/lib/components/booking/components/actionButtons/index.js +15 -22
- package/lib/components/booking/components/footer/index.d.ts +0 -1
- package/lib/components/booking/components/footer/index.js +2 -2
- package/lib/components/booking/components/voucher/index.js +40 -33
- package/lib/components/booking/info/service2/utils.d.ts +1 -1
- package/lib/components/booking/info2/cartClientCard/index.js +3 -7
- package/lib/components/booking/utils.d.ts +2 -2
- package/lib/components/checkout/PaymentModal.js +12 -15
- package/lib/components/checkout/hooks/useWalletPass.js +45 -57
- package/lib/components/eftposPay/amount.d.ts +1 -1
- package/lib/components/eftposPay/device.d.ts +1 -1
- package/lib/components/eftposPay/hooks.d.ts +1 -1
- package/lib/components/eftposPay/linkly/index.d.ts +1 -0
- package/lib/components/eftposPay/store/index.d.ts +4 -4
- package/lib/components/pay/toB/store/hooks.js +8 -16
- package/lib/components/ticketBooking/components/addServiceVariant/addService.d.ts +0 -20
- package/lib/components/ticketBooking/components/addServiceVariant/addService.js +12 -47
- package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -2
- package/lib/components/ticketBooking/components/addServiceVariant/index.js +2 -3
- package/lib/components/ticketBooking/components/menuBar/index.d.ts +1 -5
- package/lib/components/ticketBooking/components/menuBar/index.js +22 -29
- package/lib/components/ticketBooking/components/menuBar/index.less +1 -32
- package/lib/components/ticketBooking/components/ticketBooking/index.d.ts +1 -6
- package/lib/components/ticketBooking/components/ticketBooking/index.js +25 -56
- package/lib/components/ticketBooking/components/timeBar/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/timeBar/index.less +0 -1
- package/lib/components/ticketBooking/hooks/pisellos/bookingTicket.d.ts +0 -5
- package/lib/components/ticketBooking/hooks/pisellos/bookingTicket.js +1 -5
- package/lib/components/ticketBooking/hooks/pisellos/index.d.ts +0 -1
- package/lib/components/ticketBooking/hooks/pisellos/index.js +1 -3
- package/lib/components/ticketBooking/hooks/pisellos/useCustomer.js +10 -17
- package/lib/components/ticketBooking/hooks/pisellos/useProducts.d.ts +1 -1
- package/lib/components/ticketBooking/hooks/pisellos/useProducts.js +5 -35
- package/lib/components/ticketBooking/hooks/pisellos/useScanCustomer.js +2 -4
- package/lib/components/ticketBooking/hooks/pisellos/useScanGlobal.js +2 -6
- package/lib/components/ticketBooking/index.d.ts +0 -6
- package/lib/components/ticketBooking/index.js +8 -64
- package/lib/components/ticketBooking/utils/index.d.ts +2 -30
- package/lib/components/ticketBooking/utils/index.js +2 -70
- package/lib/index.d.ts +0 -2
- package/lib/index.js +0 -6
- package/lib/plus/productSelect/components/pisellPriceText/index.d.ts +0 -2
- package/lib/plus/productSelect/components/pisellPriceText/index.js +5 -6
- package/package.json +1 -1
- package/es/components/list/List.d.ts +0 -5
- package/es/components/list/List.js +0 -957
- package/es/components/list/List.less +0 -2
- package/es/components/list/ResponsiveWrapper.d.ts +0 -16
- package/es/components/list/ResponsiveWrapper.js +0 -130
- package/es/components/list/TestResponsiveWrapper.d.ts +0 -8
- package/es/components/list/TestResponsiveWrapper.js +0 -816
- package/es/components/list/TestResponsiveWrapper.less +0 -968
- package/es/components/list/components/EmptyState/EmptyState.d.ts +0 -20
- package/es/components/list/components/EmptyState/EmptyState.js +0 -75
- package/es/components/list/components/EmptyState/EmptyState.less +0 -121
- package/es/components/list/components/EmptyState/index.d.ts +0 -2
- package/es/components/list/components/EmptyState/index.js +0 -1
- package/es/components/list/components/ListItemSkeleton/ListItemSkeleton.d.ts +0 -13
- package/es/components/list/components/ListItemSkeleton/ListItemSkeleton.js +0 -39
- package/es/components/list/components/ListItemSkeleton/ListItemSkeleton.less +0 -29
- package/es/components/list/components/ListItemSkeleton/index.d.ts +0 -2
- package/es/components/list/components/ListItemSkeleton/index.js +0 -2
- package/es/components/list/components/Pagination/Pagination.d.ts +0 -30
- package/es/components/list/components/Pagination/Pagination.js +0 -240
- package/es/components/list/components/Pagination/Pagination.less +0 -439
- package/es/components/list/components/Pagination/index.d.ts +0 -1
- package/es/components/list/components/Pagination/index.js +0 -1
- package/es/components/list/components/ScrollLoader/ScrollLoader.d.ts +0 -18
- package/es/components/list/components/ScrollLoader/ScrollLoader.js +0 -18
- package/es/components/list/components/ScrollLoader/ScrollLoader.less +0 -3
- package/es/components/list/components/ScrollLoader/index.d.ts +0 -2
- package/es/components/list/components/ScrollLoader/index.js +0 -1
- package/es/components/list/components/Tab/Tab.d.ts +0 -5
- package/es/components/list/components/Tab/Tab.js +0 -43
- package/es/components/list/components/Tab/Tab.less +0 -139
- package/es/components/list/components/Tab/index.d.ts +0 -2
- package/es/components/list/components/Tab/index.js +0 -1
- package/es/components/list/components/Tab/types.d.ts +0 -14
- package/es/components/list/components/Tab/types.js +0 -1
- package/es/components/list/components/TabSkeleton/TabSkeleton.d.ts +0 -11
- package/es/components/list/components/TabSkeleton/TabSkeleton.js +0 -28
- package/es/components/list/components/TabSkeleton/TabSkeleton.less +0 -38
- package/es/components/list/components/TabSkeleton/index.d.ts +0 -2
- package/es/components/list/components/TabSkeleton/index.js +0 -2
- package/es/components/list/components/WaterfallList/WaterfallList.d.ts +0 -33
- package/es/components/list/components/WaterfallList/WaterfallList.js +0 -191
- package/es/components/list/components/WaterfallList/WaterfallList.less +0 -201
- package/es/components/list/components/WaterfallList/index.d.ts +0 -2
- package/es/components/list/components/WaterfallList/index.js +0 -1
- package/es/components/list/examples/GroupedListExample.d.ts +0 -3
- package/es/components/list/examples/GroupedListExample.js +0 -207
- package/es/components/list/hooks/index.d.ts +0 -5
- package/es/components/list/hooks/index.js +0 -3
- package/es/components/list/hooks/useDevice.d.ts +0 -24
- package/es/components/list/hooks/useDevice.js +0 -102
- package/es/components/list/hooks/useListState.d.ts +0 -43
- package/es/components/list/hooks/useListState.js +0 -176
- package/es/components/list/hooks/useWaterfall.d.ts +0 -34
- package/es/components/list/hooks/useWaterfall.js +0 -161
- package/es/components/list/index.d.ts +0 -10
- package/es/components/list/index.js +0 -7
- package/es/components/list/locales.d.ts +0 -66
- package/es/components/list/locales.js +0 -107
- package/es/components/list/styles/base.less +0 -39
- package/es/components/list/styles/content.less +0 -416
- package/es/components/list/styles/floatButton.less +0 -107
- package/es/components/list/styles/footer.less +0 -49
- package/es/components/list/styles/header.less +0 -69
- package/es/components/list/styles/responsive.less +0 -166
- package/es/components/list/types.d.ts +0 -177
- package/es/components/list/types.js +0 -1
- package/es/components/list/utils/getText.d.ts +0 -53
- package/es/components/list/utils/getText.js +0 -150
- package/es/components/list/utils/index.d.ts +0 -4
- package/es/components/list/utils/index.js +0 -5
- package/es/components/ticketBooking/components/ProductDisplayAdapter/ProductDisplayAdapter.d.ts +0 -27
- package/es/components/ticketBooking/components/ProductDisplayAdapter/ProductDisplayAdapter.js +0 -143
- package/es/components/ticketBooking/components/ProductDisplayAdapter/index.d.ts +0 -7
- package/es/components/ticketBooking/components/ProductDisplayAdapter/index.js +0 -7
- package/es/components/ticketBooking/components/ProductDisplayAdapter/index.less +0 -41
- package/es/components/ticketBooking/components/ProductDisplayAdapter/types.d.ts +0 -115
- package/es/components/ticketBooking/components/ProductDisplayAdapter/types.js +0 -273
- package/es/components/ticketBooking/components/ProductDisplayAdapter/utils.d.ts +0 -50
- package/es/components/ticketBooking/components/ProductDisplayAdapter/utils.js +0 -130
- package/es/components/ticketBooking/context/IsActiveContext.d.ts +0 -26
- package/es/components/ticketBooking/context/IsActiveContext.js +0 -37
- package/es/components/ticketBooking/context/OsKeyContext.d.ts +0 -26
- package/es/components/ticketBooking/context/OsKeyContext.js +0 -37
- package/es/components/ticketBooking/context/index.d.ts +0 -2
- package/es/components/ticketBooking/context/index.js +0 -2
- package/es/components/ticketBooking/hooks/pisellos/useActiveExecute.d.ts +0 -21
- package/es/components/ticketBooking/hooks/pisellos/useActiveExecute.js +0 -50
- package/es/components/ticketBooking/hooks/pisellos/useShopDiscountModule.d.ts +0 -6
- package/es/components/ticketBooking/hooks/pisellos/useShopDiscountModule.js +0 -17
- package/es/components/ticketBooking/utils/productCache.d.ts +0 -75
- package/es/components/ticketBooking/utils/productCache.js +0 -184
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.js +0 -11
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.less +0 -8
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.js +0 -11
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.less +0 -17
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.js +0 -11
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.less +0 -17
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.js +0 -11
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.less +0 -17
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.js +0 -11
- package/es/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.less +0 -2
- package/es/plus/productSelect/ProductCard/SkuCard/components/Action/index.d.ts +0 -8
- package/es/plus/productSelect/ProductCard/SkuCard/components/Action/index.js +0 -100
- package/es/plus/productSelect/ProductCard/SkuCard/components/Action/index.less +0 -8
- package/es/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +0 -6
- package/es/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.js +0 -32
- package/es/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.less +0 -3
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.d.ts +0 -8
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.js +0 -239
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.less +0 -44
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.js +0 -34
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.less +0 -14
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.js +0 -33
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.less +0 -30
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.d.ts +0 -5
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.js +0 -75
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.less +0 -46
- package/es/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.js +0 -39
- package/es/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.less +0 -9
- package/es/plus/productSelect/ProductCard/SkuCard/components/Cover/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Cover/index.js +0 -53
- package/es/plus/productSelect/ProductCard/SkuCard/components/Cover/index.less +0 -31
- package/es/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +0 -6
- package/es/plus/productSelect/ProductCard/SkuCard/components/Duration/index.js +0 -31
- package/es/plus/productSelect/ProductCard/SkuCard/components/Duration/index.less +0 -3
- package/es/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.js +0 -58
- package/es/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.less +0 -11
- package/es/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.js +0 -85
- package/es/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.less +0 -24
- package/es/plus/productSelect/ProductCard/SkuCard/components/Price/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Price/index.js +0 -121
- package/es/plus/productSelect/ProductCard/SkuCard/components/Price/index.less +0 -57
- package/es/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.js +0 -95
- package/es/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.less +0 -18
- package/es/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +0 -6
- package/es/plus/productSelect/ProductCard/SkuCard/components/Resource/index.js +0 -31
- package/es/plus/productSelect/ProductCard/SkuCard/components/Resource/index.less +0 -3
- package/es/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +0 -6
- package/es/plus/productSelect/ProductCard/SkuCard/components/Stock/index.js +0 -47
- package/es/plus/productSelect/ProductCard/SkuCard/components/Stock/index.less +0 -3
- package/es/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.js +0 -34
- package/es/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.less +0 -13
- package/es/plus/productSelect/ProductCard/SkuCard/components/Tags/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Tags/index.js +0 -95
- package/es/plus/productSelect/ProductCard/SkuCard/components/Tags/index.less +0 -18
- package/es/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +0 -6
- package/es/plus/productSelect/ProductCard/SkuCard/components/Time/index.js +0 -31
- package/es/plus/productSelect/ProductCard/SkuCard/components/Time/index.less +0 -3
- package/es/plus/productSelect/ProductCard/SkuCard/components/Title/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/Title/index.js +0 -34
- package/es/plus/productSelect/ProductCard/SkuCard/components/Title/index.less +0 -13
- package/es/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.d.ts +0 -7
- package/es/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.js +0 -39
- package/es/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.less +0 -22
- package/es/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.d.ts +0 -4
- package/es/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.js +0 -20
- package/es/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.less +0 -20
- package/es/plus/productSelect/ProductCard/SkuCard/hooks/useDynamicComponents.d.ts +0 -6
- package/es/plus/productSelect/ProductCard/SkuCard/hooks/useDynamicComponents.js +0 -55
- package/es/plus/productSelect/ProductCard/SkuCard/index.d.ts +0 -9
- package/es/plus/productSelect/ProductCard/SkuCard/index.js +0 -38
- package/es/plus/productSelect/ProductCard/SkuCard/locales.d.ts +0 -42
- package/es/plus/productSelect/ProductCard/SkuCard/locales.js +0 -41
- package/es/plus/productSelect/ProductCard/SkuCard/status.d.ts +0 -162
- package/es/plus/productSelect/ProductCard/SkuCard/status.js +0 -481
- package/es/plus/productSelect/ProductCard/SkuCard/type.d.ts +0 -298
- package/es/plus/productSelect/ProductCard/SkuCard/type.js +0 -1
- package/es/plus/productSelect/ProductCard/SkuCard/utils.d.ts +0 -9
- package/es/plus/productSelect/ProductCard/SkuCard/utils.js +0 -21
- package/lib/components/list/List.d.ts +0 -5
- package/lib/components/list/List.js +0 -771
- package/lib/components/list/List.less +0 -2
- package/lib/components/list/ResponsiveWrapper.d.ts +0 -16
- package/lib/components/list/ResponsiveWrapper.js +0 -145
- package/lib/components/list/TestResponsiveWrapper.d.ts +0 -8
- package/lib/components/list/TestResponsiveWrapper.js +0 -493
- package/lib/components/list/TestResponsiveWrapper.less +0 -968
- package/lib/components/list/components/EmptyState/EmptyState.d.ts +0 -20
- package/lib/components/list/components/EmptyState/EmptyState.js +0 -75
- package/lib/components/list/components/EmptyState/EmptyState.less +0 -121
- package/lib/components/list/components/EmptyState/index.d.ts +0 -2
- package/lib/components/list/components/EmptyState/index.js +0 -35
- package/lib/components/list/components/ListItemSkeleton/ListItemSkeleton.d.ts +0 -13
- package/lib/components/list/components/ListItemSkeleton/ListItemSkeleton.js +0 -75
- package/lib/components/list/components/ListItemSkeleton/ListItemSkeleton.less +0 -29
- package/lib/components/list/components/ListItemSkeleton/index.d.ts +0 -2
- package/lib/components/list/components/ListItemSkeleton/index.js +0 -41
- package/lib/components/list/components/Pagination/Pagination.d.ts +0 -30
- package/lib/components/list/components/Pagination/Pagination.js +0 -205
- package/lib/components/list/components/Pagination/Pagination.less +0 -439
- package/lib/components/list/components/Pagination/index.d.ts +0 -1
- package/lib/components/list/components/Pagination/index.js +0 -35
- package/lib/components/list/components/ScrollLoader/ScrollLoader.d.ts +0 -18
- package/lib/components/list/components/ScrollLoader/ScrollLoader.js +0 -37
- package/lib/components/list/components/ScrollLoader/ScrollLoader.less +0 -3
- package/lib/components/list/components/ScrollLoader/index.d.ts +0 -2
- package/lib/components/list/components/ScrollLoader/index.js +0 -35
- package/lib/components/list/components/Tab/Tab.d.ts +0 -5
- package/lib/components/list/components/Tab/Tab.js +0 -72
- package/lib/components/list/components/Tab/Tab.less +0 -139
- package/lib/components/list/components/Tab/index.d.ts +0 -2
- package/lib/components/list/components/Tab/index.js +0 -35
- package/lib/components/list/components/Tab/types.d.ts +0 -14
- package/lib/components/list/components/Tab/types.js +0 -17
- package/lib/components/list/components/TabSkeleton/TabSkeleton.d.ts +0 -11
- package/lib/components/list/components/TabSkeleton/TabSkeleton.js +0 -61
- package/lib/components/list/components/TabSkeleton/TabSkeleton.less +0 -38
- package/lib/components/list/components/TabSkeleton/index.d.ts +0 -2
- package/lib/components/list/components/TabSkeleton/index.js +0 -41
- package/lib/components/list/components/WaterfallList/WaterfallList.d.ts +0 -33
- package/lib/components/list/components/WaterfallList/WaterfallList.js +0 -178
- package/lib/components/list/components/WaterfallList/WaterfallList.less +0 -201
- package/lib/components/list/components/WaterfallList/index.d.ts +0 -2
- package/lib/components/list/components/WaterfallList/index.js +0 -35
- package/lib/components/list/examples/GroupedListExample.d.ts +0 -3
- package/lib/components/list/examples/GroupedListExample.js +0 -210
- package/lib/components/list/hooks/index.d.ts +0 -5
- package/lib/components/list/hooks/index.js +0 -47
- package/lib/components/list/hooks/useDevice.d.ts +0 -24
- package/lib/components/list/hooks/useDevice.js +0 -96
- package/lib/components/list/hooks/useListState.d.ts +0 -43
- package/lib/components/list/hooks/useListState.js +0 -149
- package/lib/components/list/hooks/useWaterfall.d.ts +0 -34
- package/lib/components/list/hooks/useWaterfall.js +0 -124
- package/lib/components/list/index.d.ts +0 -10
- package/lib/components/list/index.js +0 -60
- package/lib/components/list/locales.d.ts +0 -66
- package/lib/components/list/locales.js +0 -113
- package/lib/components/list/styles/base.less +0 -39
- package/lib/components/list/styles/content.less +0 -416
- package/lib/components/list/styles/floatButton.less +0 -107
- package/lib/components/list/styles/footer.less +0 -49
- package/lib/components/list/styles/header.less +0 -69
- package/lib/components/list/styles/responsive.less +0 -166
- package/lib/components/list/types.d.ts +0 -177
- package/lib/components/list/types.js +0 -17
- package/lib/components/list/utils/getText.d.ts +0 -53
- package/lib/components/list/utils/getText.js +0 -95
- package/lib/components/list/utils/index.d.ts +0 -4
- package/lib/components/list/utils/index.js +0 -43
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/ProductDisplayAdapter.d.ts +0 -27
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/ProductDisplayAdapter.js +0 -165
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/index.d.ts +0 -7
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/index.js +0 -45
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/index.less +0 -41
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/types.d.ts +0 -115
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/types.js +0 -247
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/utils.d.ts +0 -50
- package/lib/components/ticketBooking/components/ProductDisplayAdapter/utils.js +0 -100
- package/lib/components/ticketBooking/context/IsActiveContext.d.ts +0 -26
- package/lib/components/ticketBooking/context/IsActiveContext.js +0 -56
- package/lib/components/ticketBooking/context/OsKeyContext.d.ts +0 -26
- package/lib/components/ticketBooking/context/OsKeyContext.js +0 -56
- package/lib/components/ticketBooking/context/index.d.ts +0 -2
- package/lib/components/ticketBooking/context/index.js +0 -44
- package/lib/components/ticketBooking/hooks/pisellos/useActiveExecute.d.ts +0 -21
- package/lib/components/ticketBooking/hooks/pisellos/useActiveExecute.js +0 -47
- package/lib/components/ticketBooking/hooks/pisellos/useShopDiscountModule.d.ts +0 -6
- package/lib/components/ticketBooking/hooks/pisellos/useShopDiscountModule.js +0 -37
- package/lib/components/ticketBooking/utils/productCache.d.ts +0 -75
- package/lib/components/ticketBooking/utils/productCache.js +0 -144
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.js +0 -42
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.less +0 -8
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.js +0 -42
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.less +0 -17
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.js +0 -42
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.less +0 -17
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.js +0 -42
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.less +0 -17
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.js +0 -42
- package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.less +0 -2
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Action/index.d.ts +0 -8
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Action/index.js +0 -129
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Action/index.less +0 -8
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +0 -6
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.js +0 -52
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.less +0 -3
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.d.ts +0 -8
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.js +0 -178
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.less +0 -44
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.js +0 -52
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.less +0 -14
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.js +0 -63
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.less +0 -30
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.d.ts +0 -5
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.js +0 -131
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.less +0 -46
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.js +0 -62
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.less +0 -9
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Cover/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Cover/index.js +0 -78
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Cover/index.less +0 -31
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +0 -6
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Duration/index.js +0 -51
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Duration/index.less +0 -3
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.js +0 -94
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.less +0 -11
- package/lib/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.js +0 -115
- package/lib/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.less +0 -24
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Price/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Price/index.js +0 -139
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Price/index.less +0 -57
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.js +0 -97
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.less +0 -18
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +0 -6
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Resource/index.js +0 -51
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Resource/index.less +0 -3
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +0 -6
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Stock/index.js +0 -58
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Stock/index.less +0 -3
- package/lib/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.js +0 -56
- package/lib/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.less +0 -13
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Tags/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Tags/index.js +0 -97
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Tags/index.less +0 -18
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +0 -6
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Time/index.js +0 -51
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Time/index.less +0 -3
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Title/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Title/index.js +0 -56
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Title/index.less +0 -13
- package/lib/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.d.ts +0 -7
- package/lib/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.js +0 -58
- package/lib/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.less +0 -22
- package/lib/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.d.ts +0 -4
- package/lib/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.js +0 -49
- package/lib/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.less +0 -20
- package/lib/plus/productSelect/ProductCard/SkuCard/hooks/useDynamicComponents.d.ts +0 -6
- package/lib/plus/productSelect/ProductCard/SkuCard/hooks/useDynamicComponents.js +0 -83
- package/lib/plus/productSelect/ProductCard/SkuCard/index.d.ts +0 -9
- package/lib/plus/productSelect/ProductCard/SkuCard/index.js +0 -68
- package/lib/plus/productSelect/ProductCard/SkuCard/locales.d.ts +0 -42
- package/lib/plus/productSelect/ProductCard/SkuCard/locales.js +0 -65
- package/lib/plus/productSelect/ProductCard/SkuCard/status.d.ts +0 -162
- package/lib/plus/productSelect/ProductCard/SkuCard/status.js +0 -501
- package/lib/plus/productSelect/ProductCard/SkuCard/type.d.ts +0 -298
- package/lib/plus/productSelect/ProductCard/SkuCard/type.js +0 -17
- package/lib/plus/productSelect/ProductCard/SkuCard/utils.d.ts +0 -9
- package/lib/plus/productSelect/ProductCard/SkuCard/utils.js +0 -37
- package/lowcode/sku-card/meta.ts +0 -1812
- package/lowcode/sku-card/snippets.ts +0 -372
- package/lowcode/sku-list/meta.ts +0 -410
|
@@ -32,8 +32,6 @@ import { useMemoizedFn } from 'ahooks';
|
|
|
32
32
|
import useEngineContext, { usePisellOS } from "../../../../hooks/useEngineContext";
|
|
33
33
|
import useScanManager from "../../../ticketBooking/hooks/pisellos/useScanManager";
|
|
34
34
|
import { DiscountKeyboard } from "../../../../pro/priceKeyboard";
|
|
35
|
-
import { useActiveExecute, useBookingTicket } from "../../../ticketBooking/hooks/pisellos";
|
|
36
|
-
import { useShopDiscountModule } from "../../../ticketBooking/hooks/pisellos/useShopDiscountModule";
|
|
37
35
|
// Toast 内容包装器,统一设置行高
|
|
38
36
|
var createToastContent = function createToastContent(text) {
|
|
39
37
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -63,17 +61,13 @@ var ActionButtons = function ActionButtons(_ref) {
|
|
|
63
61
|
_useState8 = _slicedToArray(_useState7, 2),
|
|
64
62
|
showVoucherModal = _useState8[0],
|
|
65
63
|
setShowVoucherModal = _useState8[1];
|
|
66
|
-
var _useActiveExecute = useActiveExecute(),
|
|
67
|
-
executeIfActive = _useActiveExecute.executeIfActive;
|
|
68
64
|
var context = useEngineContext();
|
|
69
65
|
var _context$appHelper$ut = (_context$appHelper = context.appHelper) === null || _context$appHelper === void 0 ? void 0 : _context$appHelper.utils,
|
|
70
66
|
getData = _context$appHelper$ut.getData,
|
|
71
67
|
pisellosAllModule = _context$appHelper$ut.pisellosAllModule;
|
|
72
68
|
var Toast = useToast();
|
|
73
69
|
var pisellOS = usePisellOS();
|
|
74
|
-
var bookingTicket = useBookingTicket();
|
|
75
70
|
var ScheduleModule = pisellosAllModule.ScheduleModule;
|
|
76
|
-
var shopDiscount = useShopDiscountModule();
|
|
77
71
|
|
|
78
72
|
// 将选中的客户数据传递给状态管理
|
|
79
73
|
var changeCustomerToGlobalState = useMemoizedFn(function (value) {
|
|
@@ -94,7 +88,7 @@ var ActionButtons = function ActionButtons(_ref) {
|
|
|
94
88
|
|
|
95
89
|
// 监听客户选择变化,清空手动折扣
|
|
96
90
|
useEffect(function () {
|
|
97
|
-
if (!
|
|
91
|
+
if (!pisellOS) return;
|
|
98
92
|
var handleCustomerSelected = function handleCustomerSelected() {
|
|
99
93
|
// 当客户选择改变时,清空 shop_discount
|
|
100
94
|
dispatch({
|
|
@@ -104,16 +98,15 @@ var ActionButtons = function ActionButtons(_ref) {
|
|
|
104
98
|
}
|
|
105
99
|
});
|
|
106
100
|
};
|
|
107
|
-
var wrappedHandleCustomerSelected = executeIfActive(handleCustomerSelected);
|
|
108
101
|
|
|
109
102
|
// 监听客户选择事件
|
|
110
|
-
|
|
103
|
+
pisellOS.effects.on('bookingTicket:onCustomerSelected', handleCustomerSelected);
|
|
111
104
|
|
|
112
105
|
// 清理函数
|
|
113
106
|
return function () {
|
|
114
|
-
|
|
107
|
+
pisellOS.effects.off('bookingTicket:onCustomerSelected', handleCustomerSelected);
|
|
115
108
|
};
|
|
116
|
-
}, [dispatch,
|
|
109
|
+
}, [dispatch, pisellOS]);
|
|
117
110
|
|
|
118
111
|
// 同步获取金额计算所需配置
|
|
119
112
|
var getDataFromHost = function getDataFromHost() {
|
|
@@ -229,14 +222,13 @@ var ActionButtons = function ActionButtons(_ref) {
|
|
|
229
222
|
var _context$appHelper2;
|
|
230
223
|
var _ref2 = ((_context$appHelper2 = context.appHelper) === null || _context$appHelper2 === void 0 ? void 0 : _context$appHelper2.utils) || {},
|
|
231
224
|
pisellos = _ref2.pisellos;
|
|
232
|
-
if (!pisellos
|
|
225
|
+
if (!pisellos) return;
|
|
233
226
|
var onDiscountListChange = function onDiscountListChange(discount) {
|
|
234
227
|
setDiscountList(discount);
|
|
235
228
|
};
|
|
236
|
-
|
|
237
|
-
shopDiscount.effectsOn('onDiscountListChange', wrappedHandler);
|
|
229
|
+
pisellos.effects.on('shopDiscount:onDiscountListChange', onDiscountListChange);
|
|
238
230
|
return function () {
|
|
239
|
-
|
|
231
|
+
pisellos.effects.off('shopDiscount:onDiscountListChange', onDiscountListChange);
|
|
240
232
|
};
|
|
241
233
|
}, [(_context$appHelper3 = context.appHelper) === null || _context$appHelper3 === void 0 ? void 0 : _context$appHelper3.utils]);
|
|
242
234
|
|
|
@@ -46,7 +46,7 @@ import { Iconfont } from '@pisell/materials';
|
|
|
46
46
|
import { useCustomer } from "../../../ticketBooking/hooks/pisellos/useCustomer";
|
|
47
47
|
import { useDebounceEffect, useDebounceFn, useMemoizedFn } from 'ahooks';
|
|
48
48
|
import { cloneDeep } from 'lodash';
|
|
49
|
-
import {
|
|
49
|
+
import { useShopDiscount } from "../../../appointmentBooking/hooks";
|
|
50
50
|
|
|
51
51
|
/**
|
|
52
52
|
* @title: 底部
|
|
@@ -1734,7 +1734,7 @@ var Footer = function Footer(props) {
|
|
|
1734
1734
|
changeCustomerToGlobalState: changeCustomerToGlobalState
|
|
1735
1735
|
}),
|
|
1736
1736
|
selectCustomer = _useCustomer.selectCustomer;
|
|
1737
|
-
var shopDiscount =
|
|
1737
|
+
var shopDiscount = useShopDiscount();
|
|
1738
1738
|
var _useScanManager2 = useScanManager(),
|
|
1739
1739
|
clearAllScanListenersTaskQueue = _useScanManager2.clearAllScanListenersTaskQueue;
|
|
1740
1740
|
// 清空所有内容并重置购物车
|
|
@@ -28,9 +28,8 @@ import { useIsBooking4Shop } from "../../hooks/useIsBooking4Shop";
|
|
|
28
28
|
import "./index.less";
|
|
29
29
|
import { useMemoizedFn, useDebounceFn, useDebounceEffect } from 'ahooks';
|
|
30
30
|
import { getServiceAddons } from "./utils";
|
|
31
|
-
import {
|
|
31
|
+
import { useCustomer } from "../../../ticketBooking/hooks/pisellos";
|
|
32
32
|
import { getClientVariantClose } from "../../info/clientVariant/utils";
|
|
33
|
-
import { useShopDiscountModule } from "../../../ticketBooking/hooks/pisellos/useShopDiscountModule";
|
|
34
33
|
var ShopDiscountHooks = {
|
|
35
34
|
onInited: 'shopDiscount:onInited',
|
|
36
35
|
onDestroy: 'shopDiscount:onDestroy',
|
|
@@ -67,9 +66,7 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
67
66
|
var serviceValueRef = useRef(state.service.value);
|
|
68
67
|
var addonsValueRef = useRef(state.addons.value);
|
|
69
68
|
var isBooking4Shop = useIsBooking4Shop(state);
|
|
70
|
-
var shopDiscount =
|
|
71
|
-
var _useActiveExecute = useActiveExecute(),
|
|
72
|
-
executeIfActive = _useActiveExecute.executeIfActive;
|
|
69
|
+
var shopDiscount = pisellos.getModule('shopDiscount');
|
|
73
70
|
services = state.service;
|
|
74
71
|
|
|
75
72
|
// 将选中的客户数据传递给状态管理
|
|
@@ -98,7 +95,7 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
98
95
|
|
|
99
96
|
// 设置productList
|
|
100
97
|
useEffect(function () {
|
|
101
|
-
if (isBooking4Shop
|
|
98
|
+
if (isBooking4Shop) {
|
|
102
99
|
shopDiscount.setProductList([].concat(_toConsumableArray(state.service.value), _toConsumableArray(state.addons.value)));
|
|
103
100
|
}
|
|
104
101
|
}, [state.service.value, state.addons.value, isBooking4Shop]);
|
|
@@ -125,10 +122,9 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
125
122
|
onScanCode(e.detail.code);
|
|
126
123
|
});
|
|
127
124
|
useEffect(function () {
|
|
128
|
-
|
|
129
|
-
window.addEventListener('onScanWallPassCode', wrappedOnScanWallPassCode);
|
|
125
|
+
window.addEventListener('onScanWallPassCode', onScanWallPassCode);
|
|
130
126
|
return function () {
|
|
131
|
-
window.removeEventListener('onScanWallPassCode',
|
|
127
|
+
window.removeEventListener('onScanWallPassCode', onScanWallPassCode);
|
|
132
128
|
};
|
|
133
129
|
}, []);
|
|
134
130
|
var addonsMemo = useMemo(function () {
|
|
@@ -178,11 +174,12 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
178
174
|
run();
|
|
179
175
|
}, [JSON.stringify(serviceMemo), JSON.stringify(addonsMemo), isBooking4Shop]);
|
|
180
176
|
useEffect(function () {
|
|
181
|
-
if (
|
|
182
|
-
var
|
|
183
|
-
|
|
177
|
+
if (pisellos) {
|
|
178
|
+
var _pisellos$effects;
|
|
179
|
+
pisellos === null || pisellos === void 0 || (_pisellos$effects = pisellos.effects) === null || _pisellos$effects === void 0 || _pisellos$effects.on("shopDiscount:onSelectedDiscountListChange", fn);
|
|
184
180
|
return function () {
|
|
185
|
-
|
|
181
|
+
var _pisellos$effects2;
|
|
182
|
+
pisellos === null || pisellos === void 0 || (_pisellos$effects2 = pisellos.effects) === null || _pisellos$effects2 === void 0 || _pisellos$effects2.off("shopDiscount:onSelectedDiscountListChange", fn);
|
|
186
183
|
};
|
|
187
184
|
}
|
|
188
185
|
}, []);
|
|
@@ -198,7 +195,7 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
198
195
|
|
|
199
196
|
// 监听customer变化
|
|
200
197
|
useEffect(function () {
|
|
201
|
-
if (!isBooking4Shop
|
|
198
|
+
if (!isBooking4Shop) return;
|
|
202
199
|
var onScanCustomerChange = function onScanCustomerChange(customer) {
|
|
203
200
|
var clientVariantClose = getClientVariantClose();
|
|
204
201
|
if (clientVariantClose) {
|
|
@@ -209,17 +206,14 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
209
206
|
var onDiscountListChange = function onDiscountListChange(discount) {
|
|
210
207
|
setDisCountList(discount);
|
|
211
208
|
};
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
shopDiscount.effectsOn('onScanCustomerChange', wrappedOnScanCustomerChangeHandler);
|
|
216
|
-
shopDiscount.effectsOn('onLoadPrepareCalcResult', wrappedFn);
|
|
217
|
-
shopDiscount.effectsOn('onDiscountListChange', wrappedOnDiscountListChangeHandler);
|
|
209
|
+
pisellos.effects.on(ShopDiscountHooks.onScanCustomerChange, onScanCustomerChange);
|
|
210
|
+
pisellos.effects.on(ShopDiscountHooks.onLoadPrepareCalcResult, fn);
|
|
211
|
+
pisellos.effects.on(ShopDiscountHooks.onDiscountListChange, onDiscountListChange);
|
|
218
212
|
return function () {
|
|
219
213
|
shopDiscount.clear();
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
214
|
+
pisellos.effects.off(ShopDiscountHooks.onScanCustomerChange, onScanCustomerChange);
|
|
215
|
+
pisellos.effects.off(ShopDiscountHooks.onLoadPrepareCalcResult, fn);
|
|
216
|
+
pisellos.effects.off(ShopDiscountHooks.onDiscountListChange, onDiscountListChange);
|
|
223
217
|
};
|
|
224
218
|
}, [state.bookingId, isBooking4Shop, fn]);
|
|
225
219
|
var productListToValue = useMemoizedFn(function (list, edit) {
|
|
@@ -288,6 +282,7 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
288
282
|
}();
|
|
289
283
|
var availableData = useMemo(function () {
|
|
290
284
|
if (!isBooking4Shop) return [];
|
|
285
|
+
var shopDiscount = pisellos.getModule('shopDiscount');
|
|
291
286
|
return discountList.filter(function (item) {
|
|
292
287
|
return !!item.isAvailable;
|
|
293
288
|
}).map(function (discount) {
|
|
@@ -330,6 +325,7 @@ var VoucherCard = function VoucherCard(props) {
|
|
|
330
325
|
dataSource: (_state$service2 = state.service) !== null && _state$service2 !== void 0 && (_state$service2 = _state$service2.value) !== null && _state$service2 !== void 0 && _state$service2.length ? availableData : [],
|
|
331
326
|
mixedSort: mixedSort,
|
|
332
327
|
onChange: function onChange(val) {
|
|
328
|
+
var shopDiscount = pisellos.getModule('shopDiscount');
|
|
333
329
|
var detail = shopDiscount.setDiscountSelected({
|
|
334
330
|
discountId: val.id,
|
|
335
331
|
isSelected: val.isSelected
|
|
@@ -248,4 +248,4 @@ export declare const updateAppointmentServicePrice: (state: any, { start_date, e
|
|
|
248
248
|
* @Author: WangHan
|
|
249
249
|
* @Date: 2024-12-24 11:32
|
|
250
250
|
*/
|
|
251
|
-
export declare const updateServicePrice: (state: any) => Promise<any
|
|
251
|
+
export declare const updateServicePrice: (state: any) => never[] | Promise<any>;
|
|
@@ -29,7 +29,6 @@ import useTranslationOriginal from "../../../../hooks/useTranslationOriginal";
|
|
|
29
29
|
import useEngineContext from "../../../../hooks/useEngineContext";
|
|
30
30
|
import { Context } from "../../info/model";
|
|
31
31
|
import "./index.less";
|
|
32
|
-
import { useIsActive } from "../../../ticketBooking/context/IsActiveContext";
|
|
33
32
|
|
|
34
33
|
// 导出类型
|
|
35
34
|
|
|
@@ -61,7 +60,6 @@ var CartClientCard = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
61
60
|
keyword = _useState8[0],
|
|
62
61
|
setKeyword = _useState8[1];
|
|
63
62
|
var keywordRef = useRef('');
|
|
64
|
-
var isActive = useIsActive();
|
|
65
63
|
keywordRef.current = keyword;
|
|
66
64
|
var Toast = useToast();
|
|
67
65
|
var _useScanCustomer = useScanCustomer(),
|
|
@@ -317,15 +315,13 @@ var CartClientCard = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
317
315
|
setPendingCustomer(null);
|
|
318
316
|
};
|
|
319
317
|
useMemo(function () {
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
}
|
|
323
|
-
}, [isActive]);
|
|
318
|
+
setHandleSetClient(handleSetClient);
|
|
319
|
+
}, []);
|
|
324
320
|
useEffect(function () {
|
|
325
321
|
return function () {
|
|
326
322
|
setHandleSetClient(null);
|
|
327
323
|
};
|
|
328
|
-
}, [
|
|
324
|
+
}, []);
|
|
329
325
|
var tags = useMemo(function () {
|
|
330
326
|
var _latest_wallet_detail;
|
|
331
327
|
if (!selectedCustomer) return;
|
|
@@ -165,10 +165,10 @@ export declare const getProductTotalPrice: (item: any) => number;
|
|
|
165
165
|
export declare const getDuration: (duration: number | {
|
|
166
166
|
type: string;
|
|
167
167
|
value: number;
|
|
168
|
-
}) => number | {
|
|
168
|
+
}) => number | "flexible" | {
|
|
169
169
|
type: string;
|
|
170
170
|
value: number;
|
|
171
|
-
}
|
|
171
|
+
};
|
|
172
172
|
export declare const isWalkIn: (customer_id?: number | string) => boolean;
|
|
173
173
|
export declare const getIsEdit: (state: any) => boolean;
|
|
174
174
|
export {};
|
|
@@ -47,7 +47,6 @@ import { getShopWalletPassId, reorderPaymentMethodList } from "./utils";
|
|
|
47
47
|
import usePaymentLogger from "./hooks/usePaymentLogger";
|
|
48
48
|
import { Button } from 'antd';
|
|
49
49
|
import { DiscountKeyboard } from "../../pro/priceKeyboard";
|
|
50
|
-
import { useActiveExecute } from "../ticketBooking/hooks/pisellos";
|
|
51
50
|
|
|
52
51
|
// Checkout 模块的事件常量
|
|
53
52
|
var CheckoutHooks = {
|
|
@@ -99,8 +98,6 @@ var PaymentContent = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
99
98
|
pisellosAllModule = utils.pisellosAllModule,
|
|
100
99
|
interaction = utils.interaction;
|
|
101
100
|
var Toast = useToast();
|
|
102
|
-
var _useActiveExecute = useActiveExecute(),
|
|
103
|
-
executeIfActive = _useActiveExecute.executeIfActive;
|
|
104
101
|
// const paymentResultToast = usePaymentResultToast();
|
|
105
102
|
|
|
106
103
|
var checkoutRef = useRef(null);
|
|
@@ -500,7 +497,7 @@ var PaymentContent = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
500
497
|
try {
|
|
501
498
|
var core = checkoutModule.core;
|
|
502
499
|
if (core.effects && typeof core.effects.on === 'function') {
|
|
503
|
-
var unsubscribe = core.effects.on(CheckoutHooks.OnStateAmountChanged,
|
|
500
|
+
var unsubscribe = core.effects.on(CheckoutHooks.OnStateAmountChanged, /*#__PURE__*/function () {
|
|
504
501
|
var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(data) {
|
|
505
502
|
var _Toast$success, _Toast$success2, items;
|
|
506
503
|
return _regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
@@ -530,17 +527,17 @@ var PaymentContent = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
530
527
|
return function (_x4) {
|
|
531
528
|
return _ref7.apply(this, arguments);
|
|
532
529
|
};
|
|
533
|
-
}())
|
|
534
|
-
var amountChangedUnsubscribe = core.effects.on(CheckoutHooks.OnBalanceDueAmountChanged,
|
|
530
|
+
}());
|
|
531
|
+
var amountChangedUnsubscribe = core.effects.on(CheckoutHooks.OnBalanceDueAmountChanged, function (data) {
|
|
535
532
|
setBalanceDueAmount(data.newAmount);
|
|
536
533
|
setBalanceDueTotalAmount(data.totalAmount || '0');
|
|
537
|
-
})
|
|
538
|
-
var orderSubmitStartUnsubscribe = core.effects.on(CheckoutHooks.OnOrderSubmitStart,
|
|
534
|
+
});
|
|
535
|
+
var orderSubmitStartUnsubscribe = core.effects.on(CheckoutHooks.OnOrderSubmitStart, function () {
|
|
539
536
|
var _Toast$loading2;
|
|
540
537
|
setSyncingLock(true);
|
|
541
538
|
Toast === null || Toast === void 0 || (_Toast$loading2 = Toast.loading) === null || _Toast$loading2 === void 0 || _Toast$loading2.call(Toast, '', 0);
|
|
542
|
-
})
|
|
543
|
-
var orderSubmitEndUnsubscribe = core.effects.on(CheckoutHooks.OnOrderSubmitEnd,
|
|
539
|
+
});
|
|
540
|
+
var orderSubmitEndUnsubscribe = core.effects.on(CheckoutHooks.OnOrderSubmitEnd, function (res) {
|
|
544
541
|
setSyncingLock(false);
|
|
545
542
|
if (res.success) {
|
|
546
543
|
var _Toast$hide;
|
|
@@ -556,7 +553,7 @@ var PaymentContent = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
556
553
|
Toast === null || Toast === void 0 || Toast.fail(locales.getText('pisell2.checkout.order-sync-failed') || 'Order sync failed');
|
|
557
554
|
}
|
|
558
555
|
}
|
|
559
|
-
})
|
|
556
|
+
});
|
|
560
557
|
|
|
561
558
|
// const orderSyncFailedUnsubscribe = core.effects.on(
|
|
562
559
|
// CheckoutHooks.OnOrderSyncFailed,
|
|
@@ -565,7 +562,7 @@ var PaymentContent = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
565
562
|
// Toast?.fail(locales.getText('pisell2.checkout.order-sync-failed') || 'Order sync failed');
|
|
566
563
|
// }
|
|
567
564
|
// );
|
|
568
|
-
var orderPaymentAddedUnsubscribe = core.effects.on(CheckoutHooks.OnOrderPaymentAdded,
|
|
565
|
+
var orderPaymentAddedUnsubscribe = core.effects.on(CheckoutHooks.OnOrderPaymentAdded, /*#__PURE__*/function () {
|
|
569
566
|
var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(data) {
|
|
570
567
|
var orderInfo, balanceDueAmount, autoCloseConfig, _paymentItems, _totalAmount, serviceChargeTotal, paymentMethodName, isCashPayment, _interaction$utils3, _interaction$utils3$p;
|
|
571
568
|
return _regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
@@ -655,7 +652,7 @@ var PaymentContent = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
655
652
|
return function (_x5) {
|
|
656
653
|
return _ref8.apply(this, arguments);
|
|
657
654
|
};
|
|
658
|
-
}())
|
|
655
|
+
}());
|
|
659
656
|
return function () {
|
|
660
657
|
if (unsubscribe && typeof unsubscribe === 'function') {
|
|
661
658
|
unsubscribe();
|
|
@@ -1414,8 +1411,6 @@ var PaymentModal = function PaymentModal(_ref18) {
|
|
|
1414
1411
|
_useState36 = _slicedToArray(_useState35, 2),
|
|
1415
1412
|
currentEditOrderId = _useState36[0],
|
|
1416
1413
|
_setCurrentEditOrderId = _useState36[1];
|
|
1417
|
-
var _useActiveExecute2 = useActiveExecute(),
|
|
1418
|
-
executeIfActive = _useActiveExecute2.executeIfActive;
|
|
1419
1414
|
var Toast = useToast();
|
|
1420
1415
|
|
|
1421
1416
|
// 重试处理函数(逻辑由用户自己实现)
|
|
@@ -2090,7 +2085,7 @@ var PaymentModal = function PaymentModal(_ref18) {
|
|
|
2090
2085
|
unsubscribeRef.current = undefined;
|
|
2091
2086
|
}
|
|
2092
2087
|
// 监听订单同步完成,同步完成后显示订单完成 toast,关闭当前弹窗
|
|
2093
|
-
unsubscribeRef.current = checkout.core.effects.on('checkout:onOrderSynced',
|
|
2088
|
+
unsubscribeRef.current = checkout.core.effects.on('checkout:onOrderSynced', /*#__PURE__*/function () {
|
|
2094
2089
|
var _ref29 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee22(data) {
|
|
2095
2090
|
var _data$response, _responseData$payment2;
|
|
2096
2091
|
var currentOrderId, responseData, paymentStatus, orderTotalAmount, gapAmount, currentChangeGivenAmount, failureReason, _responseData$payment3, params, statusClassName, autoCloseConfig, enabledAutoPrint, _interaction$utils6, _interaction$utils6$a, _orderInfo3, paymentResult;
|
|
@@ -2235,7 +2230,7 @@ var PaymentModal = function PaymentModal(_ref18) {
|
|
|
2235
2230
|
return function (_x17) {
|
|
2236
2231
|
return _ref29.apply(this, arguments);
|
|
2237
2232
|
};
|
|
2238
|
-
}())
|
|
2233
|
+
}());
|
|
2239
2234
|
_context23.next = 42;
|
|
2240
2235
|
break;
|
|
2241
2236
|
case 25:
|
|
@@ -27,8 +27,6 @@ import { usePisellOS } from "../../../hooks/useEngineContext";
|
|
|
27
27
|
import { formatDiscountWalletData, formatMachineCodeServer2CardList, isSameContent } from "../components/WalletPassModule/utils";
|
|
28
28
|
import usePaymentLogger from "./usePaymentLogger";
|
|
29
29
|
import { isWalkIn } from "../../booking/utils";
|
|
30
|
-
import { useActiveExecute } from "../../ticketBooking/hooks/pisellos";
|
|
31
|
-
import { useShopDiscountModule } from "../../ticketBooking/hooks/pisellos/useShopDiscountModule";
|
|
32
30
|
|
|
33
31
|
/**
|
|
34
32
|
* 自定义Hook:使用WalletPass功能
|
|
@@ -38,8 +36,6 @@ export var useWalletPass = function useWalletPass(props) {
|
|
|
38
36
|
customAmount = props.customAmount,
|
|
39
37
|
clientId = props.clientId;
|
|
40
38
|
var logger = usePaymentLogger();
|
|
41
|
-
var _useActiveExecute = useActiveExecute(),
|
|
42
|
-
executeIfActive = _useActiveExecute.executeIfActive;
|
|
43
39
|
|
|
44
40
|
// 钱包推荐列表
|
|
45
41
|
var _useState = useState([]),
|
|
@@ -118,7 +114,7 @@ export var useWalletPass = function useWalletPass(props) {
|
|
|
118
114
|
|
|
119
115
|
// 获取checkout模块
|
|
120
116
|
var checkoutModule = pisellos.getModule('checkout');
|
|
121
|
-
var shopDiscount =
|
|
117
|
+
var shopDiscount = pisellos.getModule('shopDiscount');
|
|
122
118
|
var paymentModule = checkoutModule === null || checkoutModule === void 0 ? void 0 : checkoutModule.payment;
|
|
123
119
|
var setWalletSelect = useMemoizedFn(function (data) {
|
|
124
120
|
setSelectedWallet(data);
|
|
@@ -519,41 +515,30 @@ export var useWalletPass = function useWalletPass(props) {
|
|
|
519
515
|
if (!paymentModule) return;
|
|
520
516
|
var core = pisellos; // 获取core实例
|
|
521
517
|
|
|
522
|
-
// checkout 单实例,执行时判断是否active
|
|
523
|
-
var wrappedHandlePaymentStarted = executeIfActive(handlePaymentStarted);
|
|
524
|
-
var wrappedOnOrderCreated = executeIfActive(onOrderCreated);
|
|
525
|
-
var wrappedHandleWalletRecommendListUpdated = executeIfActive(handleWalletRecommendListUpdated);
|
|
526
|
-
var wrappedHandleUserIdentificationCodesUpdated = executeIfActive(handleUserIdentificationCodesUpdated);
|
|
527
|
-
var wrappedHandleWalletCacheCleared = executeIfActive(handleWalletCacheCleared);
|
|
528
|
-
var wrappedHandleSearchIdentificationCodeCompleted = executeIfActive(handleSearchIdentificationCodeCompleted);
|
|
529
|
-
var wrappedHandleWalletInitializationStarted = executeIfActive(handleWalletInitializationStarted);
|
|
530
|
-
var wrappedHandleWalletInitializationCompleted = executeIfActive(handleWalletInitializationCompleted);
|
|
531
|
-
var wrappedHandleWalletInitializationFailed = executeIfActive(handleWalletInitializationFailed);
|
|
532
518
|
// 注册事件监听器
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
paymentModule.effectsOn('onWalletInitializationFailed', wrappedHandleWalletInitializationFailed);
|
|
519
|
+
core.effects.on('wallet:onWalletRecommendListUpdated', handleWalletRecommendListUpdated);
|
|
520
|
+
core.effects.on('checkout:onPaymentStarted', handlePaymentStarted);
|
|
521
|
+
core.effects.on('checkout:onPaymentItemAdded', handlePaymentStarted);
|
|
522
|
+
core.effects.on('wallet:onUserIdentificationCodesUpdated', handleUserIdentificationCodesUpdated);
|
|
523
|
+
core.effects.on('wallet:onWalletCacheCleared', handleWalletCacheCleared);
|
|
524
|
+
core.effects.on('wallet:onSearchIdentificationCodeCompleted', handleSearchIdentificationCodeCompleted);
|
|
525
|
+
core.effects.on('checkout:onWalletDataInitialized', onOrderCreated);
|
|
526
|
+
core.effects.on('wallet:onWalletInitializationStarted', handleWalletInitializationStarted);
|
|
527
|
+
core.effects.on('wallet:onWalletInitializationCompleted', handleWalletInitializationCompleted);
|
|
528
|
+
core.effects.on('wallet:onWalletInitializationFailed', handleWalletInitializationFailed);
|
|
544
529
|
|
|
545
530
|
// 清理事件监听器
|
|
546
531
|
return function () {
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
532
|
+
core.effects.off('wallet:onWalletRecommendListUpdated', handleWalletRecommendListUpdated);
|
|
533
|
+
core.effects.off('checkout:onPaymentStarted', handlePaymentStarted);
|
|
534
|
+
core.effects.off('checkout:onPaymentItemAdded', handlePaymentStarted);
|
|
535
|
+
core.effects.off('wallet:onUserIdentificationCodesUpdated', handleUserIdentificationCodesUpdated);
|
|
536
|
+
core.effects.off('wallet:onWalletCacheCleared', handleWalletCacheCleared);
|
|
537
|
+
core.effects.off('wallet:onSearchIdentificationCodeCompleted', handleSearchIdentificationCodeCompleted);
|
|
538
|
+
core.effects.off('checkout:onWalletDataInitialized', onOrderCreated);
|
|
539
|
+
core.effects.off('wallet:onWalletInitializationStarted', handleWalletInitializationStarted);
|
|
540
|
+
core.effects.off('wallet:onWalletInitializationCompleted', handleWalletInitializationCompleted);
|
|
541
|
+
core.effects.off('wallet:onWalletInitializationFailed', handleWalletInitializationFailed);
|
|
557
542
|
};
|
|
558
543
|
}, [paymentModule]);
|
|
559
544
|
|
|
@@ -9,7 +9,7 @@ import { PosProps } from './const';
|
|
|
9
9
|
*/
|
|
10
10
|
declare const _default: ({ className, onChange, onClose, formatAmount, isMobile, net, client }: {
|
|
11
11
|
className?: string | undefined;
|
|
12
|
-
onChange?: ((status: "
|
|
12
|
+
onChange?: ((status: "page" | "success" | "print" | "fail" | "mark_tx_processed", params?: string | {
|
|
13
13
|
[keys: string]: unknown;
|
|
14
14
|
} | undefined, other?: any) => void) | undefined;
|
|
15
15
|
onClose: () => void;
|
|
@@ -11,7 +11,7 @@ import './device.less';
|
|
|
11
11
|
declare const _default: ({ api, onChange, onClose, className, device_number, isMobile, net, client, formatAmount, containerStyle, }: {
|
|
12
12
|
api: PayProps['api'];
|
|
13
13
|
className?: string | undefined;
|
|
14
|
-
onChange?: ((status: "
|
|
14
|
+
onChange?: ((status: "page" | "success" | "print" | "fail" | "mark_tx_processed", params?: string | {
|
|
15
15
|
[keys: string]: unknown;
|
|
16
16
|
} | undefined, other?: any) => void) | undefined;
|
|
17
17
|
onClose: () => void;
|
|
@@ -15,7 +15,7 @@ export declare const useStoreRef: <T extends {
|
|
|
15
15
|
readonly numRef: React.MutableRefObject<string | number | undefined>;
|
|
16
16
|
readonly orderIdRef: React.MutableRefObject<string | number>;
|
|
17
17
|
readonly modeRef: React.MutableRefObject<ModeEnum>;
|
|
18
|
-
readonly statusRef: React.MutableRefObject<"
|
|
18
|
+
readonly statusRef: React.MutableRefObject<"loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question">;
|
|
19
19
|
readonly netRef: React.MutableRefObject<boolean | undefined>;
|
|
20
20
|
readonly symbolRef: React.MutableRefObject<string>;
|
|
21
21
|
readonly amountRef: React.MutableRefObject<string | number>;
|
|
@@ -174,7 +174,7 @@ export declare const updateCustom: (payload: {
|
|
|
174
174
|
export declare const updateStatus: (status: 'loading' | 'warn' | 'fail' | 'success' | 'question') => {
|
|
175
175
|
type: EActionTypes;
|
|
176
176
|
payload: {
|
|
177
|
-
status: "
|
|
177
|
+
status: "loading" | "success" | "warn" | "fail" | "question";
|
|
178
178
|
};
|
|
179
179
|
};
|
|
180
180
|
/**
|
|
@@ -295,10 +295,10 @@ export declare const backUpFree: (payload: Partial<State>) => {
|
|
|
295
295
|
name?: string | undefined;
|
|
296
296
|
symbol?: string | undefined;
|
|
297
297
|
amount?: string | number | undefined;
|
|
298
|
-
mode?: "
|
|
298
|
+
mode?: "refund" | "pay" | "fullPay" | "query" | undefined;
|
|
299
299
|
order_id?: string | number | undefined;
|
|
300
300
|
eftpos?: "payo" | "tyro" | "windcave" | "stripe" | "linkly" | undefined;
|
|
301
|
-
action?: "
|
|
301
|
+
action?: "pay" | "amount" | "deviceList" | undefined;
|
|
302
302
|
key?: number | undefined;
|
|
303
303
|
step?: number | undefined;
|
|
304
304
|
title?: string | undefined;
|
|
@@ -308,7 +308,7 @@ export declare const backUpFree: (payload: Partial<State>) => {
|
|
|
308
308
|
net?: boolean | undefined;
|
|
309
309
|
component?: string | undefined;
|
|
310
310
|
form?: string | undefined;
|
|
311
|
-
status?: "
|
|
311
|
+
status?: "loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
|
|
312
312
|
warn?: string | undefined;
|
|
313
313
|
steps?: {
|
|
314
314
|
/** 用于重置当前步骤 */
|
|
@@ -2,11 +2,10 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
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
3
|
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
4
|
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); }); }; }
|
|
5
|
-
import React
|
|
5
|
+
import React from 'react';
|
|
6
6
|
import { ToBPayContext } from "./index";
|
|
7
7
|
import { usePisellOS } from "../../../../hooks/useEngineContext";
|
|
8
8
|
import { handlePayMethodList } from "./utils";
|
|
9
|
-
import { useActiveExecute } from "../../../ticketBooking/hooks/pisellos";
|
|
10
9
|
|
|
11
10
|
/**
|
|
12
11
|
* 使用商家端支付的Hook
|
|
@@ -33,28 +32,15 @@ export var useOSPaymentEffect = function useOSPaymentEffect() {
|
|
|
33
32
|
var _useToBPay = useToBPay(),
|
|
34
33
|
setOrder = _useToBPay.setOrder,
|
|
35
34
|
setPayMethodGroupList = _useToBPay.setPayMethodGroupList;
|
|
36
|
-
var _useActiveExecute = useActiveExecute(),
|
|
37
|
-
executeIfActive = _useActiveExecute.executeIfActive;
|
|
38
|
-
var unlisten1 = useRef(null);
|
|
39
|
-
var unlisten2 = useRef(null);
|
|
40
35
|
var osPaymentEffectOn = function osPaymentEffectOn() {
|
|
41
|
-
var wrappedOnPaymentMethodsChanged = executeIfActive(onPaymentMethodsChanged);
|
|
42
|
-
var wrappedOnOrderChanged = executeIfActive(onOrderChanged);
|
|
43
|
-
|
|
44
36
|
// 监听OS的支付方式列表变化
|
|
45
|
-
|
|
37
|
+
pisellOS.effects.on('payment:onPaymentMethodsChanged', onPaymentMethodsChanged);
|
|
46
38
|
// 监听OS的订单信息变化,包括订单、支付项发生改变、删除、修改信息等操作
|
|
47
|
-
|
|
39
|
+
pisellOS.effects.on('payment:onOrderChanged', onOrderChanged);
|
|
48
40
|
};
|
|
49
41
|
var osPaymentEffectOff = function osPaymentEffectOff() {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
(_unlisten1$current = unlisten1.current) === null || _unlisten1$current === void 0 || _unlisten1$current.call(unlisten1);
|
|
53
|
-
}
|
|
54
|
-
if (unlisten2.current) {
|
|
55
|
-
var _unlisten2$current;
|
|
56
|
-
(_unlisten2$current = unlisten2.current) === null || _unlisten2$current === void 0 || _unlisten2$current.call(unlisten2);
|
|
57
|
-
}
|
|
42
|
+
pisellOS.effects.off('payment:onPaymentMethodsChanged', onPaymentMethodsChanged);
|
|
43
|
+
pisellOS.effects.off('payment:onOrderChanged', onOrderChanged);
|
|
58
44
|
};
|
|
59
45
|
var onPaymentMethodsChanged = /*#__PURE__*/function () {
|
|
60
46
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(res) {
|
|
@@ -1,29 +1,9 @@
|
|
|
1
|
-
import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter';
|
|
2
1
|
import './index.less';
|
|
3
2
|
interface AddServiceProps {
|
|
4
3
|
onEdit?: any;
|
|
5
4
|
dispatch?: any;
|
|
6
5
|
state?: any;
|
|
7
6
|
renderMode?: 'current' | 'drawer';
|
|
8
|
-
/**
|
|
9
|
-
* 产品展示配置
|
|
10
|
-
*
|
|
11
|
-
* 支持两种方式:
|
|
12
|
-
* 1. 简易模式:传入预设字符串,如 'product-select', 'sku-list-a1', 'sku-list-a2', 'sku-list-a5'
|
|
13
|
-
* 2. 完整配置模式:传入完整的配置对象
|
|
14
|
-
*
|
|
15
|
-
* @example
|
|
16
|
-
* // 简易模式
|
|
17
|
-
* <AddService productDisplayConfig="sku-list-a1" />
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* // 完整配置模式
|
|
21
|
-
* <AddService productDisplayConfig={{
|
|
22
|
-
* displayMode: 'sku-list',
|
|
23
|
-
* skuListConfig: { ... }
|
|
24
|
-
* }} />
|
|
25
|
-
*/
|
|
26
|
-
productDisplayConfig?: ProductDisplayPresetKey | ProductDisplayConfig;
|
|
27
7
|
}
|
|
28
8
|
declare const AddSerivce: (props: AddServiceProps) => JSX.Element | null;
|
|
29
9
|
export default AddSerivce;
|