@pisell/private-materials 3.3.26 → 3.3.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +8 -8
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +7 -7
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +5 -5
- package/es/components/Sales/Customer/index.js +3 -1
- package/es/components/Sales/Event/Detail.js +5 -1
- package/es/components/Sales/Event/serve.d.ts +3 -0
- package/es/components/Sales/Init/index.d.ts +1 -0
- package/es/components/Sales/Init/index.js +3 -2
- package/es/components/Sales/Step/index.d.ts +2 -0
- package/es/components/Sales/Step/index.js +13 -4
- package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/ConfirmInformation/index.js +5 -5
- package/es/components/appointmentBooking/components/Content/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Services/index.js +2 -0
- package/es/components/appointmentBooking/deposit/index.js +2 -2
- package/es/components/appointmentBooking/index.d.ts +1 -0
- package/es/components/booking/components/footer/utils.js +16 -15
- package/es/components/booking/hooks/useQuotation.d.ts +4 -0
- package/es/components/booking/hooks/useQuotation.js +256 -0
- package/es/components/booking/info/index.d.ts +0 -1
- package/es/components/booking/info/service/addService/index.d.ts +1 -0
- package/es/components/booking/info/service/addService/index.js +4 -4
- package/es/components/booking/info/service/editService/index.js +6 -3
- package/es/components/booking/info/service/index.js +4 -1
- package/es/components/booking/info/service2/Group/utils.js +1 -1
- package/es/components/booking/info/service2/hooks/useSelectPet.js +6 -4
- package/es/components/booking/info/service2/index.js +4 -1
- package/es/components/booking/info2/service/addService/index.d.ts +1 -0
- package/es/components/booking/info2/service/addService/index.js +29 -9
- package/es/components/booking/info2/service/editService/index.js +2 -0
- package/es/components/booking/info2/service/index.js +4 -1
- package/es/components/booking/locales.d.ts +6 -0
- package/es/components/booking/locales.js +9 -3
- package/es/components/eftposPay/component/fail/failCustom.d.ts +1 -0
- package/es/components/eftposPay/component/fail/index.d.ts +1 -0
- package/es/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/es/components/eftposPay/hooks.d.ts +1 -1
- package/es/components/eftposPay/index.d.ts +1 -0
- package/es/components/eftposPay/pay.d.ts +1 -0
- package/es/components/eftposPay/store/index.d.ts +1 -1
- package/es/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +122 -31
- package/es/components/eventBooking/components/Provider/Event/index.js +20 -4
- package/es/components/eventBooking/components/Provider/Resource/index.js +26 -5
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.d.ts +2 -2
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.js +1 -1
- package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
- package/es/components/eventBooking/components/bookingDetailModal/components/Schedule.js +5 -2
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.js +7 -2
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.d.ts +3 -0
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.js +60 -0
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.less +63 -0
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimes/index.d.ts +9 -0
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimes/index.js +59 -0
- package/es/components/eventBooking/components/scheduleCalendar/components/ScheduleTimes/index.less +7 -0
- package/es/components/eventBooking/components/scheduleCalendar/index.d.ts +1 -0
- package/es/components/eventBooking/components/scheduleCalendar/index.js +30 -21
- package/es/components/eventBooking/components/scheduleCalendar/index.less +2 -0
- package/es/components/eventBooking/index.d.ts +1 -0
- package/es/components/eventBooking/index.js +2 -2
- package/es/components/eventBooking/locales.d.ts +6 -0
- package/es/components/eventBooking/locales.js +166 -160
- package/es/components/pay/toC/PaymentMethods/WalletPass/List/index.d.ts +3 -0
- package/es/components/pay/toC/PaymentMethods/WalletPass/List/index.js +3 -2
- package/es/components/pay/toC/PaymentMethods/WalletPass/index.d.ts +5 -0
- package/es/components/pay/toC/PaymentMethods/WalletPass/index.js +73 -20
- package/es/components/pay/toC/PaymentMethods/WalletPass/index.less +30 -0
- package/es/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +2 -0
- package/es/components/pay/toC/PaymentMethods/WalletPass/utils.js +2 -1
- package/es/components/pay/toC/WalletPassBlock/components/WalletAvailable/index.d.ts +16 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletAvailable/index.js +60 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletAvailable/index.less +38 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletBestValueFound/index.d.ts +17 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletBestValueFound/index.js +98 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletBestValueFound/index.less +133 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +7 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.js +34 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.less +23 -0
- package/es/components/pay/toC/WalletPassBlock/index.d.ts +9 -2
- package/es/components/pay/toC/WalletPassBlock/index.js +119 -21
- package/es/components/pay/toC/WalletPassBlock/index.less +82 -13
- package/es/components/pay/toC/index.js +138 -89
- package/es/components/pay/toC/locales.d.ts +69 -3
- package/es/components/pay/toC/locales.js +132 -6
- package/es/components/pay/toC/model.d.ts +4 -0
- package/es/components/pay/toC/model.js +9 -0
- package/es/components/pay/toC/serve.d.ts +23 -0
- package/es/components/pay/toC/serve.js +34 -2
- package/es/components/pay/toC/utils.d.ts +3 -1
- package/es/components/pay/toC/utils.js +8 -3
- package/es/components/productSelect/components/productGroup/index.less +4 -12
- package/es/components/productSelect/index.less +1 -1
- package/es/components/ruleSetting/index.d.ts +1 -0
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +15 -20
- package/es/components/ticketBooking/components/menuBar/index.less +0 -1
- package/es/components/ticketBooking/components/ticketBooking/index.less +2 -4
- package/es/hooks/useLocale.d.ts +2 -0
- package/es/hooks/useLocale.js +7 -0
- package/es/hooks/useLoginUser.d.ts +2 -0
- package/es/hooks/useLoginUser.js +19 -0
- package/lib/components/Sales/Customer/index.js +3 -1
- package/lib/components/Sales/Event/Detail.js +5 -1
- package/lib/components/Sales/Event/serve.d.ts +3 -0
- package/lib/components/Sales/Init/index.d.ts +1 -0
- package/lib/components/Sales/Init/index.js +3 -2
- package/lib/components/Sales/Step/index.d.ts +2 -0
- package/lib/components/Sales/Step/index.js +13 -4
- package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/ConfirmInformation/index.js +2 -2
- package/lib/components/appointmentBooking/components/Content/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Services/index.js +2 -0
- package/lib/components/appointmentBooking/deposit/index.js +2 -2
- package/lib/components/appointmentBooking/index.d.ts +1 -0
- package/lib/components/booking/components/footer/utils.js +5 -4
- package/lib/components/booking/hooks/useQuotation.d.ts +4 -0
- package/lib/components/booking/hooks/useQuotation.js +210 -0
- package/lib/components/booking/info/index.d.ts +0 -1
- package/lib/components/booking/info/service/addService/index.d.ts +1 -0
- package/lib/components/booking/info/service/addService/index.js +2 -3
- package/lib/components/booking/info/service/editService/index.js +5 -2
- package/lib/components/booking/info/service/index.js +3 -1
- package/lib/components/booking/info/service2/Group/utils.js +2 -2
- package/lib/components/booking/info/service2/hooks/useSelectPet.js +5 -3
- package/lib/components/booking/info/service2/index.js +3 -1
- package/lib/components/booking/info2/service/addService/index.d.ts +1 -0
- package/lib/components/booking/info2/service/addService/index.js +25 -17
- package/lib/components/booking/info2/service/editService/index.js +2 -1
- package/lib/components/booking/info2/service/index.js +3 -1
- package/lib/components/booking/locales.d.ts +6 -0
- package/lib/components/booking/locales.js +9 -3
- package/lib/components/eftposPay/component/fail/failCustom.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/index.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/lib/components/eftposPay/hooks.d.ts +1 -1
- package/lib/components/eftposPay/index.d.ts +1 -0
- package/lib/components/eftposPay/pay.d.ts +1 -0
- package/lib/components/eftposPay/store/index.d.ts +1 -1
- package/lib/components/eventBooking/components/Provider/Cart/ContinueButton/index.js +52 -4
- package/lib/components/eventBooking/components/Provider/Event/index.js +15 -3
- package/lib/components/eventBooking/components/Provider/Resource/index.js +16 -3
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.d.ts +2 -2
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/SelectDate/index.js +7 -7
- package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingDetailModal/components/Schedule.js +3 -1
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.js +6 -5
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.d.ts +3 -0
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.js +75 -0
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimeItem/index.less +63 -0
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimes/index.d.ts +9 -0
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimes/index.js +64 -0
- package/lib/components/eventBooking/components/scheduleCalendar/components/ScheduleTimes/index.less +7 -0
- package/lib/components/eventBooking/components/scheduleCalendar/index.d.ts +1 -0
- package/lib/components/eventBooking/components/scheduleCalendar/index.js +17 -11
- package/lib/components/eventBooking/components/scheduleCalendar/index.less +2 -0
- package/lib/components/eventBooking/index.d.ts +1 -0
- package/lib/components/eventBooking/index.js +2 -2
- package/lib/components/eventBooking/locales.d.ts +6 -0
- package/lib/components/eventBooking/locales.js +10 -4
- package/lib/components/pay/toC/PaymentMethods/WalletPass/List/index.d.ts +3 -0
- package/lib/components/pay/toC/PaymentMethods/WalletPass/List/index.js +2 -2
- package/lib/components/pay/toC/PaymentMethods/WalletPass/index.d.ts +5 -0
- package/lib/components/pay/toC/PaymentMethods/WalletPass/index.js +52 -11
- package/lib/components/pay/toC/PaymentMethods/WalletPass/index.less +30 -0
- package/lib/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +2 -0
- package/lib/components/pay/toC/PaymentMethods/WalletPass/utils.js +2 -1
- package/lib/components/pay/toC/WalletPassBlock/components/WalletAvailable/index.d.ts +16 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletAvailable/index.js +87 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletAvailable/index.less +38 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletBestValueFound/index.d.ts +17 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletBestValueFound/index.js +103 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletBestValueFound/index.less +133 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +7 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.js +52 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.less +23 -0
- package/lib/components/pay/toC/WalletPassBlock/index.d.ts +9 -2
- package/lib/components/pay/toC/WalletPassBlock/index.js +115 -20
- package/lib/components/pay/toC/WalletPassBlock/index.less +82 -13
- package/lib/components/pay/toC/index.js +35 -9
- package/lib/components/pay/toC/locales.d.ts +69 -3
- package/lib/components/pay/toC/locales.js +72 -6
- package/lib/components/pay/toC/model.d.ts +4 -0
- package/lib/components/pay/toC/model.js +10 -0
- package/lib/components/pay/toC/serve.d.ts +23 -0
- package/lib/components/pay/toC/serve.js +12 -6
- package/lib/components/pay/toC/utils.d.ts +3 -1
- package/lib/components/pay/toC/utils.js +8 -3
- package/lib/components/productSelect/components/productGroup/index.less +4 -12
- package/lib/components/productSelect/index.less +1 -1
- package/lib/components/ruleSetting/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/addServiceVariant/addService.js +13 -16
- package/lib/components/ticketBooking/components/menuBar/index.less +0 -1
- package/lib/components/ticketBooking/components/ticketBooking/index.less +2 -4
- package/lib/hooks/useLocale.d.ts +2 -0
- package/lib/hooks/useLocale.js +41 -0
- package/lib/hooks/useLoginUser.d.ts +2 -0
- package/lib/hooks/useLoginUser.js +50 -0
- package/package.json +3 -3
|
@@ -32,6 +32,10 @@ var defaultState = {
|
|
|
32
32
|
payCallback: () => {
|
|
33
33
|
},
|
|
34
34
|
history: null,
|
|
35
|
+
walletSetting: {
|
|
36
|
+
name: "",
|
|
37
|
+
popup_status: null
|
|
38
|
+
},
|
|
35
39
|
payGroup: {
|
|
36
40
|
wait_amount: 0
|
|
37
41
|
}
|
|
@@ -48,6 +52,12 @@ var { Provider, Context } = (0, import_utils.miniRedux)({
|
|
|
48
52
|
(0, import_payGroup.syncPayGroupToStorage)(res);
|
|
49
53
|
return { ...state, payGroup: res };
|
|
50
54
|
},
|
|
55
|
+
setWalletSetting(state, payload) {
|
|
56
|
+
return { ...state, walletSetting: {
|
|
57
|
+
...state.walletSetting,
|
|
58
|
+
...payload
|
|
59
|
+
} };
|
|
60
|
+
},
|
|
51
61
|
init(state, payload) {
|
|
52
62
|
return { ...defaultState, ...payload };
|
|
53
63
|
}
|
|
@@ -32,3 +32,26 @@ export declare const getPaymentInit: (values: {
|
|
|
32
32
|
order_id?: string;
|
|
33
33
|
amount?: number;
|
|
34
34
|
}) => Promise<any>;
|
|
35
|
+
/**
|
|
36
|
+
* @title: 获取钱包名称和弹窗状态
|
|
37
|
+
* @description:
|
|
38
|
+
* @param {object} values
|
|
39
|
+
* @return {*}
|
|
40
|
+
* @Author: shengjie.zuo
|
|
41
|
+
* @member: 马天宇
|
|
42
|
+
* @Date: 2025-02-21 10:42
|
|
43
|
+
*/
|
|
44
|
+
export declare const getWalletNameAndPopupStatus: (values: {
|
|
45
|
+
setting_type?: string;
|
|
46
|
+
}) => Promise<{
|
|
47
|
+
wallet: {
|
|
48
|
+
name?: {
|
|
49
|
+
en: string;
|
|
50
|
+
'zh-CN': string;
|
|
51
|
+
'zh-HK': string;
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
wallet_setting: {
|
|
55
|
+
popup_status?: 1 | 0;
|
|
56
|
+
};
|
|
57
|
+
}>;
|
|
@@ -21,7 +21,8 @@ var serve_exports = {};
|
|
|
21
21
|
__export(serve_exports, {
|
|
22
22
|
getPaymentInit: () => getPaymentInit,
|
|
23
23
|
getPaymentList: () => getPaymentList,
|
|
24
|
-
getPaymentsAndWalletPass: () => getPaymentsAndWalletPass
|
|
24
|
+
getPaymentsAndWalletPass: () => getPaymentsAndWalletPass,
|
|
25
|
+
getWalletNameAndPopupStatus: () => getWalletNameAndPopupStatus
|
|
25
26
|
});
|
|
26
27
|
module.exports = __toCommonJS(serve_exports);
|
|
27
28
|
var import_utils = require("../../../utils");
|
|
@@ -35,9 +36,7 @@ var getPaymentList = async (values) => {
|
|
|
35
36
|
);
|
|
36
37
|
let arr = [];
|
|
37
38
|
if ((0, import_utils2.isWx)()) {
|
|
38
|
-
arr = arr.concat([
|
|
39
|
-
"mw.google"
|
|
40
|
-
]);
|
|
39
|
+
arr = arr.concat(["mw.google"]);
|
|
41
40
|
}
|
|
42
41
|
if (!(0, import_utils2.isWx)()) {
|
|
43
42
|
arr = arr.concat(["globepay.wechat.jsapi", "superpay.wechat.h5"]);
|
|
@@ -60,7 +59,9 @@ var getPaymentList = async (values) => {
|
|
|
60
59
|
};
|
|
61
60
|
var getPaymentsAndWalletPass = async (values) => {
|
|
62
61
|
let { data } = await import_utils.request.getRequest().get("/h5/pay/order/payments-and-walletpass", values);
|
|
63
|
-
const walletPass = (data.payment_list || []).find(
|
|
62
|
+
const walletPass = (data.payment_list || []).find(
|
|
63
|
+
(d) => d.service === "pisell.wallet_pass"
|
|
64
|
+
);
|
|
64
65
|
return {
|
|
65
66
|
...data,
|
|
66
67
|
walletPass
|
|
@@ -70,9 +71,14 @@ var getPaymentInit = async (values) => {
|
|
|
70
71
|
let { data } = await import_utils.request.getRequest().post("/h5/pay/payment/init", values);
|
|
71
72
|
return data;
|
|
72
73
|
};
|
|
74
|
+
var getWalletNameAndPopupStatus = async (values) => {
|
|
75
|
+
const { data } = await import_utils.request.getRequest().get("/h5/wallet/setting", values);
|
|
76
|
+
return data;
|
|
77
|
+
};
|
|
73
78
|
// Annotate the CommonJS export names for ESM import in node:
|
|
74
79
|
0 && (module.exports = {
|
|
75
80
|
getPaymentInit,
|
|
76
81
|
getPaymentList,
|
|
77
|
-
getPaymentsAndWalletPass
|
|
82
|
+
getPaymentsAndWalletPass,
|
|
83
|
+
getWalletNameAndPopupStatus
|
|
78
84
|
});
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { PayGroup } from "./model";
|
|
2
|
+
import { WalletPassDataType } from "./PaymentMethods/WalletPass/serve";
|
|
2
3
|
/**
|
|
3
4
|
* 计算walletPass列表数据的总金额
|
|
4
5
|
* @param list
|
|
@@ -21,7 +22,7 @@ export declare const formatWalletPassParams: (payGroup: PayGroup) => {
|
|
|
21
22
|
order_id: string;
|
|
22
23
|
payment_group_id: number;
|
|
23
24
|
payments: {
|
|
24
|
-
amount:
|
|
25
|
+
amount: string;
|
|
25
26
|
wallet_pass_use_value: any;
|
|
26
27
|
voucher_id: any;
|
|
27
28
|
tag: any;
|
|
@@ -47,3 +48,4 @@ export declare const isFranchiseeShop: (path?: any, history?: any) => any;
|
|
|
47
48
|
*/
|
|
48
49
|
export declare const getFranchiseeShopId: (path?: any, history?: any) => number;
|
|
49
50
|
export declare const formatFranchiseeRoute: (url: string, history?: any) => string;
|
|
51
|
+
export declare const getAvailableMaxAmount: (data: WalletPassDataType) => string;
|
|
@@ -23,6 +23,7 @@ __export(utils_exports, {
|
|
|
23
23
|
formatFranchiseeRoute: () => formatFranchiseeRoute,
|
|
24
24
|
formatWalletPassList2PreparePayments: () => formatWalletPassList2PreparePayments,
|
|
25
25
|
formatWalletPassParams: () => formatWalletPassParams,
|
|
26
|
+
getAvailableMaxAmount: () => getAvailableMaxAmount,
|
|
26
27
|
getFranchiseeShopId: () => getFranchiseeShopId,
|
|
27
28
|
getIsWalletPassAndTripartitePayment: () => getIsWalletPassAndTripartitePayment,
|
|
28
29
|
isFranchiseeShop: () => isFranchiseeShop
|
|
@@ -31,13 +32,13 @@ module.exports = __toCommonJS(utils_exports);
|
|
|
31
32
|
var import_decimal = require("decimal.js");
|
|
32
33
|
var import_status = require("./status");
|
|
33
34
|
var calcWalletPassListAmount = (list) => {
|
|
34
|
-
return list.reduce((pre, cur) => pre.add(new import_decimal.Decimal(String(cur
|
|
35
|
+
return list.reduce((pre, cur) => pre.add(new import_decimal.Decimal(String(getAvailableMaxAmount(cur) || 0))), new import_decimal.Decimal("0")).toNumber();
|
|
35
36
|
};
|
|
36
37
|
var formatWalletPassList2PreparePayments = (list) => {
|
|
37
38
|
return (list || []).map((item) => {
|
|
38
39
|
return {
|
|
39
40
|
voucher_id: item.id || 0,
|
|
40
|
-
amount: Number(item
|
|
41
|
+
amount: Number(getAvailableMaxAmount(item)) || 0,
|
|
41
42
|
tag: item.tag || ""
|
|
42
43
|
};
|
|
43
44
|
});
|
|
@@ -46,7 +47,7 @@ var formatWalletPassParams = (payGroup) => {
|
|
|
46
47
|
const { order_id, payment_group_id, walletPass } = payGroup;
|
|
47
48
|
const payments = (walletPass == null ? void 0 : walletPass.cards.map((item) => {
|
|
48
49
|
return {
|
|
49
|
-
amount: item
|
|
50
|
+
amount: getAvailableMaxAmount(item),
|
|
50
51
|
wallet_pass_use_value: item.available_max_par_value,
|
|
51
52
|
voucher_id: item.id,
|
|
52
53
|
tag: item.tag,
|
|
@@ -81,12 +82,16 @@ var formatFranchiseeRoute = (url, history) => {
|
|
|
81
82
|
}
|
|
82
83
|
return url;
|
|
83
84
|
};
|
|
85
|
+
var getAvailableMaxAmount = (data) => {
|
|
86
|
+
return data.tag !== "point_card" ? data.available_max_amount : data == null ? void 0 : data.recommended_usage_amount;
|
|
87
|
+
};
|
|
84
88
|
// Annotate the CommonJS export names for ESM import in node:
|
|
85
89
|
0 && (module.exports = {
|
|
86
90
|
calcWalletPassListAmount,
|
|
87
91
|
formatFranchiseeRoute,
|
|
88
92
|
formatWalletPassList2PreparePayments,
|
|
89
93
|
formatWalletPassParams,
|
|
94
|
+
getAvailableMaxAmount,
|
|
90
95
|
getFranchiseeShopId,
|
|
91
96
|
getIsWalletPassAndTripartitePayment,
|
|
92
97
|
isFranchiseeShop
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
.pisell-product-select-group {
|
|
2
2
|
.group-title {
|
|
3
3
|
color: var(--ps-category-text-color, #000);
|
|
4
|
-
font-family: Inter;
|
|
5
4
|
font-size: 18px;
|
|
6
5
|
font-style: normal;
|
|
7
6
|
font-weight: 600;
|
|
@@ -84,7 +83,6 @@
|
|
|
84
83
|
background: var(--Error-100, #fee4e2);
|
|
85
84
|
color: var(--Error-700, #b42318);
|
|
86
85
|
text-align: center;
|
|
87
|
-
font-family: Inter;
|
|
88
86
|
font-size: 14px;
|
|
89
87
|
font-style: normal;
|
|
90
88
|
font-weight: 500;
|
|
@@ -114,8 +112,7 @@
|
|
|
114
112
|
row-gap: 8px;
|
|
115
113
|
min-height: 92px;
|
|
116
114
|
.title {
|
|
117
|
-
color: var(--ps-card-text, #
|
|
118
|
-
font-family: Inter;
|
|
115
|
+
color: var(--ps-card-text, #1b1b1b);
|
|
119
116
|
font-size: 18px;
|
|
120
117
|
font-style: normal;
|
|
121
118
|
font-weight: 600;
|
|
@@ -130,9 +127,8 @@
|
|
|
130
127
|
.stock,
|
|
131
128
|
.specs {
|
|
132
129
|
overflow: hidden;
|
|
133
|
-
color: var(--ps-color-text-secondary, #
|
|
130
|
+
color: var(--ps-color-text-secondary, #4e4e4e);
|
|
134
131
|
text-overflow: ellipsis;
|
|
135
|
-
font-family: Inter;
|
|
136
132
|
font-size: 14px;
|
|
137
133
|
font-style: normal;
|
|
138
134
|
font-weight: 500;
|
|
@@ -161,7 +157,6 @@
|
|
|
161
157
|
mix-blend-mode: multiply;
|
|
162
158
|
color: var(--Error-700, #b42318);
|
|
163
159
|
text-align: center;
|
|
164
|
-
font-family: Inter;
|
|
165
160
|
font-size: 14px;
|
|
166
161
|
font-style: normal;
|
|
167
162
|
font-weight: 500;
|
|
@@ -174,16 +169,14 @@
|
|
|
174
169
|
gap: 8px;
|
|
175
170
|
}
|
|
176
171
|
.price {
|
|
177
|
-
color: var(--ps-card-text, #
|
|
178
|
-
font-family: Inter;
|
|
172
|
+
color: var(--ps-card-text, #1b1b1b);
|
|
179
173
|
font-size: 18px;
|
|
180
174
|
font-style: normal;
|
|
181
175
|
font-weight: 600;
|
|
182
176
|
line-height: 28px;
|
|
183
177
|
}
|
|
184
178
|
.original-price {
|
|
185
|
-
color: var(--ps-color-text-secondary, #
|
|
186
|
-
font-family: Inter;
|
|
179
|
+
color: var(--ps-color-text-secondary, #4e4e4e);
|
|
187
180
|
font-size: 16px;
|
|
188
181
|
font-style: normal;
|
|
189
182
|
font-weight: 400;
|
|
@@ -197,7 +190,6 @@
|
|
|
197
190
|
|
|
198
191
|
.remark {
|
|
199
192
|
color: var(--Warning-600, #dc6803);
|
|
200
|
-
font-family: Inter;
|
|
201
193
|
font-size: 14px;
|
|
202
194
|
font-style: normal;
|
|
203
195
|
font-weight: 600;
|
|
@@ -47,7 +47,7 @@ var import_serviceManager = require("../../../booking/info/service/serviceManage
|
|
|
47
47
|
var import_productSelect = __toESM(require("../../../productSelect"));
|
|
48
48
|
var import_index = require("./index.less");
|
|
49
49
|
var AddSerivce = (props) => {
|
|
50
|
-
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
50
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
51
51
|
const { onEdit, state, dispatch, renderMode = "current" } = props;
|
|
52
52
|
const [loading, setLoading] = (0, import_react.useState)(false);
|
|
53
53
|
const context = (0, import_useEngineContext.default)();
|
|
@@ -63,6 +63,10 @@ var AddSerivce = (props) => {
|
|
|
63
63
|
state == null ? void 0 : state.renderType
|
|
64
64
|
);
|
|
65
65
|
const [currentProduct, setCurrentProduct] = (0, import_react.useState)(null);
|
|
66
|
+
const customerId = (0, import_react.useMemo)(() => {
|
|
67
|
+
var _a2, _b2;
|
|
68
|
+
return ((_b2 = (_a2 = state.client) == null ? void 0 : _a2.value) == null ? void 0 : _b2.id) || void 0;
|
|
69
|
+
}, [(_g = (_f = state.client) == null ? void 0 : _f.value) == null ? void 0 : _g.id]);
|
|
66
70
|
const setDefaultService = async (list) => {
|
|
67
71
|
if (state.renderType !== "eventBooking") {
|
|
68
72
|
return;
|
|
@@ -134,11 +138,8 @@ var AddSerivce = (props) => {
|
|
|
134
138
|
with_count: ["bundleGroup", "optionGroup"],
|
|
135
139
|
order_by_string: "sort:desc",
|
|
136
140
|
status: "published",
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
useCache: true
|
|
140
|
-
}
|
|
141
|
-
}
|
|
141
|
+
schedule_date: params == null ? void 0 : params.schedule_date,
|
|
142
|
+
customer_id: params == null ? void 0 : params.customer_id
|
|
142
143
|
});
|
|
143
144
|
setLoading(false);
|
|
144
145
|
if (!state.service.addModal) {
|
|
@@ -173,6 +174,7 @@ var AddSerivce = (props) => {
|
|
|
173
174
|
package: true
|
|
174
175
|
},
|
|
175
176
|
is_eject: isEject ? 1 : 0,
|
|
177
|
+
customer_id: customerId,
|
|
176
178
|
isOS: isSession
|
|
177
179
|
},
|
|
178
180
|
onCancel: () => {
|
|
@@ -269,20 +271,15 @@ var AddSerivce = (props) => {
|
|
|
269
271
|
}
|
|
270
272
|
}
|
|
271
273
|
return _list;
|
|
272
|
-
}, [(
|
|
274
|
+
}, [(_h = state.service) == null ? void 0 : _h.services, state == null ? void 0 : state.activeCartId]);
|
|
273
275
|
const currentDate = (0, import_react.useMemo)(() => {
|
|
274
276
|
return state.date.value.format("YYYY-MM-DD");
|
|
275
277
|
}, [state.date.value]);
|
|
276
278
|
(0, import_react.useEffect)(() => {
|
|
277
279
|
if (renderMode === "current") {
|
|
278
|
-
getServices({ schedule_date: currentDate });
|
|
279
|
-
}
|
|
280
|
-
}, [renderMode, currentDate]);
|
|
281
|
-
(0, import_react.useEffect)(() => {
|
|
282
|
-
if (state.renderType === "eventBooking" && state.modalOpen) {
|
|
283
|
-
getServices({ schedule_date: currentDate });
|
|
280
|
+
getServices({ schedule_date: currentDate, customer_id: customerId });
|
|
284
281
|
}
|
|
285
|
-
}, [
|
|
282
|
+
}, [renderMode, currentDate, customerId]);
|
|
286
283
|
return (0, import_react.useMemo)(() => {
|
|
287
284
|
if (renderMode === "current") {
|
|
288
285
|
return /* @__PURE__ */ import_react.default.createElement(
|
|
@@ -295,13 +292,13 @@ var AddSerivce = (props) => {
|
|
|
295
292
|
},
|
|
296
293
|
onChange: handleSelectProduct,
|
|
297
294
|
value: currentProduct == null ? void 0 : currentProduct.id,
|
|
298
|
-
loading
|
|
295
|
+
loading: !renderList.length && loading
|
|
299
296
|
}
|
|
300
297
|
);
|
|
301
298
|
}
|
|
302
299
|
return null;
|
|
303
300
|
}, [
|
|
304
|
-
(
|
|
301
|
+
(_j = (_i = state.service) == null ? void 0 : _i.cacheItem) == null ? void 0 : _j.autoClose,
|
|
305
302
|
state.service.addModal,
|
|
306
303
|
import_utils.locales,
|
|
307
304
|
renderList,
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
.pisell-ticket-booking-wrapper {
|
|
2
|
-
|
|
3
|
-
|
|
4
2
|
.pisell-lowcode__booking-tab-pane-footer {
|
|
5
3
|
padding: 16px;
|
|
6
4
|
}
|
|
7
5
|
.create-booking-page-info-wrap-create {
|
|
8
|
-
background-color: #
|
|
6
|
+
background-color: #1b1b1b;
|
|
9
7
|
.booking-info {
|
|
10
8
|
.booking-info-create-new,
|
|
11
9
|
.pisell-lowcode__booking-field-title,
|
|
@@ -15,4 +13,4 @@
|
|
|
15
13
|
}
|
|
16
14
|
}
|
|
17
15
|
}
|
|
18
|
-
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
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/hooks/useLocale.ts
|
|
30
|
+
var useLocale_exports = {};
|
|
31
|
+
__export(useLocale_exports, {
|
|
32
|
+
default: () => useLocale_default
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(useLocale_exports);
|
|
35
|
+
var import_useEngineContext = __toESM(require("./useEngineContext"));
|
|
36
|
+
var useLocale = () => {
|
|
37
|
+
var _a, _b;
|
|
38
|
+
const context = (0, import_useEngineContext.default)();
|
|
39
|
+
return ((_b = (_a = context == null ? void 0 : context.engine) == null ? void 0 : _a.props) == null ? void 0 : _b.locale) || "en";
|
|
40
|
+
};
|
|
41
|
+
var useLocale_default = useLocale;
|
|
@@ -0,0 +1,50 @@
|
|
|
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/hooks/useLoginUser.ts
|
|
30
|
+
var useLoginUser_exports = {};
|
|
31
|
+
__export(useLoginUser_exports, {
|
|
32
|
+
default: () => useLoginUser_default
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(useLoginUser_exports);
|
|
35
|
+
var import_react = require("react");
|
|
36
|
+
var import_useEngineContext = __toESM(require("./useEngineContext"));
|
|
37
|
+
var useLoginUser = () => {
|
|
38
|
+
const context = (0, import_useEngineContext.default)();
|
|
39
|
+
const { store, storage, getStore } = context.appHelper.utils || {};
|
|
40
|
+
const user = (0, import_react.useMemo)(() => {
|
|
41
|
+
var _a, _b, _c;
|
|
42
|
+
const _store = getStore();
|
|
43
|
+
let userInfo = (_c = (_b = (_a = _store.getState) == null ? void 0 : _a.call(_store)) == null ? void 0 : _b.global) == null ? void 0 : _c.userInfo;
|
|
44
|
+
const localUserInfo = JSON.parse((storage == null ? void 0 : storage.get("customer")) || "{}");
|
|
45
|
+
userInfo = (userInfo == null ? void 0 : userInfo.id) ? userInfo : localUserInfo;
|
|
46
|
+
return userInfo;
|
|
47
|
+
}, [store]);
|
|
48
|
+
return user;
|
|
49
|
+
};
|
|
50
|
+
var useLoginUser_default = useLoginUser;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/private-materials",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.27",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -59,9 +59,9 @@
|
|
|
59
59
|
"react-infinite-scroll-component": "^6.1.0",
|
|
60
60
|
"rc-virtual-list": "^3.11.3",
|
|
61
61
|
"decimal.js": "^10.4.3",
|
|
62
|
-
"@pisell/materials": "3.3.
|
|
63
|
-
"@pisell/icon": "0.0.11",
|
|
62
|
+
"@pisell/materials": "3.3.8",
|
|
64
63
|
"@pisell/utils": "1.0.42",
|
|
64
|
+
"@pisell/icon": "0.0.11",
|
|
65
65
|
"@pisell/date-picker": "3.0.2"
|
|
66
66
|
},
|
|
67
67
|
"peerDependencies": {
|