@pisell/private-materials 6.3.55 → 6.3.56
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 +10 -10
- package/es/components/appointmentBooking/components/Services/index.js +27 -24
- package/es/components/appointmentBooking/components/Voucher/index.js +14 -0
- package/es/components/booking/components/TabProduct/index.d.ts +0 -1
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +0 -1
- package/es/components/booking/components/voucher/index.js +29 -9
- package/es/components/booking/forms/table/index.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +0 -1
- package/es/components/booking/info/service/like/index.d.ts +0 -1
- package/es/components/eftpos/deviceList/index.d.ts +0 -1
- package/es/components/eftpos/form/index.d.ts +0 -1
- package/es/components/eftpos/group/index.d.ts +0 -1
- package/es/components/eftpos/hooks.d.ts +0 -1
- package/es/components/eftpos/icon/apiKey.d.ts +0 -1
- package/es/components/eftpos/icon/device.d.ts +0 -1
- package/es/components/eftpos/receipt/index.d.ts +0 -1
- package/es/components/eftposPay/component/alert/warn.d.ts +0 -1
- package/es/components/eftposPay/component/header/titlebar.d.ts +0 -1
- package/es/components/eftposPay/component/step/index.d.ts +0 -1
- package/es/components/eftposPay/component/step/step.d.ts +0 -1
- package/es/components/eftposPay/hooks.d.ts +1 -1
- package/es/components/eftposPay/store/index.d.ts +1 -1
- package/es/components/eftposPay/tyro/hooks.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +0 -1
- package/es/components/productExtension/fields/Actor/index.d.ts +0 -1
- package/es/components/productExtension/fields/Forms/index.d.ts +0 -1
- package/es/components/schedules/calendar/calendarItem.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +0 -1
- package/es/components/schedules/resources/relationProduct/index.d.ts +0 -1
- package/es/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/es/components/shoppingCart/components/Render/index.d.ts +0 -1
- package/es/components/walletList/index.js +173 -39
- package/es/components/walletList/locales.d.ts +9 -0
- package/es/components/walletList/locales.js +12 -3
- package/es/components/walletList/serve.d.ts +19 -0
- package/es/components/walletList/serve.js +94 -5
- package/es/components/walletList/tempHolderSelector/index.d.ts +14 -0
- package/es/components/walletList/tempHolderSelector/index.js +196 -0
- package/es/components/walletList/tempHolderSelector/index.less +63 -0
- package/es/index.d.ts +2 -1
- package/es/index.js +3 -2
- package/es/plus/clientName/index.d.ts +0 -1
- package/es/plus/selectHolder/components/ErrorTip/index.d.ts +3 -0
- package/es/plus/selectHolder/components/ErrorTip/index.js +14 -0
- package/es/plus/selectHolder/components/ErrorTip/index.less +51 -0
- package/es/plus/selectHolder/components/HolderItem/index.d.ts +6 -0
- package/es/plus/selectHolder/components/HolderItem/index.js +77 -0
- package/es/plus/selectHolder/components/HolderItem/index.less +105 -0
- package/es/plus/selectHolder/components/HolderList/index.d.ts +30 -0
- package/es/plus/selectHolder/components/HolderList/index.js +43 -0
- package/es/plus/selectHolder/index.d.ts +7 -0
- package/es/plus/selectHolder/index.js +236 -0
- package/es/plus/selectHolder/index.less +117 -0
- package/es/plus/selectHolder/locales.d.ts +21 -0
- package/es/plus/selectHolder/locales.js +20 -0
- package/es/plus/selectHolder/types.d.ts +104 -0
- package/es/plus/selectHolder/types.js +1 -0
- package/es/plus/selectHolder/utils.d.ts +9 -0
- package/es/plus/selectHolder/utils.js +16 -0
- package/es/plus/walletEditor/WalletEditor.js +60 -2
- package/es/plus/walletEditor/locales.d.ts +9 -0
- package/es/plus/walletEditor/locales.js +12 -3
- package/es/plus/walletPassGallery/components/passList/index.d.ts +1 -0
- package/es/plus/walletPassGallery/components/passList/index.js +17 -5
- package/es/plus/walletPassGallery/index.js +223 -41
- package/es/plus/walletPassGallery/locales.d.ts +15 -0
- package/es/plus/walletPassGallery/locales.js +29 -5
- package/es/plus/walletPassGallery/serve.d.ts +15 -1
- package/es/plus/walletPassGallery/serve.js +59 -2
- package/es/plus/walletPassGallery/utils.d.ts +48 -0
- package/es/plus/walletPassGallery/utils.js +342 -0
- package/es/pro/pisellPaymentList/example.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Services/index.js +5 -2
- package/lib/components/appointmentBooking/components/Voucher/index.js +12 -0
- package/lib/components/booking/components/TabProduct/index.d.ts +0 -1
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +0 -1
- package/lib/components/booking/components/voucher/index.js +29 -6
- package/lib/components/booking/forms/table/index.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +0 -1
- package/lib/components/booking/info/service/like/index.d.ts +0 -1
- package/lib/components/eftpos/deviceList/index.d.ts +0 -1
- package/lib/components/eftpos/form/index.d.ts +0 -1
- package/lib/components/eftpos/group/index.d.ts +0 -1
- package/lib/components/eftpos/hooks.d.ts +0 -1
- package/lib/components/eftpos/icon/apiKey.d.ts +0 -1
- package/lib/components/eftpos/icon/device.d.ts +0 -1
- package/lib/components/eftpos/receipt/index.d.ts +0 -1
- package/lib/components/eftposPay/component/alert/warn.d.ts +0 -1
- package/lib/components/eftposPay/component/header/titlebar.d.ts +0 -1
- package/lib/components/eftposPay/component/step/index.d.ts +0 -1
- package/lib/components/eftposPay/component/step/step.d.ts +0 -1
- package/lib/components/eftposPay/hooks.d.ts +1 -1
- package/lib/components/eftposPay/store/index.d.ts +1 -1
- package/lib/components/eftposPay/tyro/hooks.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +0 -1
- package/lib/components/productExtension/fields/Actor/index.d.ts +0 -1
- package/lib/components/productExtension/fields/Forms/index.d.ts +0 -1
- package/lib/components/schedules/calendar/calendarItem.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +0 -1
- package/lib/components/schedules/resources/relationProduct/index.d.ts +0 -1
- package/lib/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/lib/components/shoppingCart/components/Render/index.d.ts +0 -1
- package/lib/components/walletList/index.js +100 -4
- package/lib/components/walletList/locales.d.ts +9 -0
- package/lib/components/walletList/locales.js +12 -3
- package/lib/components/walletList/serve.d.ts +19 -0
- package/lib/components/walletList/serve.js +26 -3
- package/lib/components/walletList/tempHolderSelector/index.d.ts +14 -0
- package/lib/components/walletList/tempHolderSelector/index.js +166 -0
- package/lib/components/walletList/tempHolderSelector/index.less +63 -0
- package/lib/index.d.ts +2 -1
- package/lib/index.js +6 -3
- package/lib/plus/clientName/index.d.ts +0 -1
- package/lib/plus/selectHolder/components/ErrorTip/index.d.ts +3 -0
- package/lib/{components/wallet/PointCard/model.js → plus/selectHolder/components/ErrorTip/index.js} +10 -23
- package/lib/plus/selectHolder/components/ErrorTip/index.less +51 -0
- package/lib/plus/selectHolder/components/HolderItem/index.d.ts +6 -0
- package/lib/plus/selectHolder/components/HolderItem/index.js +101 -0
- package/lib/plus/selectHolder/components/HolderItem/index.less +105 -0
- package/lib/plus/selectHolder/components/HolderList/index.d.ts +30 -0
- package/lib/{components/wallet/components/WalletBar → plus/selectHolder/components/HolderList}/index.js +29 -15
- package/lib/plus/selectHolder/index.d.ts +7 -0
- package/lib/plus/selectHolder/index.js +202 -0
- package/lib/plus/selectHolder/index.less +117 -0
- package/lib/plus/selectHolder/locales.d.ts +21 -0
- package/lib/{components/wallet/Voucher → plus/selectHolder}/locales.js +15 -15
- package/lib/plus/selectHolder/types.d.ts +104 -0
- package/lib/plus/selectHolder/types.js +17 -0
- package/lib/plus/selectHolder/utils.d.ts +9 -0
- package/lib/{components/wallet/RechargeableCard/serve.js → plus/selectHolder/utils.js} +11 -10
- package/lib/plus/walletEditor/WalletEditor.js +53 -0
- package/lib/plus/walletEditor/locales.d.ts +9 -0
- package/lib/plus/walletEditor/locales.js +12 -3
- package/lib/plus/walletPassGallery/components/passList/index.d.ts +1 -0
- package/lib/plus/walletPassGallery/components/passList/index.js +16 -4
- package/lib/plus/walletPassGallery/index.js +154 -27
- package/lib/plus/walletPassGallery/locales.d.ts +15 -0
- package/lib/plus/walletPassGallery/locales.js +32 -5
- package/lib/plus/walletPassGallery/serve.d.ts +15 -1
- package/lib/plus/walletPassGallery/serve.js +17 -5
- package/lib/plus/walletPassGallery/utils.d.ts +48 -0
- package/lib/plus/walletPassGallery/utils.js +287 -0
- package/lib/pro/pisellPaymentList/example.d.ts +0 -1
- package/lowcode/event-select-holder/meta.ts +2 -2
- package/lowcode/select-holder/meta.ts +220 -0
- package/lowcode/select-holder/snippets.ts +41 -0
- package/package.json +4 -4
- package/es/components/wallet/Detail/index.d.ts +0 -42
- package/es/components/wallet/Detail/index.js +0 -1182
- package/es/components/wallet/Detail/index.less +0 -386
- package/es/components/wallet/Detail/locales.d.ts +0 -153
- package/es/components/wallet/Detail/locales.js +0 -170
- package/es/components/wallet/Detail/model.d.ts +0 -13
- package/es/components/wallet/Detail/model.js +0 -22
- package/es/components/wallet/Detail/serve.d.ts +0 -39
- package/es/components/wallet/Detail/serve.js +0 -64
- package/es/components/wallet/DetailContext.d.ts +0 -25
- package/es/components/wallet/DetailContext.js +0 -162
- package/es/components/wallet/DiscountCard/index.d.ts +0 -3
- package/es/components/wallet/DiscountCard/index.js +0 -218
- package/es/components/wallet/DiscountCard/index.less +0 -9
- package/es/components/wallet/DiscountCard/model.d.ts +0 -14
- package/es/components/wallet/DiscountCard/model.js +0 -22
- package/es/components/wallet/PointCard/index.d.ts +0 -3
- package/es/components/wallet/PointCard/index.js +0 -169
- package/es/components/wallet/PointCard/index.less +0 -9
- package/es/components/wallet/PointCard/model.d.ts +0 -13
- package/es/components/wallet/PointCard/model.js +0 -22
- package/es/components/wallet/RechargeableCard/index.d.ts +0 -13
- package/es/components/wallet/RechargeableCard/index.js +0 -463
- package/es/components/wallet/RechargeableCard/index.less +0 -108
- package/es/components/wallet/RechargeableCard/model.d.ts +0 -29
- package/es/components/wallet/RechargeableCard/model.js +0 -28
- package/es/components/wallet/RechargeableCard/serve.d.ts +0 -23
- package/es/components/wallet/RechargeableCard/serve.js +0 -32
- package/es/components/wallet/Voucher/index.d.ts +0 -12
- package/es/components/wallet/Voucher/index.js +0 -131
- package/es/components/wallet/Voucher/index.less +0 -9
- package/es/components/wallet/Voucher/locales.d.ts +0 -21
- package/es/components/wallet/Voucher/locales.js +0 -20
- package/es/components/wallet/Voucher/model.d.ts +0 -13
- package/es/components/wallet/Voucher/model.js +0 -22
- package/es/components/wallet/carouselArrow.png +0 -0
- package/es/components/wallet/components/FooterButtons/index.d.ts +0 -18
- package/es/components/wallet/components/FooterButtons/index.js +0 -81
- package/es/components/wallet/components/FooterButtons/index.less +0 -91
- package/es/components/wallet/components/UsageRules/index.d.ts +0 -23
- package/es/components/wallet/components/UsageRules/index.js +0 -147
- package/es/components/wallet/components/UsageRules/index.less +0 -157
- package/es/components/wallet/components/WalletBar/index.d.ts +0 -8
- package/es/components/wallet/components/WalletBar/index.js +0 -19
- package/es/components/wallet/components/WalletBar/index.less +0 -36
- package/es/components/wallet/components/WalletCard.d.ts +0 -11
- package/es/components/wallet/components/WalletCard.js +0 -91
- package/es/components/wallet/components/index.d.ts +0 -3
- package/es/components/wallet/components/index.js +0 -4
- package/es/components/wallet/hooks/useWalletCard.d.ts +0 -33
- package/es/components/wallet/hooks/useWalletCard.js +0 -147
- package/es/components/wallet/index.d.ts +0 -10
- package/es/components/wallet/index.js +0 -807
- package/es/components/wallet/index.less +0 -151
- package/es/components/wallet/locales.d.ts +0 -132
- package/es/components/wallet/locales.js +0 -139
- package/es/components/wallet/model.d.ts +0 -37
- package/es/components/wallet/model.js +0 -86
- package/es/components/wallet/serve.d.ts +0 -150
- package/es/components/wallet/serve.js +0 -205
- package/es/components/wallet/utils/formatUtils.d.ts +0 -36
- package/es/components/wallet/utils/formatUtils.js +0 -73
- package/lib/components/wallet/Detail/index.d.ts +0 -42
- package/lib/components/wallet/Detail/index.js +0 -874
- package/lib/components/wallet/Detail/index.less +0 -386
- package/lib/components/wallet/Detail/locales.d.ts +0 -153
- package/lib/components/wallet/Detail/locales.js +0 -194
- package/lib/components/wallet/Detail/model.d.ts +0 -13
- package/lib/components/wallet/Detail/model.js +0 -43
- package/lib/components/wallet/Detail/serve.d.ts +0 -39
- package/lib/components/wallet/Detail/serve.js +0 -44
- package/lib/components/wallet/DetailContext.d.ts +0 -25
- package/lib/components/wallet/DetailContext.js +0 -118
- package/lib/components/wallet/DiscountCard/index.d.ts +0 -3
- package/lib/components/wallet/DiscountCard/index.js +0 -209
- package/lib/components/wallet/DiscountCard/index.less +0 -9
- package/lib/components/wallet/DiscountCard/model.d.ts +0 -14
- package/lib/components/wallet/DiscountCard/model.js +0 -43
- package/lib/components/wallet/PointCard/index.d.ts +0 -3
- package/lib/components/wallet/PointCard/index.js +0 -190
- package/lib/components/wallet/PointCard/index.less +0 -9
- package/lib/components/wallet/PointCard/model.d.ts +0 -13
- package/lib/components/wallet/RechargeableCard/index.d.ts +0 -13
- package/lib/components/wallet/RechargeableCard/index.js +0 -380
- package/lib/components/wallet/RechargeableCard/index.less +0 -108
- package/lib/components/wallet/RechargeableCard/model.d.ts +0 -29
- package/lib/components/wallet/RechargeableCard/model.js +0 -49
- package/lib/components/wallet/RechargeableCard/serve.d.ts +0 -23
- package/lib/components/wallet/Voucher/index.d.ts +0 -12
- package/lib/components/wallet/Voucher/index.js +0 -146
- package/lib/components/wallet/Voucher/index.less +0 -9
- package/lib/components/wallet/Voucher/locales.d.ts +0 -21
- package/lib/components/wallet/Voucher/model.d.ts +0 -13
- package/lib/components/wallet/Voucher/model.js +0 -43
- package/lib/components/wallet/carouselArrow.png +0 -0
- package/lib/components/wallet/components/FooterButtons/index.d.ts +0 -18
- package/lib/components/wallet/components/FooterButtons/index.js +0 -109
- package/lib/components/wallet/components/FooterButtons/index.less +0 -91
- package/lib/components/wallet/components/UsageRules/index.d.ts +0 -23
- package/lib/components/wallet/components/UsageRules/index.js +0 -113
- package/lib/components/wallet/components/UsageRules/index.less +0 -157
- package/lib/components/wallet/components/WalletBar/index.d.ts +0 -8
- package/lib/components/wallet/components/WalletBar/index.less +0 -36
- package/lib/components/wallet/components/WalletCard.d.ts +0 -11
- package/lib/components/wallet/components/WalletCard.js +0 -97
- package/lib/components/wallet/components/index.d.ts +0 -3
- package/lib/components/wallet/components/index.js +0 -45
- package/lib/components/wallet/hooks/useWalletCard.d.ts +0 -33
- package/lib/components/wallet/hooks/useWalletCard.js +0 -111
- package/lib/components/wallet/index.d.ts +0 -10
- package/lib/components/wallet/index.js +0 -580
- package/lib/components/wallet/index.less +0 -151
- package/lib/components/wallet/locales.d.ts +0 -132
- package/lib/components/wallet/locales.js +0 -163
- package/lib/components/wallet/model.d.ts +0 -37
- package/lib/components/wallet/model.js +0 -91
- package/lib/components/wallet/serve.d.ts +0 -150
- package/lib/components/wallet/serve.js +0 -85
- package/lib/components/wallet/utils/formatUtils.d.ts +0 -36
- package/lib/components/wallet/utils/formatUtils.js +0 -73
|
@@ -68,7 +68,10 @@ var locales_default = {
|
|
|
68
68
|
enterJSONConfig: 'Enter JSON config, e.g. {"type": "register"}',
|
|
69
69
|
selectValidityPeriod: "Select validity period",
|
|
70
70
|
selectCustomDate: "Select custom date",
|
|
71
|
-
registerToIssue: "Register to issue"
|
|
71
|
+
registerToIssue: "Register to issue",
|
|
72
|
+
"pisell2.wallet-editor.holder": "Holder",
|
|
73
|
+
"pisell2.wallet-editor.holder.required": "Please select a holder",
|
|
74
|
+
"pisell2.wallet-editor.holder.invalid": "Invalid holder. Please select again"
|
|
72
75
|
},
|
|
73
76
|
"zh-CN": {
|
|
74
77
|
// 表单标签
|
|
@@ -115,7 +118,10 @@ var locales_default = {
|
|
|
115
118
|
enterJSONConfig: '输入JSON配置,例如 {"type": "register"}',
|
|
116
119
|
selectValidityPeriod: "选择有效期",
|
|
117
120
|
selectCustomDate: "选择自定义日期",
|
|
118
|
-
registerToIssue: "注册即发放"
|
|
121
|
+
registerToIssue: "注册即发放",
|
|
122
|
+
"pisell2.wallet-editor.holder": "持有人",
|
|
123
|
+
"pisell2.wallet-editor.holder.required": "请选择持有人",
|
|
124
|
+
"pisell2.wallet-editor.holder.invalid": "无效持有人,请重新选择"
|
|
119
125
|
},
|
|
120
126
|
"zh-HK": {
|
|
121
127
|
// 表單標籤
|
|
@@ -162,6 +168,9 @@ var locales_default = {
|
|
|
162
168
|
enterJSONConfig: '輸入JSON配置,例如 {"type": "register"}',
|
|
163
169
|
selectValidityPeriod: "選擇有效期",
|
|
164
170
|
selectCustomDate: "選擇自定義日期",
|
|
165
|
-
registerToIssue: "註冊即發放"
|
|
171
|
+
registerToIssue: "註冊即發放",
|
|
172
|
+
"pisell2.wallet-editor.holder": "持有人",
|
|
173
|
+
"pisell2.wallet-editor.holder.required": "請選擇持有人",
|
|
174
|
+
"pisell2.wallet-editor.holder.invalid": "無效持有人,請重新選擇"
|
|
166
175
|
}
|
|
167
176
|
};
|
|
@@ -44,7 +44,8 @@ var PassList = (props) => {
|
|
|
44
44
|
valuePropName = "id",
|
|
45
45
|
hasMore,
|
|
46
46
|
onLoadMore,
|
|
47
|
-
loading
|
|
47
|
+
loading,
|
|
48
|
+
onEditHolder
|
|
48
49
|
} = props;
|
|
49
50
|
const _loadMore = /* @__PURE__ */ import_react.default.createElement(
|
|
50
51
|
"div",
|
|
@@ -66,7 +67,7 @@ var PassList = (props) => {
|
|
|
66
67
|
import_utils.locales.getText("wallet-pass-gallery.allLoaded")
|
|
67
68
|
)
|
|
68
69
|
);
|
|
69
|
-
return /* @__PURE__ */ import_react.default.createElement(
|
|
70
|
+
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement(
|
|
70
71
|
import_antd.List,
|
|
71
72
|
{
|
|
72
73
|
className: "pisell-wallet-pass-gallery_list",
|
|
@@ -89,6 +90,8 @@ var PassList = (props) => {
|
|
|
89
90
|
product_cover = "",
|
|
90
91
|
par_value = "",
|
|
91
92
|
unified_messages = {},
|
|
93
|
+
holder,
|
|
94
|
+
metadata,
|
|
92
95
|
...rest
|
|
93
96
|
} = item;
|
|
94
97
|
const itemValue = item == null ? void 0 : item[valuePropName];
|
|
@@ -125,12 +128,21 @@ var PassList = (props) => {
|
|
|
125
128
|
discount: isDiscountCard ? Number(par_value) : void 0,
|
|
126
129
|
showDiscount: isDiscountCard,
|
|
127
130
|
code: encoded,
|
|
128
|
-
validDate: expire_date
|
|
131
|
+
validDate: expire_date,
|
|
132
|
+
holder,
|
|
133
|
+
onSetHolder: () => {
|
|
134
|
+
var _a;
|
|
135
|
+
onEditHolder == null ? void 0 : onEditHolder({
|
|
136
|
+
wallet_pass_detail_id: id,
|
|
137
|
+
customer_id: holder == null ? void 0 : holder.customer_id,
|
|
138
|
+
form_id: (_a = holder == null ? void 0 : holder.metadata) == null ? void 0 : _a.custom_id
|
|
139
|
+
});
|
|
140
|
+
}
|
|
129
141
|
}
|
|
130
142
|
)
|
|
131
143
|
));
|
|
132
144
|
}
|
|
133
145
|
}
|
|
134
|
-
);
|
|
146
|
+
));
|
|
135
147
|
};
|
|
136
148
|
var passList_default = PassList;
|
|
@@ -44,6 +44,7 @@ var import_utils2 = require("../../utils");
|
|
|
44
44
|
var import_useEngineContext = __toESM(require("../../hooks/useEngineContext"));
|
|
45
45
|
var import_passList = __toESM(require("./components/passList"));
|
|
46
46
|
var import_passDetail = __toESM(require("./components/passDetail"));
|
|
47
|
+
var import_tempHolderSelector = __toESM(require("../../components/walletList/tempHolderSelector"));
|
|
47
48
|
var import_index = require("./index.less");
|
|
48
49
|
var { Title } = import_antd.Typography;
|
|
49
50
|
var KEYS = {
|
|
@@ -65,6 +66,8 @@ var WalletPassGallery = (props) => {
|
|
|
65
66
|
const [currentItemId, setCurrentItemId] = (0, import_react.useState)(void 0);
|
|
66
67
|
const [isOpenAddModal, setIsOpenAddModal] = (0, import_react.useState)(false);
|
|
67
68
|
const [currentUnbindItem, setCurrentUnbindItem] = (0, import_react.useState)(null);
|
|
69
|
+
const [editHolderData, setEditHolderData] = (0, import_react.useState)(null);
|
|
70
|
+
const [updateHolderLoading, setUpdateHolderLoading] = (0, import_react.useState)(false);
|
|
68
71
|
const context = (0, import_useEngineContext.default)();
|
|
69
72
|
const utils = ((_a = context == null ? void 0 : context.appHelper) == null ? void 0 : _a.utils) || {};
|
|
70
73
|
const platform = (0, import_react.useMemo)(() => {
|
|
@@ -83,14 +86,17 @@ var WalletPassGallery = (props) => {
|
|
|
83
86
|
});
|
|
84
87
|
const _getAvailableList = (0, import_ahooks.useInfiniteScroll)(
|
|
85
88
|
async (d) => {
|
|
86
|
-
const
|
|
87
|
-
const
|
|
89
|
+
const _searchParams = new URLSearchParams(window.location.search);
|
|
90
|
+
const walletId = _searchParams.get("id");
|
|
91
|
+
const holderId = _searchParams.get("holder_id");
|
|
92
|
+
const res = await (0, import_serve.getWalletPassList)({
|
|
88
93
|
available: 1,
|
|
89
94
|
num: 20,
|
|
90
95
|
skip: (d == null ? void 0 : d.nextId) || 1,
|
|
91
96
|
tags: TAGS,
|
|
92
97
|
filter_wallet_id: walletId || void 0,
|
|
93
|
-
|
|
98
|
+
filter_holder_id: holderId || void 0,
|
|
99
|
+
with: ["holder.detail"]
|
|
94
100
|
});
|
|
95
101
|
return {
|
|
96
102
|
list: (res == null ? void 0 : res.list) || [],
|
|
@@ -110,14 +116,17 @@ var WalletPassGallery = (props) => {
|
|
|
110
116
|
);
|
|
111
117
|
const _getUnavailableList = (0, import_ahooks.useInfiniteScroll)(
|
|
112
118
|
async (d) => {
|
|
113
|
-
const
|
|
114
|
-
const
|
|
119
|
+
const _searchParams = new URLSearchParams(window.location.search);
|
|
120
|
+
const walletId = _searchParams.get("id");
|
|
121
|
+
const holderId = _searchParams.get("holder_id");
|
|
122
|
+
const res = await (0, import_serve.getWalletPassList)({
|
|
115
123
|
available: 0,
|
|
116
124
|
num: 20,
|
|
117
125
|
skip: (d == null ? void 0 : d.nextId) || 1,
|
|
118
126
|
tags: TAGS,
|
|
119
127
|
filter_wallet_id: walletId || void 0,
|
|
120
|
-
|
|
128
|
+
filter_holder_id: holderId || void 0,
|
|
129
|
+
with: ["holder.detail"]
|
|
121
130
|
});
|
|
122
131
|
return {
|
|
123
132
|
list: (res == null ? void 0 : res.list) || [],
|
|
@@ -135,24 +144,82 @@ var WalletPassGallery = (props) => {
|
|
|
135
144
|
);
|
|
136
145
|
(0, import_react.useEffect)(() => {
|
|
137
146
|
const walletId = new URLSearchParams(window.location.search).get("id");
|
|
147
|
+
const passId = new URLSearchParams(window.location.search).get(
|
|
148
|
+
"wallet_pass_detail_id"
|
|
149
|
+
);
|
|
138
150
|
if (walletId) {
|
|
139
151
|
_getWalletDetail.runAsync(walletId);
|
|
140
152
|
}
|
|
141
153
|
const req1 = _getAvailableList.loadMoreAsync();
|
|
142
154
|
const req2 = _getUnavailableList.loadMoreAsync();
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
155
|
+
let req3 = passId ? (0, import_serve.getWalletPassDetail)(passId, {
|
|
156
|
+
with: ["holder.detail"]
|
|
157
|
+
}) : Promise.resolve();
|
|
158
|
+
Promise.all([req1, req2, req3]).then(([data1, data2, data3]) => {
|
|
159
|
+
var _a2, _b2, _c2, _d2, _e2;
|
|
160
|
+
if (platform !== "h5") {
|
|
161
|
+
const list1 = (data1 == null ? void 0 : data1.list) || [];
|
|
162
|
+
const list2 = (data2 == null ? void 0 : data2.list) || [];
|
|
163
|
+
if (passId) {
|
|
164
|
+
const matchedInList1 = list1.find(
|
|
165
|
+
(item) => String(item.id) === passId
|
|
166
|
+
);
|
|
167
|
+
const matchedInList2 = list2.find(
|
|
168
|
+
(item) => String(item.id) === passId
|
|
169
|
+
);
|
|
170
|
+
if (matchedInList1 || matchedInList2) {
|
|
171
|
+
setCurrentItemId(Number(passId));
|
|
172
|
+
if (matchedInList2) {
|
|
173
|
+
setActiveKey("unavailable");
|
|
174
|
+
}
|
|
175
|
+
} else {
|
|
176
|
+
if (data3) {
|
|
177
|
+
if (data3.unified_available_status === 1) {
|
|
178
|
+
_getAvailableList.mutate((data) => ({
|
|
179
|
+
...data,
|
|
180
|
+
list: [data3, ...(data == null ? void 0 : data.list) || []]
|
|
181
|
+
}));
|
|
182
|
+
setCurrentItemId(data3.id);
|
|
183
|
+
} else {
|
|
184
|
+
_getUnavailableList.mutate((data) => ({
|
|
185
|
+
...data,
|
|
186
|
+
list: [data3, ...(data == null ? void 0 : data.list) || []]
|
|
187
|
+
}));
|
|
188
|
+
setCurrentItemId(data3.id);
|
|
189
|
+
setActiveKey("unavailable");
|
|
190
|
+
}
|
|
191
|
+
} else {
|
|
192
|
+
const firstAvailable = list1[0];
|
|
193
|
+
if (firstAvailable) {
|
|
194
|
+
setCurrentItemId(firstAvailable.id);
|
|
195
|
+
} else {
|
|
196
|
+
const firstUnavailable = list2[0];
|
|
197
|
+
if (firstUnavailable) {
|
|
198
|
+
setCurrentItemId(firstUnavailable.id);
|
|
199
|
+
setActiveKey("unavailable");
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
if (data3 && ((_a2 = data3.holder) == null ? void 0 : _a2.holder_type) === "form" && !((_b2 = data3.holder) == null ? void 0 : _b2.holder_id)) {
|
|
205
|
+
setEditHolderData({
|
|
206
|
+
wallet_pass_detail_id: passId,
|
|
207
|
+
customer_id: (_c2 = data3.holder) == null ? void 0 : _c2.customer_id,
|
|
208
|
+
form_id: (_e2 = (_d2 = data3.holder) == null ? void 0 : _d2.metadata) == null ? void 0 : _e2.custom_id
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
} else {
|
|
212
|
+
const firstAvailable = list1[0];
|
|
213
|
+
if (firstAvailable) {
|
|
214
|
+
setCurrentItemId(firstAvailable.id);
|
|
215
|
+
} else {
|
|
216
|
+
const firstUnavailable = list2[0];
|
|
217
|
+
if (firstUnavailable) {
|
|
218
|
+
setCurrentItemId(firstUnavailable.id);
|
|
219
|
+
setActiveKey("unavailable");
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
}
|
|
156
223
|
}
|
|
157
224
|
});
|
|
158
225
|
}, []);
|
|
@@ -199,10 +266,6 @@ var WalletPassGallery = (props) => {
|
|
|
199
266
|
const newId = key === KEYS.unavailable ? (_a2 = _unavailable[0]) == null ? void 0 : _a2.id : (_b2 = _avaliable[0]) == null ? void 0 : _b2.id;
|
|
200
267
|
setCurrentItemId(newId);
|
|
201
268
|
};
|
|
202
|
-
const _handleMenuChange = (key) => {
|
|
203
|
-
setActiveKey(key);
|
|
204
|
-
setCurrentItemId(void 0);
|
|
205
|
-
};
|
|
206
269
|
const _resetSearchState = () => {
|
|
207
270
|
setCurrentUnbindItem(null);
|
|
208
271
|
_getUnbindList.mutate([]);
|
|
@@ -251,6 +314,53 @@ var WalletPassGallery = (props) => {
|
|
|
251
314
|
});
|
|
252
315
|
}
|
|
253
316
|
};
|
|
317
|
+
const _handleHolderChange = (passId, holder) => {
|
|
318
|
+
if (_avaliable.find((item) => item.id === passId)) {
|
|
319
|
+
_getAvailableList.mutate((data) => {
|
|
320
|
+
const newList = data.list.map(
|
|
321
|
+
(item) => item.id === passId ? { ...item, holder } : item
|
|
322
|
+
);
|
|
323
|
+
return {
|
|
324
|
+
...data,
|
|
325
|
+
list: newList
|
|
326
|
+
};
|
|
327
|
+
});
|
|
328
|
+
} else if (_unavailable.find((item) => item.id === passId)) {
|
|
329
|
+
_getUnavailableList.mutate((data) => {
|
|
330
|
+
const newList = data.list.map(
|
|
331
|
+
(item) => item.id === passId ? { ...item, holder } : item
|
|
332
|
+
);
|
|
333
|
+
return {
|
|
334
|
+
...data,
|
|
335
|
+
list: newList
|
|
336
|
+
};
|
|
337
|
+
});
|
|
338
|
+
} else {
|
|
339
|
+
console.log("pass not found", passId);
|
|
340
|
+
}
|
|
341
|
+
};
|
|
342
|
+
const _handleBindHolder = async (holderId) => {
|
|
343
|
+
setUpdateHolderLoading(true);
|
|
344
|
+
const { wallet_pass_detail_id: passId } = editHolderData;
|
|
345
|
+
try {
|
|
346
|
+
const res = await (0, import_serve.updateWalletPassHolder)(passId, {
|
|
347
|
+
holder_type: "form",
|
|
348
|
+
holder_id: holderId
|
|
349
|
+
});
|
|
350
|
+
setEditHolderData(null);
|
|
351
|
+
if (holderId) {
|
|
352
|
+
if (res) {
|
|
353
|
+
_handleHolderChange == null ? void 0 : _handleHolderChange(Number(passId), res);
|
|
354
|
+
}
|
|
355
|
+
} else {
|
|
356
|
+
_handleHolderChange == null ? void 0 : _handleHolderChange(Number(passId), null);
|
|
357
|
+
}
|
|
358
|
+
} catch (error) {
|
|
359
|
+
console.error("Error updating wallet pass holder:", error);
|
|
360
|
+
} finally {
|
|
361
|
+
setUpdateHolderLoading(false);
|
|
362
|
+
}
|
|
363
|
+
};
|
|
254
364
|
const _currentItem = (0, import_react.useMemo)(() => {
|
|
255
365
|
if (!currentItemId) return null;
|
|
256
366
|
const found1 = _avaliable.find(
|
|
@@ -281,7 +391,8 @@ var WalletPassGallery = (props) => {
|
|
|
281
391
|
hasMore: !_getAvailableList.noMore,
|
|
282
392
|
dataSource: _avaliable,
|
|
283
393
|
value: currentItemId,
|
|
284
|
-
onChange: _handleCardClick
|
|
394
|
+
onChange: _handleCardClick,
|
|
395
|
+
onEditHolder: setEditHolderData
|
|
285
396
|
}
|
|
286
397
|
);
|
|
287
398
|
}
|
|
@@ -293,7 +404,8 @@ var WalletPassGallery = (props) => {
|
|
|
293
404
|
hasMore: !_getAvailableList.noMore,
|
|
294
405
|
dataSource: _avaliable,
|
|
295
406
|
value: currentItemId,
|
|
296
|
-
onChange: _handleCardClick
|
|
407
|
+
onChange: _handleCardClick,
|
|
408
|
+
onEditHolder: setEditHolderData
|
|
297
409
|
}
|
|
298
410
|
)), /* @__PURE__ */ import_react.default.createElement(ACol, { flex: "auto" }, /* @__PURE__ */ import_react.default.createElement(import_passDetail.default, { dataSource: _currentItem, platform })));
|
|
299
411
|
};
|
|
@@ -307,7 +419,8 @@ var WalletPassGallery = (props) => {
|
|
|
307
419
|
loading: _getUnavailableList.loadingMore,
|
|
308
420
|
dataSource: _unavailable,
|
|
309
421
|
value: currentItemId,
|
|
310
|
-
onChange: _handleCardClick
|
|
422
|
+
onChange: _handleCardClick,
|
|
423
|
+
onEditHolder: setEditHolderData
|
|
311
424
|
}
|
|
312
425
|
);
|
|
313
426
|
}
|
|
@@ -319,7 +432,8 @@ var WalletPassGallery = (props) => {
|
|
|
319
432
|
loading: _getUnavailableList.loadingMore,
|
|
320
433
|
dataSource: _unavailable,
|
|
321
434
|
value: currentItemId,
|
|
322
|
-
onChange: _handleCardClick
|
|
435
|
+
onChange: _handleCardClick,
|
|
436
|
+
onEditHolder: setEditHolderData
|
|
323
437
|
}
|
|
324
438
|
)), /* @__PURE__ */ import_react.default.createElement(ACol, { flex: "auto" }, /* @__PURE__ */ import_react.default.createElement(import_passDetail.default, { dataSource: _currentItem, platform })));
|
|
325
439
|
};
|
|
@@ -497,6 +611,19 @@ var WalletPassGallery = (props) => {
|
|
|
497
611
|
onChangeType: _resetSearchState
|
|
498
612
|
}
|
|
499
613
|
), (_getUnbindList.data || []).map(renderSearchCard))
|
|
614
|
+
), !!editHolderData && /* @__PURE__ */ import_react.default.createElement(
|
|
615
|
+
import_tempHolderSelector.default,
|
|
616
|
+
{
|
|
617
|
+
visible: true,
|
|
618
|
+
onCancel: () => {
|
|
619
|
+
setEditHolderData(null);
|
|
620
|
+
},
|
|
621
|
+
onConfirm: _handleBindHolder,
|
|
622
|
+
confirmLoading: updateHolderLoading,
|
|
623
|
+
formId: editHolderData == null ? void 0 : editHolderData.form_id,
|
|
624
|
+
customerId: editHolderData == null ? void 0 : editHolderData.customer_id,
|
|
625
|
+
value: editHolderData == null ? void 0 : editHolderData.holder_id
|
|
626
|
+
}
|
|
500
627
|
));
|
|
501
628
|
};
|
|
502
629
|
var walletPassGallery_default = WalletPassGallery;
|
|
@@ -87,6 +87,11 @@ declare const _default: {
|
|
|
87
87
|
'wallet-pass-gallery.voucherExpireNote': string;
|
|
88
88
|
'wallet-pass-gallery.viewMore': string;
|
|
89
89
|
'wallet-pass-gallery.allLoaded': string;
|
|
90
|
+
'page.wallet.tempHolderSelector.title': string;
|
|
91
|
+
'page.wallet.tempHolderSelector.create': string;
|
|
92
|
+
'page.wallet.tempHolderSelector.confirm': string;
|
|
93
|
+
'page.wallet.notValidDate': string;
|
|
94
|
+
'page.wallet.includedDate': string;
|
|
90
95
|
};
|
|
91
96
|
'zh-CN': {
|
|
92
97
|
'wallet-pass-gallery.rechargeableCard': string;
|
|
@@ -176,6 +181,11 @@ declare const _default: {
|
|
|
176
181
|
'wallet-pass-gallery.voucherExpireNote': string;
|
|
177
182
|
'wallet-pass-gallery.viewMore': string;
|
|
178
183
|
'wallet-pass-gallery.allLoaded': string;
|
|
184
|
+
'page.wallet.tempHolderSelector.title': string;
|
|
185
|
+
'page.wallet.tempHolderSelector.create': string;
|
|
186
|
+
'page.wallet.tempHolderSelector.confirm': string;
|
|
187
|
+
'page.wallet.notValidDate': string;
|
|
188
|
+
'page.wallet.includedDate': string;
|
|
179
189
|
};
|
|
180
190
|
'zh-HK': {
|
|
181
191
|
'wallet-pass-gallery.rechargeableCard': string;
|
|
@@ -265,6 +275,11 @@ declare const _default: {
|
|
|
265
275
|
'wallet-pass-gallery.voucherExpireNote': string;
|
|
266
276
|
'wallet-pass-gallery.viewMore': string;
|
|
267
277
|
'wallet-pass-gallery.allLoaded': string;
|
|
278
|
+
'page.wallet.tempHolderSelector.title': string;
|
|
279
|
+
'page.wallet.tempHolderSelector.create': string;
|
|
280
|
+
'page.wallet.tempHolderSelector.confirm': string;
|
|
281
|
+
'page.wallet.notValidDate': string;
|
|
282
|
+
'page.wallet.includedDate': string;
|
|
268
283
|
};
|
|
269
284
|
};
|
|
270
285
|
export default _default;
|
|
@@ -116,7 +116,16 @@ var locales_default = {
|
|
|
116
116
|
"wallet-pass-gallery.monthlyReset": "Counter resets on 1st of each month at midnight",
|
|
117
117
|
"wallet-pass-gallery.voucherExpireNote": "Voucher will automatically expire when limit is reached",
|
|
118
118
|
"wallet-pass-gallery.viewMore": "View More",
|
|
119
|
-
"wallet-pass-gallery.allLoaded": "All loaded"
|
|
119
|
+
"wallet-pass-gallery.allLoaded": "All loaded",
|
|
120
|
+
// TempHolderSelector
|
|
121
|
+
"page.wallet.tempHolderSelector.title": "Edit Holder",
|
|
122
|
+
"page.wallet.tempHolderSelector.create": "Create New",
|
|
123
|
+
"page.wallet.tempHolderSelector.confirm": "Confirm",
|
|
124
|
+
// temp
|
|
125
|
+
"page.wallet.notValidDate": "Not valid on",
|
|
126
|
+
// 不可用日期
|
|
127
|
+
"page.wallet.includedDate": "Included dates"
|
|
128
|
+
// 包含日期
|
|
120
129
|
},
|
|
121
130
|
"zh-CN": {
|
|
122
131
|
"wallet-pass-gallery.rechargeableCard": "充值卡",
|
|
@@ -189,7 +198,7 @@ var locales_default = {
|
|
|
189
198
|
"wallet-pass-gallery.loading": "正在加载钱包...",
|
|
190
199
|
"wallet-pass-gallery.usageRules": "使用规则",
|
|
191
200
|
"wallet-pass-gallery.usageRulesSubtitle": "请仔细阅读以下使用条件",
|
|
192
|
-
"wallet-pass-gallery.timeUsageLimits": "
|
|
201
|
+
"wallet-pass-gallery.timeUsageLimits": "使用频次限制",
|
|
193
202
|
"wallet-pass-gallery.totalQuantityControl": "总量控制",
|
|
194
203
|
"wallet-pass-gallery.dailyLimit": "每日限制:",
|
|
195
204
|
"wallet-pass-gallery.weeklyLimit": "每周限制:",
|
|
@@ -205,7 +214,16 @@ var locales_default = {
|
|
|
205
214
|
"wallet-pass-gallery.monthlyReset": "每月1号0点自动重置计数",
|
|
206
215
|
"wallet-pass-gallery.voucherExpireNote": "用完后此券将自动失效",
|
|
207
216
|
"wallet-pass-gallery.viewMore": "查看更多",
|
|
208
|
-
"wallet-pass-gallery.allLoaded": "已全部加载"
|
|
217
|
+
"wallet-pass-gallery.allLoaded": "已全部加载",
|
|
218
|
+
// TempHolderSelector
|
|
219
|
+
"page.wallet.tempHolderSelector.title": "编辑持有人",
|
|
220
|
+
"page.wallet.tempHolderSelector.create": "创建新持有人",
|
|
221
|
+
"page.wallet.tempHolderSelector.confirm": "确定",
|
|
222
|
+
// temp
|
|
223
|
+
"page.wallet.notValidDate": "不可用日期",
|
|
224
|
+
// 不可用日期
|
|
225
|
+
"page.wallet.includedDate": "包含日期"
|
|
226
|
+
// 包含日期
|
|
209
227
|
},
|
|
210
228
|
"zh-HK": {
|
|
211
229
|
"wallet-pass-gallery.rechargeableCard": "充值卡",
|
|
@@ -278,7 +296,7 @@ var locales_default = {
|
|
|
278
296
|
"wallet-pass-gallery.loading": "正在加載錢包...",
|
|
279
297
|
"wallet-pass-gallery.usageRules": "使用規則",
|
|
280
298
|
"wallet-pass-gallery.usageRulesSubtitle": "請仔細閱讀以下使用條件",
|
|
281
|
-
"wallet-pass-gallery.timeUsageLimits": "
|
|
299
|
+
"wallet-pass-gallery.timeUsageLimits": "使用頻次限制",
|
|
282
300
|
"wallet-pass-gallery.totalQuantityControl": "總量控制",
|
|
283
301
|
"wallet-pass-gallery.dailyLimit": "每日限制:",
|
|
284
302
|
"wallet-pass-gallery.weeklyLimit": "每週限制:",
|
|
@@ -294,6 +312,15 @@ var locales_default = {
|
|
|
294
312
|
"wallet-pass-gallery.monthlyReset": "每月1號0點自動重置計數",
|
|
295
313
|
"wallet-pass-gallery.voucherExpireNote": "用完後此券將自動失效",
|
|
296
314
|
"wallet-pass-gallery.viewMore": "查看更多",
|
|
297
|
-
"wallet-pass-gallery.allLoaded": "已全部加載"
|
|
315
|
+
"wallet-pass-gallery.allLoaded": "已全部加載",
|
|
316
|
+
// TempHolderSelector
|
|
317
|
+
"page.wallet.tempHolderSelector.title": "編輯持有人",
|
|
318
|
+
"page.wallet.tempHolderSelector.create": "創建新持有人",
|
|
319
|
+
"page.wallet.tempHolderSelector.confirm": "確定",
|
|
320
|
+
// temp
|
|
321
|
+
"page.wallet.notValidDate": "不可用日期",
|
|
322
|
+
// 不可用日期
|
|
323
|
+
"page.wallet.includedDate": "包含日期"
|
|
324
|
+
// 包含日期
|
|
298
325
|
}
|
|
299
326
|
};
|
|
@@ -16,6 +16,7 @@ export interface IWalletListParmsProps {
|
|
|
16
16
|
num?: number;
|
|
17
17
|
skip?: number;
|
|
18
18
|
filter_wallet_id?: string;
|
|
19
|
+
filter_holder_id?: string;
|
|
19
20
|
available: 0 | 1;
|
|
20
21
|
with?: string[];
|
|
21
22
|
}
|
|
@@ -86,7 +87,7 @@ export declare type ErrorCallback = () => void;
|
|
|
86
87
|
* @returns Promise<{list: IWalletListItemProps[], count: number}> 钱包列表和总数
|
|
87
88
|
* @throws 请求失败时抛出错误
|
|
88
89
|
*/
|
|
89
|
-
export declare const
|
|
90
|
+
export declare const getWalletPassList: (params?: IWalletListParmsProps) => Promise<{
|
|
90
91
|
list: IWalletListItemProps[];
|
|
91
92
|
count: number;
|
|
92
93
|
}>;
|
|
@@ -218,4 +219,17 @@ export declare const orderRechargeProduct: (params: OrderParams) => Promise<Orde
|
|
|
218
219
|
* @date: 2025-11-03 15:30
|
|
219
220
|
*/
|
|
220
221
|
export declare const getWalletDetail: (id: string | number) => Promise<any>;
|
|
222
|
+
/**
|
|
223
|
+
* 更新卡券持有人
|
|
224
|
+
* @param id 卡券ID
|
|
225
|
+
* @param params 更新参数
|
|
226
|
+
* @returns 更新结果
|
|
227
|
+
*/
|
|
228
|
+
export declare const updateWalletPassHolder: (id: string, params: any) => Promise<any>;
|
|
229
|
+
/**
|
|
230
|
+
* 获取卡券详情
|
|
231
|
+
* @param id 卡券ID
|
|
232
|
+
* @returns 卡券详情
|
|
233
|
+
*/
|
|
234
|
+
export declare const getWalletPassDetail: (id: string, params: any) => Promise<any>;
|
|
221
235
|
export {};
|
|
@@ -24,15 +24,17 @@ __export(serve_exports, {
|
|
|
24
24
|
getDetailApi: () => getDetailApi,
|
|
25
25
|
getUnbindList: () => getUnbindList,
|
|
26
26
|
getWalletDetail: () => getWalletDetail,
|
|
27
|
-
|
|
27
|
+
getWalletPassDetail: () => getWalletPassDetail,
|
|
28
|
+
getWalletPassList: () => getWalletPassList,
|
|
28
29
|
goOrder: () => goOrder,
|
|
29
30
|
orderRechargeProduct: () => orderRechargeProduct,
|
|
30
|
-
setRequest: () => setRequest
|
|
31
|
+
setRequest: () => setRequest,
|
|
32
|
+
updateWalletPassHolder: () => updateWalletPassHolder
|
|
31
33
|
});
|
|
32
34
|
module.exports = __toCommonJS(serve_exports);
|
|
33
35
|
var import_utils = require("../../utils");
|
|
34
36
|
var import_utils2 = require("@pisell/utils");
|
|
35
|
-
var
|
|
37
|
+
var getWalletPassList = async (params) => {
|
|
36
38
|
try {
|
|
37
39
|
const { data } = await import_utils.request.getRequest().get(`/h5/machinecode/lowcode/list`, params);
|
|
38
40
|
return data || { list: [], count: 0 };
|
|
@@ -87,6 +89,14 @@ var orderRechargeProduct = async (params) => {
|
|
|
87
89
|
var getWalletDetail = async (id) => {
|
|
88
90
|
return import_utils.request.getRequest().get(`/h5/wallet/${id}`, {});
|
|
89
91
|
};
|
|
92
|
+
var updateWalletPassHolder = async (id, params) => {
|
|
93
|
+
const { data } = await import_utils.request.getRequest().post(`/h5/machinecode/${id}/bind-holder`, params);
|
|
94
|
+
return data;
|
|
95
|
+
};
|
|
96
|
+
var getWalletPassDetail = async (id, params) => {
|
|
97
|
+
const { data } = await import_utils.request.getRequest().get(`/h5/machinecode/lowcode/detail/${id}`, params);
|
|
98
|
+
return data;
|
|
99
|
+
};
|
|
90
100
|
// Annotate the CommonJS export names for ESM import in node:
|
|
91
101
|
0 && (module.exports = {
|
|
92
102
|
bindCodeToCustomer,
|
|
@@ -94,8 +104,10 @@ var getWalletDetail = async (id) => {
|
|
|
94
104
|
getDetailApi,
|
|
95
105
|
getUnbindList,
|
|
96
106
|
getWalletDetail,
|
|
97
|
-
|
|
107
|
+
getWalletPassDetail,
|
|
108
|
+
getWalletPassList,
|
|
98
109
|
goOrder,
|
|
99
110
|
orderRechargeProduct,
|
|
100
|
-
setRequest
|
|
111
|
+
setRequest,
|
|
112
|
+
updateWalletPassHolder
|
|
101
113
|
});
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
interface ScheduleTextResult {
|
|
2
|
+
validityTexts: string[];
|
|
3
|
+
excluded_date: string[];
|
|
4
|
+
included_date: string[];
|
|
5
|
+
}
|
|
6
|
+
declare type Locale = 'en' | 'zh-CN' | 'zh-HK';
|
|
7
|
+
interface ScheduleItem {
|
|
8
|
+
id: number;
|
|
9
|
+
name: string | {
|
|
10
|
+
[key: string]: string;
|
|
11
|
+
};
|
|
12
|
+
type: 'standard' | 'time-slots' | 'designation';
|
|
13
|
+
start_time: string | null;
|
|
14
|
+
end_time: string | null;
|
|
15
|
+
repeat_type: 'none' | 'daily' | 'weekly';
|
|
16
|
+
repeat_rule: {
|
|
17
|
+
end: {
|
|
18
|
+
type: 'never' | 'date' | 'occurrence';
|
|
19
|
+
end_date: string | null;
|
|
20
|
+
occurrence: number | null;
|
|
21
|
+
};
|
|
22
|
+
frequency: number;
|
|
23
|
+
excluded_date: Array<{
|
|
24
|
+
start: string;
|
|
25
|
+
end: string;
|
|
26
|
+
}>;
|
|
27
|
+
included_date: any[];
|
|
28
|
+
frequency_date: number[];
|
|
29
|
+
} | null;
|
|
30
|
+
designation: Array<{
|
|
31
|
+
start_date: string;
|
|
32
|
+
start_time: string;
|
|
33
|
+
end_date: string;
|
|
34
|
+
end_time: string;
|
|
35
|
+
}> | null;
|
|
36
|
+
is_all: number;
|
|
37
|
+
time_slot: Array<{
|
|
38
|
+
start_time: string;
|
|
39
|
+
end_time: string;
|
|
40
|
+
}>;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* 根据scheduleList格式化文案展示
|
|
44
|
+
* @param scheduleList 日程列表
|
|
45
|
+
* @returns 格式化后的文案结果数组,每个日程对应一个结果
|
|
46
|
+
*/
|
|
47
|
+
export declare function formatScheduleText(scheduleList: ScheduleItem[], locale?: Locale): ScheduleTextResult[];
|
|
48
|
+
export {};
|