@pisell/private-materials 3.0.125 → 3.0.127
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 +4 -4
- package/build/lowcode/render/default/view.js +13 -11
- package/build/lowcode/view.js +12 -10
- package/es/components/booking/addons/model.d.ts +2 -1
- package/es/components/booking/forms/forms.d.ts +1 -1
- package/es/components/booking/forms/model.d.ts +2 -1
- package/es/components/booking/info/header/index.js +2 -2
- package/es/components/booking/locales.d.ts +6 -6
- package/es/components/booking/locales.js +6 -6
- package/es/components/booking/notes/index.d.ts +1 -1
- package/es/components/booking/notes/model.d.ts +2 -1
- package/es/components/booking/payments/model.d.ts +2 -1
- package/es/components/eftposPay/store/index.d.ts +4 -4
- package/es/components/pay/toC/index.js +96 -24
- package/es/components/pay/toC/locales.d.ts +9 -0
- package/es/components/pay/toC/locales.js +12 -3
- package/es/components/pay/toC/status.d.ts +9 -0
- package/es/components/pay/toC/status.js +38 -4
- package/es/components/pay/toC/utils.d.ts +8 -0
- package/es/components/pay/toC/utils.js +13 -0
- package/es/components/schedules/index.d.ts +1 -1
- package/es/components/schedules/model.d.ts +2 -1
- package/lib/components/booking/addons/model.d.ts +2 -1
- package/lib/components/booking/forms/forms.d.ts +1 -1
- package/lib/components/booking/forms/model.d.ts +2 -1
- package/lib/components/booking/info/header/index.js +1 -1
- package/lib/components/booking/locales.d.ts +6 -6
- package/lib/components/booking/locales.js +6 -6
- package/lib/components/booking/notes/index.d.ts +1 -1
- package/lib/components/booking/notes/model.d.ts +2 -1
- package/lib/components/booking/payments/model.d.ts +2 -1
- package/lib/components/eftposPay/store/index.d.ts +4 -4
- package/lib/components/pay/toC/index.js +30 -0
- package/lib/components/pay/toC/locales.d.ts +9 -0
- package/lib/components/pay/toC/locales.js +12 -3
- package/lib/components/pay/toC/status.d.ts +9 -0
- package/lib/components/pay/toC/status.js +35 -5
- package/lib/components/pay/toC/utils.d.ts +8 -0
- package/lib/components/pay/toC/utils.js +9 -2
- package/lib/components/schedules/index.d.ts +1 -1
- package/lib/components/schedules/model.d.ts +2 -1
- package/package.json +4 -4
|
@@ -179,8 +179,8 @@ declare const _default: {
|
|
|
179
179
|
list: any[];
|
|
180
180
|
}) => string;
|
|
181
181
|
'page.event.booking.text.duplicate-enrollment-confirm': string;
|
|
182
|
-
'page.booking.text.unconfirmed-
|
|
183
|
-
'page.booking.text.unconfirmed-
|
|
182
|
+
'page.booking.text.unconfirmed-payments': string;
|
|
183
|
+
'page.booking.text.unconfirmed-payments.msg': string;
|
|
184
184
|
'page.booking.text.go-to-payments': string;
|
|
185
185
|
'page.booking.text.cancel-only': string;
|
|
186
186
|
'page.booking.text.refund': string;
|
|
@@ -374,8 +374,8 @@ declare const _default: {
|
|
|
374
374
|
list: any[];
|
|
375
375
|
}) => string;
|
|
376
376
|
'page.event.booking.text.duplicate-enrollment-confirm': string;
|
|
377
|
-
'page.booking.text.unconfirmed-
|
|
378
|
-
'page.booking.text.unconfirmed-
|
|
377
|
+
'page.booking.text.unconfirmed-payments': string;
|
|
378
|
+
'page.booking.text.unconfirmed-payments.msg': string;
|
|
379
379
|
'page.booking.text.go-to-payments': string;
|
|
380
380
|
'page.booking.text.cancel-only': string;
|
|
381
381
|
'page.booking.text.refund': string;
|
|
@@ -569,8 +569,8 @@ declare const _default: {
|
|
|
569
569
|
list: any[];
|
|
570
570
|
}) => string;
|
|
571
571
|
'page.event.booking.text.duplicate-enrollment-confirm': string;
|
|
572
|
-
'page.booking.text.unconfirmed-
|
|
573
|
-
'page.booking.text.unconfirmed-
|
|
572
|
+
'page.booking.text.unconfirmed-payments': string;
|
|
573
|
+
'page.booking.text.unconfirmed-payments.msg': string;
|
|
574
574
|
'page.booking.text.go-to-payments': string;
|
|
575
575
|
'page.booking.text.cancel-only': string;
|
|
576
576
|
'page.booking.text.refund': string;
|
|
@@ -235,8 +235,8 @@ var locales_default = {
|
|
|
235
235
|
return `${customerName || ""} has already enrolled in the ${title} ${listStr.join(",")}, Are you sure you want to enroll again?`;
|
|
236
236
|
},
|
|
237
237
|
"page.event.booking.text.duplicate-enrollment-confirm": "Confirm",
|
|
238
|
-
"page.booking.text.unconfirmed-
|
|
239
|
-
"page.booking.text.unconfirmed-
|
|
238
|
+
"page.booking.text.unconfirmed-payments": "Unconfirmed payments",
|
|
239
|
+
"page.booking.text.unconfirmed-payments.msg": "There are unconfirmed payments, please confirm or void the payments first.",
|
|
240
240
|
"page.booking.text.go-to-payments": "Go to payments",
|
|
241
241
|
"page.booking.text.cancel-only": "Cancel only",
|
|
242
242
|
"page.booking.text.refund": "Refund",
|
|
@@ -456,8 +456,8 @@ var locales_default = {
|
|
|
456
456
|
return `${customerName || ""}已报名${title} ${listStr.join(",")}, 确定要再次报名吗?`;
|
|
457
457
|
},
|
|
458
458
|
"page.event.booking.text.duplicate-enrollment-confirm": "确认",
|
|
459
|
-
"page.booking.text.unconfirmed-
|
|
460
|
-
"page.booking.text.unconfirmed-
|
|
459
|
+
"page.booking.text.unconfirmed-payments": "未确认的付款",
|
|
460
|
+
"page.booking.text.unconfirmed-payments.msg": "存在未确认的付款,请先确认收款或作废。",
|
|
461
461
|
"page.booking.text.go-to-payments": "前往收款界面",
|
|
462
462
|
"page.booking.text.cancel-only": "仅取消",
|
|
463
463
|
"page.booking.text.refund": "退款",
|
|
@@ -677,8 +677,8 @@ var locales_default = {
|
|
|
677
677
|
return `${customerName || ""}已報名${title} ${listStr.join(",")}, 確定要再次報名嗎?`;
|
|
678
678
|
},
|
|
679
679
|
"page.event.booking.text.duplicate-enrollment-confirm": "確認",
|
|
680
|
-
"page.booking.text.unconfirmed-
|
|
681
|
-
"page.booking.text.unconfirmed-
|
|
680
|
+
"page.booking.text.unconfirmed-payments": "未確認的付款",
|
|
681
|
+
"page.booking.text.unconfirmed-payments.msg": "存在未確認的付款,請先確認收款或作廢。",
|
|
682
682
|
"page.booking.text.go-to-payments": "前往收款界面",
|
|
683
683
|
"page.booking.text.cancel-only": "僅取消",
|
|
684
684
|
"page.booking.text.refund": "退款",
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { FormState } from "../model";
|
|
2
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
3
4
|
state: FormState;
|
|
4
5
|
} & {
|
|
5
6
|
dispatch: (params: {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { FormState } from "../model";
|
|
2
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
3
4
|
state: FormState;
|
|
4
5
|
} & {
|
|
5
6
|
dispatch: (params: {
|
|
@@ -121,7 +121,7 @@ export declare const updateCustom: (payload: {
|
|
|
121
121
|
export declare const updateStatus: (status: 'loading' | 'warn' | 'fail' | 'success' | 'question') => {
|
|
122
122
|
type: EActionTypes;
|
|
123
123
|
payload: {
|
|
124
|
-
status: "
|
|
124
|
+
status: "success" | "warn" | "loading" | "fail" | "question";
|
|
125
125
|
};
|
|
126
126
|
};
|
|
127
127
|
export declare const updateWarn: (warn: ReactNode) => {
|
|
@@ -190,16 +190,16 @@ export declare const backUpProduction: (payload: Partial<State>) => {
|
|
|
190
190
|
export declare const backUpFree: (payload: Partial<State>) => {
|
|
191
191
|
type: EActionTypes;
|
|
192
192
|
payload: {
|
|
193
|
-
mode?: "
|
|
193
|
+
mode?: "pay" | "refund" | "query" | undefined;
|
|
194
194
|
eftpos?: "payo" | "tyro" | "windcave" | "stripe" | "eftpos" | undefined;
|
|
195
195
|
key?: number | undefined;
|
|
196
196
|
step?: number | undefined;
|
|
197
197
|
title?: string | undefined;
|
|
198
|
-
type?: "
|
|
198
|
+
type?: "step" | "unset" | undefined;
|
|
199
199
|
render?: boolean | undefined;
|
|
200
200
|
component?: string | undefined;
|
|
201
201
|
lastComponent?: string | undefined;
|
|
202
|
-
status?: "
|
|
202
|
+
status?: "success" | "warn" | "loading" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
|
|
203
203
|
warn?: ReactNode;
|
|
204
204
|
steps?: {
|
|
205
205
|
/** 用于重置当前步骤 */
|
|
@@ -48,6 +48,7 @@ var import_useEngineContext = __toESM(require("../../../hooks/useEngineContext")
|
|
|
48
48
|
var import_utils2 = require("../../../utils");
|
|
49
49
|
var import_payGroup = require("./payGroup");
|
|
50
50
|
var import_locales = __toESM(require("./locales"));
|
|
51
|
+
var import_utils3 = require("./utils");
|
|
51
52
|
var import_index = require("./index.less");
|
|
52
53
|
var ToCPay = (props, ref) => {
|
|
53
54
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q;
|
|
@@ -60,6 +61,7 @@ var ToCPay = (props, ref) => {
|
|
|
60
61
|
const [renderType, setRenderType] = (0, import_react.useState)("modal");
|
|
61
62
|
const context = (0, import_useEngineContext.default)();
|
|
62
63
|
const [showInformation, setShowInformation] = (0, import_react.useState)(false);
|
|
64
|
+
const [showDetectIncognitoConfirm, setShowDetectIncognitoConfirm] = (0, import_react.useState)(false);
|
|
63
65
|
const utils = context.appHelper.utils || {};
|
|
64
66
|
const dvaStore = (_c = (_b = (_a = context.appHelper.utils) == null ? void 0 : _a.getStore) == null ? void 0 : _b.call(_a)) == null ? void 0 : _c.getState();
|
|
65
67
|
const customer_id = (_i = (_h = (_g = (_f = (_e = (_d = context.appHelper.utils) == null ? void 0 : _d.getStore()) == null ? void 0 : _e.getState) == null ? void 0 : _f.call(_e)) == null ? void 0 : _g.global) == null ? void 0 : _h.userInfo) == null ? void 0 : _i.id;
|
|
@@ -192,9 +194,18 @@ var ToCPay = (props, ref) => {
|
|
|
192
194
|
return !isWalletPassPay;
|
|
193
195
|
}
|
|
194
196
|
}, [state.payGroup, waitAmount, isWalletPassPay]);
|
|
197
|
+
const getIsShowDetectIncognitoConfirm = async (payGroup) => {
|
|
198
|
+
const { isPrivate } = await (0, import_utils.detectIncognito)();
|
|
199
|
+
return ((payGroup == null ? void 0 : payGroup.wait_amount) || 0) > 0 && (0, import_utils3.getIsWalletPassAndTripartitePayment)(payGroup) && isPrivate;
|
|
200
|
+
};
|
|
195
201
|
const onSubmit = async (newOrderId) => {
|
|
196
202
|
var _a2;
|
|
197
203
|
let newPayGroup = state.payGroup;
|
|
204
|
+
const result = await getIsShowDetectIncognitoConfirm(newPayGroup);
|
|
205
|
+
if (result) {
|
|
206
|
+
setShowDetectIncognitoConfirm(true);
|
|
207
|
+
return;
|
|
208
|
+
}
|
|
198
209
|
if (!((_a2 = state.payGroup) == null ? void 0 : _a2.payment_group_id)) {
|
|
199
210
|
newPayGroup = await paymentInit(newOrderId);
|
|
200
211
|
}
|
|
@@ -331,6 +342,25 @@ var ToCPay = (props, ref) => {
|
|
|
331
342
|
}
|
|
332
343
|
}
|
|
333
344
|
),
|
|
345
|
+
/* @__PURE__ */ import_react.default.createElement(
|
|
346
|
+
import_materials.PisellModal.Information,
|
|
347
|
+
{
|
|
348
|
+
open: showDetectIncognitoConfirm,
|
|
349
|
+
describe: import_utils.locales.getText("tocPay.text.detectIncognitoConfirm"),
|
|
350
|
+
okText: import_utils.locales.getText("tocPay.text.copyLink"),
|
|
351
|
+
closable: true,
|
|
352
|
+
maskClosable: false,
|
|
353
|
+
onCancel: () => {
|
|
354
|
+
setShowDetectIncognitoConfirm(false);
|
|
355
|
+
},
|
|
356
|
+
onOk: async () => {
|
|
357
|
+
await (0, import_utils.copyToClipboard)(window.location.href);
|
|
358
|
+
(0, import_materials.PisellToast)({
|
|
359
|
+
content: import_utils.locales.getText("tocPay.text.copySuccess")
|
|
360
|
+
});
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
),
|
|
334
364
|
/* @__PURE__ */ import_react.default.createElement(
|
|
335
365
|
import_materials.PisellLoading,
|
|
336
366
|
{
|
|
@@ -67,6 +67,9 @@ declare const _default: {
|
|
|
67
67
|
'tocPay.text.walletCanPay': string;
|
|
68
68
|
'tocPay.text.paymentInstructions': string;
|
|
69
69
|
'tocPay.text.walletSearchEmpty': string;
|
|
70
|
+
'tocPay.text.detectIncognitoConfirm': string;
|
|
71
|
+
'tocPay.text.copyLink': string;
|
|
72
|
+
'tocPay.text.copySuccess': string;
|
|
70
73
|
};
|
|
71
74
|
'zh-CN': {
|
|
72
75
|
'tocPay.text.checkout': string;
|
|
@@ -135,6 +138,9 @@ declare const _default: {
|
|
|
135
138
|
'tocPay.text.walletPassNoExtraPay': string;
|
|
136
139
|
'tocPay.text.walletCanPay': string;
|
|
137
140
|
'tocPay.text.walletSearchEmpty': string;
|
|
141
|
+
'tocPay.text.detectIncognitoConfirm': string;
|
|
142
|
+
'tocPay.text.copyLink': string;
|
|
143
|
+
'tocPay.text.copySuccess': string;
|
|
138
144
|
};
|
|
139
145
|
'zh-HK': {
|
|
140
146
|
'tocPay.text.checkout': string;
|
|
@@ -203,6 +209,9 @@ declare const _default: {
|
|
|
203
209
|
'tocPay.text.walletPassNoExtraPay': string;
|
|
204
210
|
'tocPay.text.walletCanPay': string;
|
|
205
211
|
'tocPay.text.walletSearchEmpty': string;
|
|
212
|
+
'tocPay.text.detectIncognitoConfirm': string;
|
|
213
|
+
'tocPay.text.copyLink': string;
|
|
214
|
+
'tocPay.text.copySuccess': string;
|
|
206
215
|
};
|
|
207
216
|
};
|
|
208
217
|
export default _default;
|
|
@@ -90,7 +90,10 @@ var locales_default = {
|
|
|
90
90
|
"tocPay.text.walletPassNoExtraPay": "No extra pay needed",
|
|
91
91
|
"tocPay.text.walletCanPay": "You can use the balance in your wallet pass or other eligible types of voucher to pay.",
|
|
92
92
|
"tocPay.text.paymentInstructions": "Instructions",
|
|
93
|
-
"tocPay.text.walletSearchEmpty": "No results found."
|
|
93
|
+
"tocPay.text.walletSearchEmpty": "No results found.",
|
|
94
|
+
"tocPay.text.detectIncognitoConfirm": "You are currently in private mode, wallet payment may not succeed. Please copy the link and continue payment in a non-private browsing tab.",
|
|
95
|
+
"tocPay.text.copyLink": "Copy link",
|
|
96
|
+
"tocPay.text.copySuccess": "Copy Success"
|
|
94
97
|
},
|
|
95
98
|
"zh-CN": {
|
|
96
99
|
"tocPay.text.checkout": "结账",
|
|
@@ -158,7 +161,10 @@ var locales_default = {
|
|
|
158
161
|
"tocPay.text.walletPassCompleteTitle": "请点击底部的“提交”按钮完成支付",
|
|
159
162
|
"tocPay.text.walletPassNoExtraPay": "无需额外支付金额",
|
|
160
163
|
"tocPay.text.walletCanPay": "您可以使用钱包内的余额或其他符合条件的代金券进行支付。",
|
|
161
|
-
"tocPay.text.walletSearchEmpty": "没有查询到任何结果。"
|
|
164
|
+
"tocPay.text.walletSearchEmpty": "没有查询到任何结果。",
|
|
165
|
+
"tocPay.text.detectIncognitoConfirm": "当前处于无痕模式,钱包支付可能失败,请复制链接在非无痕模式下继续支付。",
|
|
166
|
+
"tocPay.text.copyLink": "复制链接",
|
|
167
|
+
"tocPay.text.copySuccess": "复制成功"
|
|
162
168
|
},
|
|
163
169
|
"zh-HK": {
|
|
164
170
|
"tocPay.text.checkout": "結帳",
|
|
@@ -226,6 +232,9 @@ var locales_default = {
|
|
|
226
232
|
"tocPay.text.walletPassCompleteTitle": "請點擊底部的“提交”按鈕完成支付",
|
|
227
233
|
"tocPay.text.walletPassNoExtraPay": "無需額外支付金額",
|
|
228
234
|
"tocPay.text.walletCanPay": "您可以使用錢包內的餘額或其他符合資格的代金券進行支付。",
|
|
229
|
-
"tocPay.text.walletSearchEmpty": "沒有查詢到任何結果。"
|
|
235
|
+
"tocPay.text.walletSearchEmpty": "沒有查詢到任何結果。",
|
|
236
|
+
"tocPay.text.detectIncognitoConfirm": "目前處於無痕模式,錢包支付可能失敗,請複製連結在非無痕模式下繼續支付。",
|
|
237
|
+
"tocPay.text.copyLink": "復製链接",
|
|
238
|
+
"tocPay.text.copySuccess": "復製成功"
|
|
230
239
|
}
|
|
231
240
|
};
|
|
@@ -1,3 +1,12 @@
|
|
|
1
1
|
export declare const paymentServices: any;
|
|
2
2
|
export declare const paymentTypes: any[];
|
|
3
|
+
export declare const tripartitePaymentKeys: string[];
|
|
3
4
|
export declare const paymentKeys: string[];
|
|
5
|
+
/**
|
|
6
|
+
* @title: 判断是否是三方支付
|
|
7
|
+
* @description:
|
|
8
|
+
* @return: *
|
|
9
|
+
* @Author: shengjie.zuo
|
|
10
|
+
* @Date: 2024-08-30 10:16:26
|
|
11
|
+
*/
|
|
12
|
+
export declare const isTripartitePayment: (service: string) => boolean;
|
|
@@ -19,57 +19,72 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
19
19
|
// src/components/pay/toC/status.ts
|
|
20
20
|
var status_exports = {};
|
|
21
21
|
__export(status_exports, {
|
|
22
|
+
isTripartitePayment: () => isTripartitePayment,
|
|
22
23
|
paymentKeys: () => paymentKeys,
|
|
23
24
|
paymentServices: () => paymentServices,
|
|
24
|
-
paymentTypes: () => paymentTypes
|
|
25
|
+
paymentTypes: () => paymentTypes,
|
|
26
|
+
tripartitePaymentKeys: () => tripartitePaymentKeys
|
|
25
27
|
});
|
|
26
28
|
module.exports = __toCommonJS(status_exports);
|
|
27
29
|
var paymentServices = {
|
|
28
30
|
// stripe支付
|
|
29
31
|
stripe: {
|
|
30
32
|
// url: stripe,
|
|
33
|
+
isTripartitePayment: true
|
|
31
34
|
},
|
|
32
35
|
// 微信支付
|
|
33
36
|
"globepay.wechat.jsapi": {
|
|
34
37
|
// url: wxpay,
|
|
38
|
+
isTripartitePayment: true
|
|
35
39
|
},
|
|
36
40
|
// 微信H5支付
|
|
37
41
|
"superpay.wechat.h5": {
|
|
38
42
|
// url: wxpay,
|
|
39
|
-
channel: ["wx"]
|
|
43
|
+
channel: ["wx"],
|
|
44
|
+
isTripartitePayment: true
|
|
40
45
|
},
|
|
41
46
|
// 支付包H5支付
|
|
42
47
|
"globepay.alipay.h5": {
|
|
43
48
|
// url: alipay,
|
|
44
|
-
channel: ["nowx", "phone", "ios"]
|
|
49
|
+
channel: ["nowx", "phone", "ios"],
|
|
50
|
+
isTripartitePayment: true
|
|
45
51
|
},
|
|
46
52
|
"globepay.paypal.h5": {
|
|
47
53
|
// url: paypal,
|
|
48
|
-
channel: ["wx", "nowx", "phone", "ios"]
|
|
54
|
+
channel: ["wx", "nowx", "phone", "ios"],
|
|
55
|
+
isTripartitePayment: false
|
|
49
56
|
},
|
|
50
57
|
"superpay.alipay.h5": {
|
|
51
58
|
// url: alipay,
|
|
59
|
+
isTripartitePayment: true
|
|
52
60
|
},
|
|
53
61
|
"mw.google": {
|
|
54
62
|
// url: google_pay,
|
|
63
|
+
isTripartitePayment: true
|
|
55
64
|
},
|
|
56
65
|
"mw.apple": {
|
|
57
66
|
// url: apple_pay,
|
|
67
|
+
isTripartitePayment: true
|
|
58
68
|
},
|
|
59
69
|
"mw.credit_card": {
|
|
60
70
|
// url: credit_card,
|
|
71
|
+
isTripartitePayment: true
|
|
61
72
|
},
|
|
62
73
|
"pisell.bank_deposit": {
|
|
63
74
|
// url: bank_deposit,
|
|
75
|
+
isTripartitePayment: false
|
|
64
76
|
},
|
|
65
77
|
"pisell.offline_payment": {
|
|
66
78
|
// url: offline_payment,
|
|
79
|
+
isTripartitePayment: false
|
|
67
80
|
},
|
|
68
81
|
"pisell.other.cashmanual": {
|
|
69
82
|
// url: custom,
|
|
83
|
+
isTripartitePayment: false
|
|
70
84
|
},
|
|
71
85
|
"pisell.custom_payment": {
|
|
72
86
|
// url: custom,
|
|
87
|
+
isTripartitePayment: false
|
|
73
88
|
}
|
|
74
89
|
};
|
|
75
90
|
var getPaymentTypes = () => {
|
|
@@ -82,11 +97,26 @@ var getPaymentTypes = () => {
|
|
|
82
97
|
}
|
|
83
98
|
return arr;
|
|
84
99
|
};
|
|
100
|
+
var getTripartitePaymentKeys = () => {
|
|
101
|
+
let arr = [];
|
|
102
|
+
for (let key in paymentServices) {
|
|
103
|
+
if (paymentServices[key].isTripartitePayment) {
|
|
104
|
+
arr.push(key);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
return arr;
|
|
108
|
+
};
|
|
85
109
|
var paymentTypes = getPaymentTypes();
|
|
110
|
+
var tripartitePaymentKeys = getTripartitePaymentKeys();
|
|
86
111
|
var paymentKeys = Object.keys(paymentServices);
|
|
112
|
+
var isTripartitePayment = (service) => {
|
|
113
|
+
return tripartitePaymentKeys.includes(service);
|
|
114
|
+
};
|
|
87
115
|
// Annotate the CommonJS export names for ESM import in node:
|
|
88
116
|
0 && (module.exports = {
|
|
117
|
+
isTripartitePayment,
|
|
89
118
|
paymentKeys,
|
|
90
119
|
paymentServices,
|
|
91
|
-
paymentTypes
|
|
120
|
+
paymentTypes,
|
|
121
|
+
tripartitePaymentKeys
|
|
92
122
|
});
|
|
@@ -28,3 +28,11 @@ export declare const formatWalletPassParams: (payGroup: PayGroup) => {
|
|
|
28
28
|
wallet_pass_usage_unit: any;
|
|
29
29
|
}[];
|
|
30
30
|
};
|
|
31
|
+
/**
|
|
32
|
+
* @title: 获取是否walletPass和三方支付的组合支付
|
|
33
|
+
* @description: 三方支付 (stripe 支付宝 微信 苹果 谷歌)
|
|
34
|
+
* @return: *
|
|
35
|
+
* @Author: shengjie.zuo
|
|
36
|
+
* @Date: 2024-08-30 10:06:17
|
|
37
|
+
*/
|
|
38
|
+
export declare const getIsWalletPassAndTripartitePayment: (payGroup: PayGroup) => boolean | 0 | undefined;
|
|
@@ -21,10 +21,12 @@ var utils_exports = {};
|
|
|
21
21
|
__export(utils_exports, {
|
|
22
22
|
calcWalletPassListAmount: () => calcWalletPassListAmount,
|
|
23
23
|
formatWalletPassList2PreparePayments: () => formatWalletPassList2PreparePayments,
|
|
24
|
-
formatWalletPassParams: () => formatWalletPassParams
|
|
24
|
+
formatWalletPassParams: () => formatWalletPassParams,
|
|
25
|
+
getIsWalletPassAndTripartitePayment: () => getIsWalletPassAndTripartitePayment
|
|
25
26
|
});
|
|
26
27
|
module.exports = __toCommonJS(utils_exports);
|
|
27
28
|
var import_decimal = require("decimal.js");
|
|
29
|
+
var import_status = require("./status");
|
|
28
30
|
var calcWalletPassListAmount = (list) => {
|
|
29
31
|
return list.reduce((pre, cur) => pre.add(new import_decimal.Decimal(String(cur.available_max_amount || 0))), new import_decimal.Decimal("0")).toNumber();
|
|
30
32
|
};
|
|
@@ -54,9 +56,14 @@ var formatWalletPassParams = (payGroup) => {
|
|
|
54
56
|
payments
|
|
55
57
|
};
|
|
56
58
|
};
|
|
59
|
+
var getIsWalletPassAndTripartitePayment = (payGroup) => {
|
|
60
|
+
var _a, _b, _c;
|
|
61
|
+
return ((_b = (_a = payGroup == null ? void 0 : payGroup.walletPass) == null ? void 0 : _a.cards) == null ? void 0 : _b.length) && (0, import_status.isTripartitePayment)((_c = payGroup == null ? void 0 : payGroup.otherPayment) == null ? void 0 : _c.service);
|
|
62
|
+
};
|
|
57
63
|
// Annotate the CommonJS export names for ESM import in node:
|
|
58
64
|
0 && (module.exports = {
|
|
59
65
|
calcWalletPassListAmount,
|
|
60
66
|
formatWalletPassList2PreparePayments,
|
|
61
|
-
formatWalletPassParams
|
|
67
|
+
formatWalletPassParams,
|
|
68
|
+
getIsWalletPassAndTripartitePayment
|
|
62
69
|
});
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { CalendarDataItem, ScheduleItem } from "./type";
|
|
2
3
|
import dayjs from "dayjs";
|
|
3
4
|
export interface FormState {
|
|
@@ -68,7 +69,7 @@ export interface FormState {
|
|
|
68
69
|
};
|
|
69
70
|
setGlobalState: Function | null;
|
|
70
71
|
}
|
|
71
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
72
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
72
73
|
state: FormState;
|
|
73
74
|
} & {
|
|
74
75
|
dispatch: (params: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/private-materials",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.127",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -59,10 +59,10 @@
|
|
|
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/
|
|
62
|
+
"@pisell/utils": "1.0.29",
|
|
63
|
+
"@pisell/materials": "3.0.42",
|
|
63
64
|
"@pisell/icon": "0.0.11",
|
|
64
|
-
"@pisell/date-picker": "1.0.
|
|
65
|
-
"@pisell/utils": "1.0.29"
|
|
65
|
+
"@pisell/date-picker": "1.0.99"
|
|
66
66
|
},
|
|
67
67
|
"peerDependencies": {
|
|
68
68
|
"react": "^18.0.0",
|