@pisell/private-materials 6.3.87 → 6.3.89
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 +8 -8
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +10 -10
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +9 -9
- package/es/components/appointmentBooking/components/Cart/Item/Total.d.ts +0 -1
- package/es/components/appointmentBooking/components/Cart/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Footer/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/TimeSlicing/components/SelectDateOS.d.ts +0 -1
- package/es/components/appointmentBooking/deposit/components/PolicyModal/index.d.ts +0 -1
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/es/components/booking/forms/footer.d.ts +0 -1
- package/es/components/booking/forms/sendModal/useSendModal.d.ts +0 -1
- package/es/components/booking/hooks/useClearCart.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/es/components/booking/info/date/index.d.ts +1 -0
- package/es/components/booking/info/dateRange/index.d.ts +0 -1
- package/es/components/booking/info/service/like/index.d.ts +1 -0
- package/es/components/ecocup/components/AddCustomerModal/index.d.ts +9 -0
- package/es/components/ecocup/components/AddCustomerModal/index.js +216 -0
- package/es/components/ecocup/components/AddCustomerModal/index.less +9 -0
- package/es/components/ecocup/components/CupActionList/index.d.ts +13 -0
- package/es/components/ecocup/components/CupActionList/index.js +91 -0
- package/es/components/ecocup/components/CupActionList/index.less +102 -0
- package/es/components/ecocup/components/CupActionModal/hooks.d.ts +5 -0
- package/es/components/ecocup/components/CupActionModal/hooks.js +68 -0
- package/es/components/ecocup/components/CupActionModal/index.d.ts +14 -0
- package/es/components/ecocup/components/CupActionModal/index.js +92 -0
- package/es/components/ecocup/components/CupActionModal/index.less +38 -0
- package/es/components/ecocup/components/CupInfoCard/index.d.ts +7 -0
- package/es/components/ecocup/components/CupInfoCard/index.js +12 -0
- package/es/components/ecocup/components/CupInfoCard/index.less +11 -0
- package/es/components/ecocup/components/CupStatusModal/hooks.d.ts +5 -0
- package/es/components/ecocup/components/CupStatusModal/hooks.js +68 -0
- package/es/components/ecocup/components/CupStatusModal/index.d.ts +13 -0
- package/es/components/ecocup/components/CupStatusModal/index.js +147 -0
- package/es/components/ecocup/components/CupStatusModal/index.less +35 -0
- package/es/components/ecocup/components/CustomerAndCupModal/hooks.d.ts +14 -0
- package/es/components/ecocup/components/CustomerAndCupModal/hooks.js +133 -0
- package/es/components/ecocup/components/CustomerAndCupModal/index.d.ts +16 -0
- package/es/components/ecocup/components/CustomerAndCupModal/index.js +227 -0
- package/es/components/ecocup/components/CustomerAndCupModal/index.less +68 -0
- package/es/components/ecocup/components/CustomerCard/index.d.ts +6 -0
- package/es/components/ecocup/components/CustomerCard/index.js +34 -0
- package/es/components/ecocup/components/CustomerCard/index.less +50 -0
- package/es/components/ecocup/components/MoreDropdown/index.d.ts +8 -0
- package/es/components/ecocup/components/MoreDropdown/index.js +33 -0
- package/es/components/ecocup/components/PageHeader/index.d.ts +6 -0
- package/es/components/ecocup/components/PageHeader/index.js +37 -0
- package/es/components/ecocup/components/PageHeader/index.less +19 -0
- package/es/components/ecocup/components/SearchBar/const.d.ts +4 -0
- package/es/components/ecocup/components/SearchBar/const.js +16 -0
- package/es/components/ecocup/components/SearchBar/hooks.d.ts +44 -0
- package/es/components/ecocup/components/SearchBar/hooks.js +184 -0
- package/es/components/ecocup/components/SearchBar/index.d.ts +12 -0
- package/es/components/ecocup/components/SearchBar/index.js +218 -0
- package/es/components/ecocup/components/SearchBar/index.less +88 -0
- package/es/components/ecocup/cupList/const.d.ts +133 -0
- package/es/components/ecocup/cupList/const.js +306 -0
- package/es/components/ecocup/cupList/hooks/index.d.ts +4 -0
- package/es/components/ecocup/cupList/hooks/index.js +4 -0
- package/es/components/ecocup/cupList/hooks/useColumns.d.ts +43 -0
- package/es/components/ecocup/cupList/hooks/useColumns.js +168 -0
- package/es/components/ecocup/cupList/hooks/useCupApi.d.ts +32 -0
- package/es/components/ecocup/cupList/hooks/useCupApi.js +172 -0
- package/es/components/ecocup/cupList/hooks/useSummary.d.ts +2 -0
- package/es/components/ecocup/cupList/hooks/useSummary.js +40 -0
- package/es/components/ecocup/cupList/index.d.ts +6 -0
- package/es/components/ecocup/cupList/index.js +220 -0
- package/es/components/ecocup/cupList/index.less +113 -0
- package/es/components/ecocup/cupProject/const.d.ts +7 -0
- package/es/components/ecocup/cupProject/const.js +27 -0
- package/es/components/ecocup/cupProject/index.d.ts +3 -0
- package/es/components/ecocup/cupProject/index.js +103 -0
- package/es/components/ecocup/cupProject/index.less +41 -0
- package/es/components/ecocup/customerList/const.d.ts +44 -0
- package/es/components/ecocup/customerList/const.js +67 -0
- package/es/components/ecocup/customerList/hooks/index.d.ts +3 -0
- package/es/components/ecocup/customerList/hooks/index.js +3 -0
- package/es/components/ecocup/customerList/hooks/useColumns.d.ts +15 -0
- package/es/components/ecocup/customerList/hooks/useColumns.js +44 -0
- package/es/components/ecocup/customerList/hooks/useCustomerApi.d.ts +15 -0
- package/es/components/ecocup/customerList/hooks/useCustomerApi.js +70 -0
- package/es/components/ecocup/customerList/index.d.ts +7 -0
- package/es/components/ecocup/customerList/index.js +127 -0
- package/es/components/ecocup/customerList/index.less +15 -0
- package/es/components/ecocup/hooks.d.ts +49 -0
- package/es/components/ecocup/hooks.js +151 -0
- package/es/components/ecocup/locales.d.ts +339 -0
- package/es/components/ecocup/locales.js +372 -0
- package/es/components/ecocup/types.d.ts +103 -0
- package/es/components/ecocup/types.js +36 -0
- package/es/components/ecocup/utils/scanListener.d.ts +20 -0
- package/es/components/ecocup/utils/scanListener.js +107 -0
- package/es/components/eftpos/const.d.ts +1 -3
- package/es/components/eftpos/const.js +0 -2
- package/es/components/eftpos/device.d.ts +1 -3
- package/es/components/eftpos/device.js +3 -5
- 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/hooks.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/index.d.ts +1 -0
- package/es/components/eftpos/index.js +11 -34
- package/es/components/eftpos/index.less +1 -26
- package/es/components/eftpos/locales.d.ts +0 -3
- package/es/components/eftpos/locales.js +0 -3
- package/es/components/eftpos/receipt/index.d.ts +1 -0
- package/es/components/eftposPay/amount.d.ts +1 -0
- package/es/components/eftposPay/app.d.ts +1 -1
- package/es/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/es/components/eftposPay/component/header/titlebar.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/const.d.ts +1 -6
- package/es/components/eftposPay/const.js +0 -2
- package/es/components/eftposPay/device.js +208 -36
- package/es/components/eftposPay/hooks.d.ts +1 -2
- package/es/components/eftposPay/hooks.js +0 -12
- package/es/components/eftposPay/linkly/index.js +0 -1
- package/es/components/eftposPay/manufacturer.d.ts +0 -1
- package/es/components/eftposPay/manufacturer.js +0 -4
- package/es/components/eftposPay/pay.js +2 -7
- package/es/components/eftposPay/store/index.d.ts +1 -1
- package/es/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/es/components/eftposPay/windcave/windcave.js +9 -9
- package/es/components/eventBooking/components/Provider/Content/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/EmptyHolderModal/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Header/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/OrderProductModal/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/RemoveOptionConfirmModal.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/SelectHolderModal.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/bookingDetailModal/components/Resource.d.ts +1 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +1 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/List/index.d.ts +0 -1
- package/es/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/es/components/shoppingCart/hooks/useAddService.d.ts +0 -1
- package/es/components/shoppingCart/hooks/useClearCart.d.ts +0 -1
- package/es/hooks/useEngineContext.d.ts +1 -0
- package/es/hooks/useEngineContext.js +7 -0
- package/es/index.d.ts +5 -1
- package/es/index.js +5 -1
- package/es/plus/clientName/index.d.ts +1 -0
- package/es/plus/orderList/components/BatchActionBar.d.ts +9 -0
- package/es/plus/orderList/components/BatchActionBar.js +835 -0
- package/es/plus/orderList/components/FilterList.d.ts +8 -0
- package/es/plus/orderList/components/FilterList.js +78 -0
- package/es/plus/orderList/components/HandleActions.d.ts +4 -0
- package/es/plus/orderList/components/HandleActions.js +24 -0
- package/es/plus/orderList/components/QuickFilter.d.ts +4 -0
- package/es/plus/orderList/components/QuickFilter.js +14 -0
- package/es/plus/orderList/components/Reset.d.ts +6 -0
- package/es/plus/orderList/components/Reset.js +23 -0
- package/es/plus/orderList/components/Toolbar.d.ts +5 -0
- package/es/plus/orderList/components/Toolbar.js +57 -0
- package/es/plus/orderList/config.d.ts +154 -0
- package/es/plus/orderList/config.js +786 -0
- package/es/plus/orderList/index.d.ts +9 -0
- package/es/plus/orderList/index.js +128 -0
- package/es/plus/orderList/index.less +125 -0
- package/es/plus/orderList/locales.d.ts +372 -0
- package/es/plus/orderList/locales.js +459 -0
- package/es/plus/orderList/serve.d.ts +42 -0
- package/es/plus/orderList/serve.js +351 -0
- package/es/plus/saasRegister/components/VertifyEmail.d.ts +0 -1
- package/es/plus/skuOptionsSelection/components/OptionsCard/index.d.ts +0 -1
- package/es/plus/skuOptionsSelection/components/OptionsCard/index.less +2 -0
- package/es/plus/skuOptionsSelection/components/TitleExtra/index.d.ts +0 -1
- package/es/plus/skuOptionsSelection/components/VariantCard/index.d.ts +0 -1
- package/es/plus/skuOptionsSelection/index.js +2 -2
- package/es/plus/skuOptionsSelection/utils/transformSelectorValueToValue.js +9 -2
- package/es/plus/skuOptionsSelection/utils/transformValueToSelectorValue.js +8 -4
- package/es/plus/walletPassGallery/components/passList/index.d.ts +0 -1
- package/es/plus/walletPassGallery/components/timelineSection/index.d.ts +0 -1
- package/es/pro/NumericStepper/index.d.ts +28 -3
- package/es/pro/NumericStepper/index.js +175 -107
- package/es/pro/NumericStepper/index.less +295 -143
- package/es/pro/Selector/Selector.js +33 -26
- package/es/pro/Selector/components/Card/index.js +2 -3
- package/es/pro/Selector/components/Card/index.less +11 -4
- package/es/pro/Selector/components/Indicator/index.d.ts +1 -0
- package/es/pro/Selector/components/Indicator/index.js +2 -1
- package/es/pro/Selector/components/Indicator/index.less +4 -1
- package/es/pro/Selector/components/LayoutContainer/index.d.ts +5 -3
- package/es/pro/Selector/components/LayoutContainer/index.js +226 -9
- package/es/pro/Selector/components/LayoutContainer/index.less +19 -0
- package/es/pro/Selector/demo.js +1 -1
- package/es/pro/Selector/hooks/usePresetItemProps.js +2 -0
- package/es/pro/Selector/hooks/usePresetProps.js +60 -6
- package/es/pro/Selector/selector.less +0 -64
- package/es/pro/Selector/types.d.ts +40 -0
- package/es/pro/comprehensiveSearch/components/deviceIconGroup/index.d.ts +11 -0
- package/es/pro/comprehensiveSearch/components/deviceIconGroup/index.js +54 -0
- package/es/pro/comprehensiveSearch/components/deviceIconGroup/index.less +28 -0
- package/es/pro/comprehensiveSearch/components/index.d.ts +2 -0
- package/es/pro/comprehensiveSearch/components/index.js +2 -0
- package/es/pro/comprehensiveSearch/components/searchSection/index.d.ts +24 -0
- package/es/pro/comprehensiveSearch/components/searchSection/index.js +140 -0
- package/es/pro/comprehensiveSearch/components/searchSection/index.less +100 -0
- package/es/pro/comprehensiveSearch/components/searchSection/locales.d.ts +15 -0
- package/es/pro/comprehensiveSearch/components/searchSection/locales.js +14 -0
- package/es/pro/comprehensiveSearch/hooks/useNativeScanner.d.ts +5 -0
- package/es/pro/comprehensiveSearch/hooks/useNativeScanner.js +24 -0
- package/es/pro/comprehensiveSearch/hooks/useTerminalPeripherals.d.ts +9 -0
- package/es/pro/comprehensiveSearch/hooks/useTerminalPeripherals.js +44 -0
- package/es/pro/comprehensiveSearch/index.d.ts +7 -0
- package/es/pro/comprehensiveSearch/index.js +207 -0
- package/es/pro/comprehensiveSearch/index.less +196 -0
- package/es/pro/comprehensiveSearch/locales.d.ts +15 -0
- package/es/pro/comprehensiveSearch/locales.js +14 -0
- package/es/pro/comprehensiveSearch/types.d.ts +32 -0
- package/es/pro/comprehensiveSearch/types.js +1 -0
- package/es/pro/keyboards/index.d.ts +2 -0
- package/es/pro/keyboards/index.js +1 -0
- package/es/pro/keyboards/locales.d.ts +24 -0
- package/es/pro/keyboards/locales.js +35 -0
- package/es/pro/keyboards/numberKeyboard/index.d.ts +16 -0
- package/es/pro/keyboards/numberKeyboard/index.js +523 -0
- package/es/pro/keyboards/numberKeyboard/index.less +59 -0
- package/es/pro/keyboards/numberKeyboard/types.d.ts +63 -0
- package/es/pro/keyboards/numberKeyboard/types.js +1 -0
- package/es/pro/pisellPaymentList/example.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Cart/Item/Total.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Cart/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Footer/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/TimeSlicing/components/SelectDateOS.d.ts +0 -1
- package/lib/components/appointmentBooking/deposit/components/PolicyModal/index.d.ts +0 -1
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/lib/components/booking/forms/footer.d.ts +0 -1
- package/lib/components/booking/forms/sendModal/useSendModal.d.ts +0 -1
- package/lib/components/booking/hooks/useClearCart.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/lib/components/booking/info/date/index.d.ts +1 -0
- package/lib/components/booking/info/dateRange/index.d.ts +0 -1
- package/lib/components/booking/info/service/like/index.d.ts +1 -0
- package/lib/components/ecocup/components/AddCustomerModal/index.d.ts +9 -0
- package/lib/components/ecocup/components/AddCustomerModal/index.js +212 -0
- package/lib/components/ecocup/components/AddCustomerModal/index.less +9 -0
- package/lib/components/ecocup/components/CupActionList/index.d.ts +13 -0
- package/lib/components/ecocup/components/CupActionList/index.js +116 -0
- package/lib/components/ecocup/components/CupActionList/index.less +102 -0
- package/lib/components/ecocup/components/CupActionModal/hooks.d.ts +5 -0
- package/lib/components/ecocup/components/CupActionModal/hooks.js +55 -0
- package/lib/components/ecocup/components/CupActionModal/index.d.ts +14 -0
- package/lib/components/ecocup/components/CupActionModal/index.js +125 -0
- package/lib/components/ecocup/components/CupActionModal/index.less +38 -0
- package/lib/components/ecocup/components/CupInfoCard/index.d.ts +7 -0
- package/lib/components/ecocup/components/CupInfoCard/index.js +43 -0
- package/lib/components/ecocup/components/CupInfoCard/index.less +11 -0
- package/lib/components/ecocup/components/CupStatusModal/hooks.d.ts +5 -0
- package/lib/components/ecocup/components/CupStatusModal/hooks.js +55 -0
- package/lib/components/ecocup/components/CupStatusModal/index.d.ts +13 -0
- package/lib/components/ecocup/components/CupStatusModal/index.js +140 -0
- package/lib/components/ecocup/components/CupStatusModal/index.less +35 -0
- package/lib/components/ecocup/components/CustomerAndCupModal/hooks.d.ts +14 -0
- package/lib/components/ecocup/components/CustomerAndCupModal/hooks.js +89 -0
- package/lib/components/ecocup/components/CustomerAndCupModal/index.d.ts +16 -0
- package/lib/components/ecocup/components/CustomerAndCupModal/index.js +178 -0
- package/lib/components/ecocup/components/CustomerAndCupModal/index.less +68 -0
- package/lib/components/ecocup/components/CustomerCard/index.d.ts +6 -0
- package/lib/components/ecocup/components/CustomerCard/index.js +48 -0
- package/lib/components/ecocup/components/CustomerCard/index.less +50 -0
- package/lib/components/ecocup/components/MoreDropdown/index.d.ts +8 -0
- package/lib/components/ecocup/components/MoreDropdown/index.js +68 -0
- package/lib/components/ecocup/components/PageHeader/index.d.ts +6 -0
- package/lib/components/ecocup/components/PageHeader/index.js +59 -0
- package/lib/components/ecocup/components/PageHeader/index.less +19 -0
- package/lib/components/ecocup/components/SearchBar/const.d.ts +4 -0
- package/lib/components/{eftposPay/mx51/types.js → ecocup/components/SearchBar/const.js} +28 -17
- package/lib/components/ecocup/components/SearchBar/hooks.d.ts +44 -0
- package/lib/components/ecocup/components/SearchBar/hooks.js +135 -0
- package/lib/components/ecocup/components/SearchBar/index.d.ts +12 -0
- package/lib/components/ecocup/components/SearchBar/index.js +213 -0
- package/lib/components/ecocup/components/SearchBar/index.less +88 -0
- package/lib/components/ecocup/cupList/const.d.ts +133 -0
- package/lib/components/ecocup/cupList/const.js +326 -0
- package/lib/components/ecocup/cupList/hooks/index.d.ts +4 -0
- package/lib/components/ecocup/cupList/hooks/index.js +39 -0
- package/lib/components/ecocup/cupList/hooks/useColumns.d.ts +43 -0
- package/lib/components/ecocup/cupList/hooks/useColumns.js +202 -0
- package/lib/components/ecocup/cupList/hooks/useCupApi.d.ts +32 -0
- package/lib/components/ecocup/cupList/hooks/useCupApi.js +112 -0
- package/lib/components/ecocup/cupList/hooks/useSummary.d.ts +2 -0
- package/lib/components/ecocup/cupList/hooks/useSummary.js +75 -0
- package/lib/components/ecocup/cupList/index.d.ts +6 -0
- package/lib/components/ecocup/cupList/index.js +208 -0
- package/lib/components/ecocup/cupList/index.less +113 -0
- package/lib/components/ecocup/cupProject/const.d.ts +7 -0
- package/lib/components/ecocup/cupProject/const.js +58 -0
- package/lib/components/ecocup/cupProject/index.d.ts +3 -0
- package/lib/components/ecocup/cupProject/index.js +126 -0
- package/lib/components/ecocup/cupProject/index.less +41 -0
- package/lib/components/ecocup/customerList/const.d.ts +44 -0
- package/lib/components/ecocup/customerList/const.js +93 -0
- package/lib/components/ecocup/customerList/hooks/index.d.ts +3 -0
- package/lib/components/{eftposPay/aggregatePayment → ecocup/customerList/hooks}/index.js +10 -10
- package/lib/components/ecocup/customerList/hooks/useColumns.d.ts +15 -0
- package/lib/components/ecocup/customerList/hooks/useColumns.js +89 -0
- package/lib/components/ecocup/customerList/hooks/useCustomerApi.d.ts +15 -0
- package/lib/components/ecocup/customerList/hooks/useCustomerApi.js +56 -0
- package/lib/components/ecocup/customerList/index.d.ts +7 -0
- package/lib/components/ecocup/customerList/index.js +138 -0
- package/lib/components/ecocup/customerList/index.less +15 -0
- package/lib/components/ecocup/hooks.d.ts +49 -0
- package/lib/components/ecocup/hooks.js +155 -0
- package/lib/components/ecocup/locales.d.ts +339 -0
- package/lib/components/ecocup/locales.js +389 -0
- package/lib/components/ecocup/types.d.ts +103 -0
- package/lib/components/ecocup/types.js +57 -0
- package/lib/components/ecocup/utils/scanListener.d.ts +20 -0
- package/lib/components/ecocup/utils/scanListener.js +90 -0
- package/lib/components/eftpos/const.d.ts +1 -3
- package/lib/components/eftpos/const.js +0 -2
- package/lib/components/eftpos/device.d.ts +1 -3
- package/lib/components/eftpos/device.js +3 -3
- 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/hooks.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/index.d.ts +1 -0
- package/lib/components/eftpos/index.js +5 -20
- package/lib/components/eftpos/index.less +1 -26
- package/lib/components/eftpos/locales.d.ts +0 -3
- package/lib/components/eftpos/locales.js +0 -3
- package/lib/components/eftpos/receipt/index.d.ts +1 -0
- package/lib/components/eftposPay/amount.d.ts +1 -0
- package/lib/components/eftposPay/app.d.ts +1 -1
- package/lib/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/lib/components/eftposPay/component/header/titlebar.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/const.d.ts +1 -6
- package/lib/components/eftposPay/const.js +0 -2
- package/lib/components/eftposPay/device.js +108 -23
- package/lib/components/eftposPay/hooks.d.ts +1 -2
- package/lib/components/eftposPay/hooks.js +0 -16
- package/lib/components/eftposPay/linkly/index.js +0 -1
- package/lib/components/eftposPay/manufacturer.d.ts +0 -1
- package/lib/components/eftposPay/manufacturer.js +0 -6
- package/lib/components/eftposPay/pay.js +2 -4
- package/lib/components/eftposPay/store/index.d.ts +1 -1
- package/lib/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/lib/components/eftposPay/windcave/windcave.js +9 -9
- package/lib/components/eventBooking/components/Provider/Content/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/EmptyHolderModal/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Header/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/OrderProductModal/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/RemoveOptionConfirmModal.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/SelectHolderModal.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/bookingDetailModal/components/Resource.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +1 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/List/index.d.ts +0 -1
- package/lib/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/lib/components/shoppingCart/hooks/useAddService.d.ts +0 -1
- package/lib/components/shoppingCart/hooks/useClearCart.d.ts +0 -1
- package/lib/hooks/useEngineContext.d.ts +1 -0
- package/lib/hooks/useEngineContext.js +10 -2
- package/lib/index.d.ts +5 -1
- package/lib/index.js +13 -1
- package/lib/plus/clientName/index.d.ts +1 -0
- package/lib/plus/orderList/components/BatchActionBar.d.ts +9 -0
- package/lib/plus/orderList/components/BatchActionBar.js +567 -0
- package/lib/plus/orderList/components/FilterList.d.ts +8 -0
- package/lib/plus/orderList/components/FilterList.js +121 -0
- package/lib/plus/orderList/components/HandleActions.d.ts +4 -0
- package/lib/plus/orderList/components/HandleActions.js +52 -0
- package/lib/plus/orderList/components/QuickFilter.d.ts +4 -0
- package/lib/plus/orderList/components/QuickFilter.js +43 -0
- package/lib/plus/orderList/components/Reset.d.ts +6 -0
- package/lib/plus/orderList/components/Reset.js +58 -0
- package/lib/plus/orderList/components/Toolbar.d.ts +5 -0
- package/lib/plus/orderList/components/Toolbar.js +68 -0
- package/lib/plus/orderList/config.d.ts +154 -0
- package/lib/plus/orderList/config.js +764 -0
- package/lib/plus/orderList/index.d.ts +9 -0
- package/lib/plus/orderList/index.js +132 -0
- package/lib/plus/orderList/index.less +125 -0
- package/lib/plus/orderList/locales.d.ts +372 -0
- package/lib/plus/orderList/locales.js +471 -0
- package/lib/plus/orderList/serve.d.ts +42 -0
- package/lib/plus/orderList/serve.js +177 -0
- package/lib/plus/saasRegister/components/VertifyEmail.d.ts +0 -1
- package/lib/plus/skuOptionsSelection/components/OptionsCard/index.d.ts +0 -1
- package/lib/plus/skuOptionsSelection/components/OptionsCard/index.less +2 -0
- package/lib/plus/skuOptionsSelection/components/TitleExtra/index.d.ts +0 -1
- package/lib/plus/skuOptionsSelection/components/VariantCard/index.d.ts +0 -1
- package/lib/plus/skuOptionsSelection/index.js +2 -2
- package/lib/plus/skuOptionsSelection/utils/transformSelectorValueToValue.js +9 -2
- package/lib/plus/skuOptionsSelection/utils/transformValueToSelectorValue.js +7 -3
- package/lib/plus/walletPassGallery/components/passList/index.d.ts +0 -1
- package/lib/plus/walletPassGallery/components/timelineSection/index.d.ts +0 -1
- package/lib/pro/NumericStepper/index.d.ts +28 -3
- package/lib/pro/NumericStepper/index.js +176 -88
- package/lib/pro/NumericStepper/index.less +295 -143
- package/lib/pro/Selector/Selector.js +27 -16
- package/lib/pro/Selector/components/Card/index.js +9 -1
- package/lib/pro/Selector/components/Card/index.less +11 -4
- package/lib/pro/Selector/components/Indicator/index.d.ts +1 -0
- package/lib/pro/Selector/components/Indicator/index.js +1 -1
- package/lib/pro/Selector/components/Indicator/index.less +4 -1
- package/lib/pro/Selector/components/LayoutContainer/index.d.ts +5 -3
- package/lib/pro/Selector/components/LayoutContainer/index.js +130 -2
- package/lib/pro/Selector/components/LayoutContainer/index.less +19 -0
- package/lib/pro/Selector/demo.js +1 -1
- package/lib/pro/Selector/hooks/usePresetItemProps.js +2 -0
- package/lib/pro/Selector/hooks/usePresetProps.js +28 -6
- package/lib/pro/Selector/selector.less +0 -64
- package/lib/pro/Selector/types.d.ts +40 -0
- package/lib/pro/comprehensiveSearch/components/deviceIconGroup/index.d.ts +11 -0
- package/lib/pro/comprehensiveSearch/components/deviceIconGroup/index.js +64 -0
- package/lib/pro/comprehensiveSearch/components/deviceIconGroup/index.less +28 -0
- package/lib/pro/comprehensiveSearch/components/index.d.ts +2 -0
- package/lib/pro/comprehensiveSearch/components/index.js +42 -0
- package/lib/pro/comprehensiveSearch/components/searchSection/index.d.ts +24 -0
- package/lib/pro/comprehensiveSearch/components/searchSection/index.js +153 -0
- package/lib/pro/comprehensiveSearch/components/searchSection/index.less +100 -0
- package/lib/pro/comprehensiveSearch/components/searchSection/locales.d.ts +15 -0
- package/lib/pro/comprehensiveSearch/components/searchSection/locales.js +38 -0
- package/lib/pro/comprehensiveSearch/hooks/useNativeScanner.d.ts +5 -0
- package/lib/pro/comprehensiveSearch/hooks/useNativeScanner.js +56 -0
- package/lib/pro/comprehensiveSearch/hooks/useTerminalPeripherals.d.ts +9 -0
- package/lib/pro/comprehensiveSearch/hooks/useTerminalPeripherals.js +70 -0
- package/lib/pro/comprehensiveSearch/index.d.ts +7 -0
- package/lib/pro/comprehensiveSearch/index.js +190 -0
- package/lib/pro/comprehensiveSearch/index.less +196 -0
- package/lib/pro/comprehensiveSearch/locales.d.ts +15 -0
- package/lib/pro/comprehensiveSearch/locales.js +38 -0
- package/lib/pro/comprehensiveSearch/types.d.ts +32 -0
- package/lib/pro/comprehensiveSearch/types.js +17 -0
- package/lib/pro/keyboards/index.d.ts +2 -0
- package/lib/pro/keyboards/index.js +39 -0
- package/lib/pro/keyboards/locales.d.ts +24 -0
- package/lib/pro/keyboards/locales.js +47 -0
- package/lib/pro/keyboards/numberKeyboard/index.d.ts +16 -0
- package/lib/pro/keyboards/numberKeyboard/index.js +400 -0
- package/lib/pro/keyboards/numberKeyboard/index.less +59 -0
- package/lib/pro/keyboards/numberKeyboard/types.d.ts +63 -0
- package/lib/pro/keyboards/numberKeyboard/types.js +17 -0
- package/lib/pro/pisellPaymentList/example.d.ts +1 -0
- package/lowcode/eco-cup-list/meta.ts +63 -0
- package/lowcode/eco-customer-list/meta.ts +63 -0
- package/lowcode/ecocup-cup-list/meta.ts +38 -0
- package/lowcode/ecocup-cup-project/meta.ts +35 -0
- package/lowcode/ecocup-customer-list/meta.ts +38 -0
- package/lowcode/order-list/meta.ts +87 -0
- package/package.json +4 -4
- package/es/components/eftposPay/aggregatePayment/hooks/usePayment.d.ts +0 -6
- package/es/components/eftposPay/aggregatePayment/hooks/usePayment.js +0 -125
- package/es/components/eftposPay/aggregatePayment/index.d.ts +0 -3
- package/es/components/eftposPay/aggregatePayment/index.js +0 -3
- package/es/components/eftposPay/aggregatePayment/mock.d.ts +0 -495
- package/es/components/eftposPay/aggregatePayment/mock.js +0 -567
- package/es/components/eftposPay/aggregatePayment/service.d.ts +0 -24
- package/es/components/eftposPay/aggregatePayment/service.js +0 -70
- package/es/components/eftposPay/aggregatePayment/types.d.ts +0 -96
- package/es/components/eftposPay/aggregatePayment/types.js +0 -61
- package/es/components/eftposPay/aggregatePayment/utils/logs.d.ts +0 -110
- package/es/components/eftposPay/aggregatePayment/utils/logs.js +0 -385
- package/es/components/eftposPay/aggregatePayment/utils/payment.d.ts +0 -132
- package/es/components/eftposPay/aggregatePayment/utils/payment.js +0 -1127
- package/es/components/eftposPay/mx51/Action.d.ts +0 -6
- package/es/components/eftposPay/mx51/Action.js +0 -91
- package/es/components/eftposPay/mx51/const.d.ts +0 -5
- package/es/components/eftposPay/mx51/const.js +0 -69
- package/es/components/eftposPay/mx51/index.d.ts +0 -6
- package/es/components/eftposPay/mx51/index.js +0 -362
- package/es/components/eftposPay/mx51/types.d.ts +0 -136
- package/es/components/eftposPay/mx51/types.js +0 -29
- package/es/components/eftposPay/mx51/utils.d.ts +0 -10
- package/es/components/eftposPay/mx51/utils.js +0 -120
- package/lib/components/eftposPay/aggregatePayment/hooks/usePayment.d.ts +0 -6
- package/lib/components/eftposPay/aggregatePayment/hooks/usePayment.js +0 -152
- package/lib/components/eftposPay/aggregatePayment/index.d.ts +0 -3
- package/lib/components/eftposPay/aggregatePayment/mock.d.ts +0 -495
- package/lib/components/eftposPay/aggregatePayment/mock.js +0 -679
- package/lib/components/eftposPay/aggregatePayment/service.d.ts +0 -24
- package/lib/components/eftposPay/aggregatePayment/service.js +0 -81
- package/lib/components/eftposPay/aggregatePayment/types.d.ts +0 -96
- package/lib/components/eftposPay/aggregatePayment/types.js +0 -74
- package/lib/components/eftposPay/aggregatePayment/utils/logs.d.ts +0 -110
- package/lib/components/eftposPay/aggregatePayment/utils/logs.js +0 -302
- package/lib/components/eftposPay/aggregatePayment/utils/payment.d.ts +0 -132
- package/lib/components/eftposPay/aggregatePayment/utils/payment.js +0 -746
- package/lib/components/eftposPay/mx51/Action.d.ts +0 -6
- package/lib/components/eftposPay/mx51/Action.js +0 -127
- package/lib/components/eftposPay/mx51/const.d.ts +0 -5
- package/lib/components/eftposPay/mx51/const.js +0 -85
- package/lib/components/eftposPay/mx51/index.d.ts +0 -6
- package/lib/components/eftposPay/mx51/index.js +0 -330
- package/lib/components/eftposPay/mx51/types.d.ts +0 -136
- package/lib/components/eftposPay/mx51/utils.d.ts +0 -10
- package/lib/components/eftposPay/mx51/utils.js +0 -114
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
|
|
19
|
+
// src/components/ecocup/components/SearchBar/hooks.ts
|
|
20
|
+
var hooks_exports = {};
|
|
21
|
+
__export(hooks_exports, {
|
|
22
|
+
useCupScanStatus: () => useCupScanStatus,
|
|
23
|
+
useSearch: () => useSearch,
|
|
24
|
+
useSearchCup: () => useSearchCup,
|
|
25
|
+
useSearchCustomer: () => useSearchCustomer
|
|
26
|
+
});
|
|
27
|
+
module.exports = __toCommonJS(hooks_exports);
|
|
28
|
+
var import_react = require("react");
|
|
29
|
+
var import_utils = require("@pisell/utils");
|
|
30
|
+
var import_hooks = require("../../hooks");
|
|
31
|
+
var import_types = require("../../types");
|
|
32
|
+
var import_hooks2 = require("../../hooks");
|
|
33
|
+
var useSearchCustomer = () => {
|
|
34
|
+
const { get } = (0, import_hooks.useRequest)();
|
|
35
|
+
const { goalShopId } = (0, import_hooks2.useGetGoalShopInfo)();
|
|
36
|
+
const run = (text) => {
|
|
37
|
+
if (!text) return;
|
|
38
|
+
return get("/shop/wallet/eco/customer", {
|
|
39
|
+
search: text,
|
|
40
|
+
with: ["tags"],
|
|
41
|
+
goal_shop_id: goalShopId
|
|
42
|
+
});
|
|
43
|
+
};
|
|
44
|
+
return {
|
|
45
|
+
run
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
var useSearchCup = () => {
|
|
49
|
+
const { get } = (0, import_hooks.useRequest)();
|
|
50
|
+
const { goalShopId } = (0, import_hooks2.useGetGoalShopInfo)();
|
|
51
|
+
const run = (text) => {
|
|
52
|
+
if (!text) return;
|
|
53
|
+
return get("/shop/wallet/eco", {
|
|
54
|
+
type: "eco",
|
|
55
|
+
code: text,
|
|
56
|
+
with: [
|
|
57
|
+
"customer:id,display_name,cover,phone,country_calling_code,nickname",
|
|
58
|
+
"rentShop:id,name",
|
|
59
|
+
"returnShop:id,name",
|
|
60
|
+
"currentShop:id,name"
|
|
61
|
+
],
|
|
62
|
+
num: 1,
|
|
63
|
+
goal_shop_id: goalShopId
|
|
64
|
+
});
|
|
65
|
+
};
|
|
66
|
+
return {
|
|
67
|
+
run
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
var useSearch = () => {
|
|
71
|
+
const searchCustomer = useSearchCustomer();
|
|
72
|
+
const searchCup = useSearchCup();
|
|
73
|
+
const [loading, setLoading] = (0, import_react.useState)(false);
|
|
74
|
+
const run = async (params) => {
|
|
75
|
+
var _a, _b;
|
|
76
|
+
const { searchType, searchText = "" } = params;
|
|
77
|
+
const isCupCode = /^EC[a-zA-Z0-9]{8}$/.test(searchText);
|
|
78
|
+
if (searchType === "cup" && !isCupCode) {
|
|
79
|
+
return {
|
|
80
|
+
status: "failed",
|
|
81
|
+
message: import_utils.locales.getText("pisell2.text.ecocup.search-bar.search-tip")
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
const type = !!searchType ? searchType : isCupCode ? "cup" : "customer";
|
|
85
|
+
const runFn = type === "cup" ? searchCup.run : searchCustomer.run;
|
|
86
|
+
try {
|
|
87
|
+
setLoading(true);
|
|
88
|
+
const res = await runFn(searchText);
|
|
89
|
+
if ((_a = res == null ? void 0 : res.data) == null ? void 0 : _a.list) {
|
|
90
|
+
return { status: "success", type, data: ((_b = res == null ? void 0 : res.data) == null ? void 0 : _b.list) || [] };
|
|
91
|
+
} else {
|
|
92
|
+
return { status: "failed", type, message: (res == null ? void 0 : res.message) || "" };
|
|
93
|
+
}
|
|
94
|
+
} catch (error) {
|
|
95
|
+
return { status: "failed", type, message: (error == null ? void 0 : error.message) || "" };
|
|
96
|
+
} finally {
|
|
97
|
+
setLoading(false);
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
return { loading, run };
|
|
101
|
+
};
|
|
102
|
+
var useCupScanStatus = () => {
|
|
103
|
+
const shopId = (0, import_hooks.useGetShopId)();
|
|
104
|
+
const getCupScanStatus = (cup, customerId) => {
|
|
105
|
+
if (!cup) {
|
|
106
|
+
return import_types.ECupScanStatus.NOT_FOUND;
|
|
107
|
+
}
|
|
108
|
+
if ((cup == null ? void 0 : cup.status) == import_types.ECupStatus.IN_STOCK) {
|
|
109
|
+
if ((cup == null ? void 0 : cup.current_shop_id) != shopId) {
|
|
110
|
+
return import_types.ECupScanStatus.OTHER_IN_STOCK;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
if ((cup == null ? void 0 : cup.status) == import_types.ECupStatus.RENT) {
|
|
114
|
+
if ((cup == null ? void 0 : cup.customer_id) != customerId) {
|
|
115
|
+
return import_types.ECupScanStatus.OTHER_RENT;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
if ((cup == null ? void 0 : cup.status) == import_types.ECupStatus.MISSING) {
|
|
119
|
+
return import_types.ECupScanStatus.MISSING;
|
|
120
|
+
}
|
|
121
|
+
if ((cup == null ? void 0 : cup.status) == import_types.ECupStatus.BROKEN) {
|
|
122
|
+
return import_types.ECupScanStatus.BROKEN;
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
return {
|
|
126
|
+
getCupScanStatus
|
|
127
|
+
};
|
|
128
|
+
};
|
|
129
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
130
|
+
0 && (module.exports = {
|
|
131
|
+
useCupScanStatus,
|
|
132
|
+
useSearch,
|
|
133
|
+
useSearchCup,
|
|
134
|
+
useSearchCustomer
|
|
135
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import './index.less';
|
|
2
|
+
interface SearchBarProps {
|
|
3
|
+
scanListenerKey: string;
|
|
4
|
+
size?: 'large' | 'small';
|
|
5
|
+
placeholder?: string;
|
|
6
|
+
onSearch?: (value: string) => void;
|
|
7
|
+
searchType?: 'customer' | 'cup';
|
|
8
|
+
onSearchResult?: (v: any) => void;
|
|
9
|
+
customerId?: string;
|
|
10
|
+
}
|
|
11
|
+
declare const SearchBar: (props: SearchBarProps) => JSX.Element;
|
|
12
|
+
export default SearchBar;
|
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
21
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
22
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
23
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
24
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
25
|
+
mod
|
|
26
|
+
));
|
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
28
|
+
|
|
29
|
+
// src/components/ecocup/components/SearchBar/index.tsx
|
|
30
|
+
var SearchBar_exports = {};
|
|
31
|
+
__export(SearchBar_exports, {
|
|
32
|
+
default: () => SearchBar_default
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(SearchBar_exports);
|
|
35
|
+
var import_react = __toESM(require("react"));
|
|
36
|
+
var import_ahooks = require("ahooks");
|
|
37
|
+
var import_utils = require("@pisell/utils");
|
|
38
|
+
var import_materials = require("@pisell/materials");
|
|
39
|
+
var import_index = require("./index.less");
|
|
40
|
+
var import_searchSection = __toESM(require("../../../../pro/comprehensiveSearch/components/searchSection"));
|
|
41
|
+
var import_hooks = require("../../hooks");
|
|
42
|
+
var import_const = require("./const");
|
|
43
|
+
var import_hooks2 = require("./hooks");
|
|
44
|
+
var import_CupStatusModal = __toESM(require("../CupStatusModal"));
|
|
45
|
+
var import_dayjs = __toESM(require("dayjs"));
|
|
46
|
+
var SearchBar = (props) => {
|
|
47
|
+
var _a;
|
|
48
|
+
const {
|
|
49
|
+
scanListenerKey,
|
|
50
|
+
size = "large",
|
|
51
|
+
placeholder,
|
|
52
|
+
onSearch,
|
|
53
|
+
searchType,
|
|
54
|
+
onSearchResult,
|
|
55
|
+
customerId
|
|
56
|
+
} = props;
|
|
57
|
+
const [value, setValue] = (0, import_react.useState)("");
|
|
58
|
+
const [searchResult, setSearchResult] = (0, import_react.useState)(null);
|
|
59
|
+
const containerRef = (0, import_react.useRef)(null);
|
|
60
|
+
const { addListener, removeListener, setActiveListener } = (0, import_hooks.useScanListener)();
|
|
61
|
+
const searchHook = (0, import_hooks2.useSearch)();
|
|
62
|
+
const { getCupScanStatus } = (0, import_hooks2.useCupScanStatus)();
|
|
63
|
+
const cupStatusModal = (0, import_hooks.useModal)("ecocup-cup-status-modal");
|
|
64
|
+
const onSelectResult = (0, import_ahooks.useMemoizedFn)(
|
|
65
|
+
(type, item) => {
|
|
66
|
+
setSearchResult(null);
|
|
67
|
+
setValue("");
|
|
68
|
+
onSearchResult == null ? void 0 : onSearchResult({ type, data: item });
|
|
69
|
+
}
|
|
70
|
+
);
|
|
71
|
+
const scanSearchCallback = (0, import_ahooks.useMemoizedFn)((str) => {
|
|
72
|
+
console.log("scanSearchCallback>>>>>>>", str);
|
|
73
|
+
if (onSearch) {
|
|
74
|
+
onSearch(str || "");
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
if (!str) {
|
|
78
|
+
setValue("");
|
|
79
|
+
setSearchResult(null);
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
searchHook.run({ searchType, searchText: str }).then((res) => {
|
|
83
|
+
var _a2, _b, _c;
|
|
84
|
+
if ((res == null ? void 0 : res.status) === "success") {
|
|
85
|
+
if ((res == null ? void 0 : res.type) === "cup") {
|
|
86
|
+
const _cupData = ((_a2 = res == null ? void 0 : res.data) == null ? void 0 : _a2[0]) || null;
|
|
87
|
+
const scanStatus = getCupScanStatus(_cupData, customerId);
|
|
88
|
+
if (scanStatus) {
|
|
89
|
+
cupStatusModal.open({
|
|
90
|
+
data: {
|
|
91
|
+
scanStatus,
|
|
92
|
+
cupData: _cupData || { code: str }
|
|
93
|
+
}
|
|
94
|
+
});
|
|
95
|
+
return;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
const dataLength = ((_b = res == null ? void 0 : res.data) == null ? void 0 : _b.length) || 0;
|
|
99
|
+
if (dataLength === 1) {
|
|
100
|
+
setValue("");
|
|
101
|
+
setSearchResult(null);
|
|
102
|
+
onSelectResult(res == null ? void 0 : res.type, (_c = res == null ? void 0 : res.data) == null ? void 0 : _c[0]);
|
|
103
|
+
return;
|
|
104
|
+
}
|
|
105
|
+
if (dataLength === 0 && (res == null ? void 0 : res.type) === "customer") {
|
|
106
|
+
(0, import_materials.PisellToast)({
|
|
107
|
+
content: import_utils.locales.getText(
|
|
108
|
+
"pisell2.text.ecocup.toast.fail-no-match-customer"
|
|
109
|
+
)
|
|
110
|
+
});
|
|
111
|
+
setSearchResult(null);
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
114
|
+
setSearchResult(res == null ? void 0 : res.data);
|
|
115
|
+
} else {
|
|
116
|
+
if (res == null ? void 0 : res.message) {
|
|
117
|
+
(0, import_materials.PisellToast)({ content: res == null ? void 0 : res.message });
|
|
118
|
+
}
|
|
119
|
+
setSearchResult(null);
|
|
120
|
+
}
|
|
121
|
+
});
|
|
122
|
+
});
|
|
123
|
+
(0, import_react.useEffect)(() => {
|
|
124
|
+
addListener(scanListenerKey, (result) => {
|
|
125
|
+
setValue("");
|
|
126
|
+
setSearchResult(null);
|
|
127
|
+
scanSearchCallback((result == null ? void 0 : result.value) || "");
|
|
128
|
+
});
|
|
129
|
+
return () => {
|
|
130
|
+
removeListener(scanListenerKey);
|
|
131
|
+
};
|
|
132
|
+
}, [scanListenerKey, scanSearchCallback]);
|
|
133
|
+
(0, import_react.useEffect)(() => {
|
|
134
|
+
const handleClickOutside = (event) => {
|
|
135
|
+
const target = event.target;
|
|
136
|
+
if (!containerRef.current || !target) {
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
if (!containerRef.current.contains(target) && (searchResult == null ? void 0 : searchResult.length) > 1) {
|
|
140
|
+
setSearchResult(null);
|
|
141
|
+
}
|
|
142
|
+
};
|
|
143
|
+
document.addEventListener("mousedown", handleClickOutside);
|
|
144
|
+
return () => {
|
|
145
|
+
document.removeEventListener("mousedown", handleClickOutside);
|
|
146
|
+
};
|
|
147
|
+
}, [searchResult]);
|
|
148
|
+
return /* @__PURE__ */ import_react.default.createElement("div", { ref: containerRef, className: "ecocup-cup-search-bar" }, /* @__PURE__ */ import_react.default.createElement(
|
|
149
|
+
"div",
|
|
150
|
+
{
|
|
151
|
+
style: { flex: 1 },
|
|
152
|
+
onClick: () => {
|
|
153
|
+
console.log("onClick>>>>>>>", scanListenerKey);
|
|
154
|
+
setActiveListener(scanListenerKey);
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
/* @__PURE__ */ import_react.default.createElement(
|
|
158
|
+
import_searchSection.default,
|
|
159
|
+
{
|
|
160
|
+
value,
|
|
161
|
+
onChange: setValue,
|
|
162
|
+
loading: searchHook.loading,
|
|
163
|
+
style: {
|
|
164
|
+
flex: 1,
|
|
165
|
+
height: size === "large" ? "60px" : "48px",
|
|
166
|
+
padding: 0
|
|
167
|
+
},
|
|
168
|
+
placeholder: placeholder || import_utils.locales.getText("pisell2.text.cup-project.search-bar.placeholder"),
|
|
169
|
+
searchButtonProps: {
|
|
170
|
+
placement: "inside",
|
|
171
|
+
style: size === "large" ? {
|
|
172
|
+
height: 48,
|
|
173
|
+
padding: 8,
|
|
174
|
+
minWidth: 160
|
|
175
|
+
} : {
|
|
176
|
+
height: 32,
|
|
177
|
+
padding: 8,
|
|
178
|
+
minWidth: 120
|
|
179
|
+
}
|
|
180
|
+
},
|
|
181
|
+
cameraButtonProps: {
|
|
182
|
+
icon: ["pisell2-camera-01", "pisell2-qr-code-02"]
|
|
183
|
+
},
|
|
184
|
+
onSearch: () => scanSearchCallback(value)
|
|
185
|
+
}
|
|
186
|
+
)
|
|
187
|
+
), (searchResult == null ? void 0 : searchResult.length) > 1 ? /* @__PURE__ */ import_react.default.createElement("div", { className: "ecocup-cup-search-bar-result" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "ecocup-cup-search-bar-result-header" }, (_a = import_const.SEARCH_BAR_RESULT_HEADER_CONFIG) == null ? void 0 : _a.map((item) => /* @__PURE__ */ import_react.default.createElement("div", { key: item.key }, import_utils.locales.getText(item.label)))), /* @__PURE__ */ import_react.default.createElement("div", { className: "ecocup-cup-search-bar-result-content" }, searchResult == null ? void 0 : searchResult.map((item) => {
|
|
188
|
+
var _a2, _b;
|
|
189
|
+
const {
|
|
190
|
+
nickname,
|
|
191
|
+
display_name,
|
|
192
|
+
create_time,
|
|
193
|
+
country_calling_code,
|
|
194
|
+
phone,
|
|
195
|
+
email,
|
|
196
|
+
tags
|
|
197
|
+
} = item;
|
|
198
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
199
|
+
"div",
|
|
200
|
+
{
|
|
201
|
+
key: item.id,
|
|
202
|
+
className: "ecocup-cup-search-bar-result-content-item",
|
|
203
|
+
onClick: () => onSelectResult("customer", item)
|
|
204
|
+
},
|
|
205
|
+
/* @__PURE__ */ import_react.default.createElement("div", null, display_name || nickname || "-"),
|
|
206
|
+
/* @__PURE__ */ import_react.default.createElement("div", null, create_time ? (0, import_dayjs.default)(create_time).format("DD/MM/YYYY") : "-"),
|
|
207
|
+
/* @__PURE__ */ import_react.default.createElement("div", null, phone ? `(${country_calling_code}) ${phone}` : "-"),
|
|
208
|
+
/* @__PURE__ */ import_react.default.createElement("div", null, email || "-"),
|
|
209
|
+
/* @__PURE__ */ import_react.default.createElement("div", null, /* @__PURE__ */ import_react.default.createElement("span", { className: "ecocup-cup-search-bar-result-content-item-membership" }, ((_a2 = tags == null ? void 0 : tags.find) == null ? void 0 : _a2.call(tags, (v) => (v == null ? void 0 : v.name) == "admin")) ? "Admin" : ((_b = tags == null ? void 0 : tags.find) == null ? void 0 : _b.call(tags, (v) => (v == null ? void 0 : v.name) == "business")) ? "Business" : "Normal"))
|
|
210
|
+
);
|
|
211
|
+
}))) : null, cupStatusModal.visible && /* @__PURE__ */ import_react.default.createElement(import_CupStatusModal.default, { ...cupStatusModal.modalProps }));
|
|
212
|
+
};
|
|
213
|
+
var SearchBar_default = SearchBar;
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
.ecocup-cup-search-bar {
|
|
2
|
+
position: relative;
|
|
3
|
+
width: 100%;
|
|
4
|
+
display: flex;
|
|
5
|
+
flex: 1;
|
|
6
|
+
|
|
7
|
+
.comprehensive-search__search-section
|
|
8
|
+
.comprehensive-search__camera-activator.disabled {
|
|
9
|
+
width: fit-content;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.comprehensive-search__search-section
|
|
13
|
+
.comprehensive-search__camera-activator {
|
|
14
|
+
width: fit-content;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.comprehensive-search__search-section
|
|
18
|
+
.comprehensive-search__search-input-wrapper {
|
|
19
|
+
padding: 8px;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
&-result {
|
|
23
|
+
position: absolute;
|
|
24
|
+
top: 100%;
|
|
25
|
+
left: 0;
|
|
26
|
+
right: 0;
|
|
27
|
+
background-color: #fff;
|
|
28
|
+
border: 1px solid #d9d9d9;
|
|
29
|
+
border-radius: 6px;
|
|
30
|
+
z-index: 9;
|
|
31
|
+
|
|
32
|
+
&-header {
|
|
33
|
+
height: 44px;
|
|
34
|
+
display: flex;
|
|
35
|
+
align-items: center;
|
|
36
|
+
border-bottom: 1px solid #eaecf0;
|
|
37
|
+
background: #f9fafb;
|
|
38
|
+
|
|
39
|
+
& > div {
|
|
40
|
+
flex: 1;
|
|
41
|
+
display: flex;
|
|
42
|
+
align-items: center;
|
|
43
|
+
justify-content: center;
|
|
44
|
+
color: #475467;
|
|
45
|
+
font-size: 12px;
|
|
46
|
+
font-weight: 500;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&-content {
|
|
51
|
+
max-height: 220px;
|
|
52
|
+
display: flex;
|
|
53
|
+
flex-direction: column;
|
|
54
|
+
overflow-y: auto;
|
|
55
|
+
|
|
56
|
+
&-item {
|
|
57
|
+
min-height: 44px;
|
|
58
|
+
height: 44px;
|
|
59
|
+
display: flex;
|
|
60
|
+
align-items: center;
|
|
61
|
+
cursor: pointer;
|
|
62
|
+
border-bottom: 1px solid #eaecf0;
|
|
63
|
+
|
|
64
|
+
& > div {
|
|
65
|
+
flex: 1;
|
|
66
|
+
display: flex;
|
|
67
|
+
align-items: center;
|
|
68
|
+
justify-content: center;
|
|
69
|
+
color: #101828;
|
|
70
|
+
font-size: 12px;
|
|
71
|
+
font-weight: 500;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&-membership {
|
|
75
|
+
display: flex;
|
|
76
|
+
padding: 2px 8px;
|
|
77
|
+
border-radius: 16px;
|
|
78
|
+
border: 1px solid #fedf89;
|
|
79
|
+
background: #fffcf5;
|
|
80
|
+
color: #b54708;
|
|
81
|
+
text-align: center;
|
|
82
|
+
font-size: 12px;
|
|
83
|
+
font-weight: 500;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
declare const STATUS_TEXT_MAP: {
|
|
2
|
+
in_stock: string;
|
|
3
|
+
rent: string;
|
|
4
|
+
return: string;
|
|
5
|
+
missing: string;
|
|
6
|
+
broken: string;
|
|
7
|
+
shop_changed: string;
|
|
8
|
+
};
|
|
9
|
+
declare const STATUS_COLOR_MAP: {
|
|
10
|
+
in_stock: {
|
|
11
|
+
backgroundColor: string;
|
|
12
|
+
color: string;
|
|
13
|
+
border: string;
|
|
14
|
+
};
|
|
15
|
+
rent: {
|
|
16
|
+
backgroundColor: string;
|
|
17
|
+
color: string;
|
|
18
|
+
border: string;
|
|
19
|
+
};
|
|
20
|
+
return: {
|
|
21
|
+
backgroundColor: string;
|
|
22
|
+
color: string;
|
|
23
|
+
border: string;
|
|
24
|
+
};
|
|
25
|
+
shop_changed: {
|
|
26
|
+
backgroundColor: string;
|
|
27
|
+
color: string;
|
|
28
|
+
border: string;
|
|
29
|
+
};
|
|
30
|
+
overtime: {
|
|
31
|
+
backgroundColor: string;
|
|
32
|
+
color: string;
|
|
33
|
+
border: string;
|
|
34
|
+
};
|
|
35
|
+
expire_soon: {
|
|
36
|
+
backgroundColor: string;
|
|
37
|
+
color: string;
|
|
38
|
+
border: string;
|
|
39
|
+
};
|
|
40
|
+
borrowing: {
|
|
41
|
+
backgroundColor: string;
|
|
42
|
+
color: string;
|
|
43
|
+
border: string;
|
|
44
|
+
};
|
|
45
|
+
missing: {
|
|
46
|
+
backgroundColor: string;
|
|
47
|
+
color: string;
|
|
48
|
+
border: string;
|
|
49
|
+
};
|
|
50
|
+
broken: {
|
|
51
|
+
backgroundColor: string;
|
|
52
|
+
color: string;
|
|
53
|
+
border: string;
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
/**
|
|
57
|
+
* @description: 排序设置
|
|
58
|
+
* @return {*}
|
|
59
|
+
*/
|
|
60
|
+
declare const SORT_SETTINGS: {
|
|
61
|
+
show: boolean;
|
|
62
|
+
list: {
|
|
63
|
+
columnKey: string;
|
|
64
|
+
key: string;
|
|
65
|
+
type: string;
|
|
66
|
+
localFilter: boolean;
|
|
67
|
+
}[];
|
|
68
|
+
};
|
|
69
|
+
/**
|
|
70
|
+
* @description: 列配置
|
|
71
|
+
* @return {*}
|
|
72
|
+
*/
|
|
73
|
+
declare const COLUMN_SETTING: {
|
|
74
|
+
show: boolean;
|
|
75
|
+
storageMode: string;
|
|
76
|
+
};
|
|
77
|
+
/**
|
|
78
|
+
* @description: 过滤选项
|
|
79
|
+
* @return {*}
|
|
80
|
+
*/
|
|
81
|
+
declare const FILTER: (locales: any, isNormalShop: boolean, ecoShopLists?: any, isPartner?: boolean, currentPagination?: number) => {
|
|
82
|
+
show: boolean;
|
|
83
|
+
quickFilterMaxLength: number;
|
|
84
|
+
currentPagination: number;
|
|
85
|
+
list: ({
|
|
86
|
+
key: string;
|
|
87
|
+
type: string;
|
|
88
|
+
columnKey: string;
|
|
89
|
+
isCustom: boolean;
|
|
90
|
+
name: string;
|
|
91
|
+
sort: boolean;
|
|
92
|
+
localFilter: boolean;
|
|
93
|
+
other: {
|
|
94
|
+
size: string;
|
|
95
|
+
allowClear: boolean;
|
|
96
|
+
showSearch: boolean;
|
|
97
|
+
placeholder: any;
|
|
98
|
+
defaultValue: number;
|
|
99
|
+
options: {
|
|
100
|
+
label: any;
|
|
101
|
+
value: string | number;
|
|
102
|
+
}[];
|
|
103
|
+
style: {
|
|
104
|
+
width: number;
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
isHidden?: undefined;
|
|
108
|
+
} | {
|
|
109
|
+
key: string;
|
|
110
|
+
type: string;
|
|
111
|
+
columnKey: string;
|
|
112
|
+
isCustom: boolean;
|
|
113
|
+
name: string;
|
|
114
|
+
sort: boolean;
|
|
115
|
+
localFilter: boolean;
|
|
116
|
+
isHidden: boolean;
|
|
117
|
+
other: {
|
|
118
|
+
size: string;
|
|
119
|
+
allowClear: boolean;
|
|
120
|
+
showSearch: boolean;
|
|
121
|
+
placeholder: any;
|
|
122
|
+
defaultValue: number;
|
|
123
|
+
options: {
|
|
124
|
+
label: any;
|
|
125
|
+
value: any;
|
|
126
|
+
}[];
|
|
127
|
+
style: {
|
|
128
|
+
width: number;
|
|
129
|
+
};
|
|
130
|
+
};
|
|
131
|
+
})[];
|
|
132
|
+
};
|
|
133
|
+
export { STATUS_TEXT_MAP, STATUS_COLOR_MAP, SORT_SETTINGS, COLUMN_SETTING, FILTER, };
|