@pisell/private-materials 3.0.183 → 3.0.185
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 +3 -3
- package/build/lowcode/render/default/view.js +9 -9
- package/build/lowcode/view.js +6 -6
- package/es/components/booking/addons/model.d.ts +1 -2
- package/es/components/booking/forms/model.d.ts +1 -2
- package/es/components/booking/info/utils.js +1 -1
- package/es/components/booking/notes/index.d.ts +1 -1
- package/es/components/booking/notes/model.d.ts +1 -2
- package/es/components/booking/payments/model.d.ts +1 -2
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/index.js +10 -2
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +17 -1
- package/es/components/pay/toC/PaymentMethods/index.js +6 -1
- package/es/components/pay/toC/index.js +10 -2
- package/es/components/schedules/index.d.ts +1 -1
- package/es/components/schedules/model.d.ts +1 -2
- package/lib/components/booking/addons/model.d.ts +1 -2
- package/lib/components/booking/forms/model.d.ts +1 -2
- package/lib/components/booking/info/utils.js +1 -1
- package/lib/components/booking/notes/index.d.ts +1 -1
- package/lib/components/booking/notes/model.d.ts +1 -2
- package/lib/components/booking/payments/model.d.ts +1 -2
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/index.js +18 -3
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +24 -0
- package/lib/components/pay/toC/PaymentMethods/index.js +6 -1
- package/lib/components/pay/toC/index.js +16 -2
- package/lib/components/schedules/index.d.ts +1 -1
- package/lib/components/schedules/model.d.ts +1 -2
- package/package.json +3 -3
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -88,6 +88,6 @@ export var isBooking4Shop = function isBooking4Shop(shopId, renderType) {
|
|
|
88
88
|
if (renderType === 'eventBooking') {
|
|
89
89
|
return false;
|
|
90
90
|
}
|
|
91
|
-
var booking4Shops = [1350, 1401, 3013, 7154, 7572, 7007, 8119, 7320, 7362, 6497, 6087];
|
|
91
|
+
var booking4Shops = [1350, 1401, 3013, 7154, 7572, 7007, 8119, 7320, 7362, 6497, 6087, 6303, 6726];
|
|
92
92
|
return booking4Shops.includes(shopId);
|
|
93
93
|
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -111,6 +111,8 @@ var TDSPay = function TDSPay(props, ref) {
|
|
|
111
111
|
payCallback === null || payCallback === void 0 ? void 0 : payCallback({
|
|
112
112
|
key: 'fail',
|
|
113
113
|
data: {
|
|
114
|
+
res: res,
|
|
115
|
+
fn: '_fastPayNew1',
|
|
114
116
|
message: locales.getText('tocPay.text.getParamsFail')
|
|
115
117
|
}
|
|
116
118
|
});
|
|
@@ -149,7 +151,11 @@ var TDSPay = function TDSPay(props, ref) {
|
|
|
149
151
|
// 失败
|
|
150
152
|
payCallback === null || payCallback === void 0 ? void 0 : payCallback({
|
|
151
153
|
key: 'fail',
|
|
152
|
-
data:
|
|
154
|
+
data: {
|
|
155
|
+
res: res,
|
|
156
|
+
fn: '_fastPayNew2',
|
|
157
|
+
message: locales.getText('tocPay.text.getParamsFail')
|
|
158
|
+
}
|
|
153
159
|
});
|
|
154
160
|
case 17:
|
|
155
161
|
case "end":
|
|
@@ -187,7 +193,9 @@ var TDSPay = function TDSPay(props, ref) {
|
|
|
187
193
|
payCallback === null || payCallback === void 0 ? void 0 : payCallback({
|
|
188
194
|
key: 'fail',
|
|
189
195
|
data: {
|
|
190
|
-
|
|
196
|
+
_cardInfo: _cardInfo,
|
|
197
|
+
message: locales.getText('tocPay.text.getParamsFail'),
|
|
198
|
+
fn: 'newCardPay'
|
|
191
199
|
}
|
|
192
200
|
});
|
|
193
201
|
return;
|
|
@@ -8,6 +8,8 @@ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input ==
|
|
|
8
8
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
9
9
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
10
10
|
import { request } from "../../../../../utils";
|
|
11
|
+
import dayjs from 'dayjs';
|
|
12
|
+
import { sendWarningLog } from '@pisell/utils';
|
|
11
13
|
import { PisellToast } from '@pisell/materials';
|
|
12
14
|
import { setPayNumber } from "../../payGroup";
|
|
13
15
|
var REACT_APP_API_ENV = process.env.REACT_APP_API_ENV;
|
|
@@ -29,7 +31,21 @@ var paymentInfo = {
|
|
|
29
31
|
var paymentData = {};
|
|
30
32
|
var postmessageUrl = 'merchantwarrior';
|
|
31
33
|
var log = function log(data) {
|
|
32
|
-
|
|
34
|
+
var _template = {
|
|
35
|
+
module: module,
|
|
36
|
+
contents: {
|
|
37
|
+
path: location.href,
|
|
38
|
+
data: data,
|
|
39
|
+
date: dayjs().format('YYYY-MM-DD HH:mm')
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
sendWarningLog({
|
|
43
|
+
title: '3ds支付失败',
|
|
44
|
+
content: [{
|
|
45
|
+
key: 'res',
|
|
46
|
+
value: JSON.stringify(_template)
|
|
47
|
+
}]
|
|
48
|
+
});
|
|
33
49
|
};
|
|
34
50
|
|
|
35
51
|
/**
|
|
@@ -78,7 +78,12 @@ var PaymentMethods = function PaymentMethods(props, ref) {
|
|
|
78
78
|
_context.prev = 10;
|
|
79
79
|
_context.t0 = _context["catch"](4);
|
|
80
80
|
return _context.abrupt("return", props.payCallback({
|
|
81
|
-
key: 'fail'
|
|
81
|
+
key: 'fail',
|
|
82
|
+
data: {
|
|
83
|
+
err: _context.t0,
|
|
84
|
+
payGroup: payGroup,
|
|
85
|
+
fn: 'init'
|
|
86
|
+
}
|
|
82
87
|
}));
|
|
83
88
|
case 13:
|
|
84
89
|
if (!(waitAmount <= 0)) {
|
|
@@ -221,7 +221,11 @@ var ToCPay = function ToCPay(props, ref) {
|
|
|
221
221
|
console.log('err', _context2.t0);
|
|
222
222
|
payCallback({
|
|
223
223
|
key: 'fail',
|
|
224
|
-
data: {
|
|
224
|
+
data: {
|
|
225
|
+
err: _context2.t0,
|
|
226
|
+
order: order,
|
|
227
|
+
fn: '_getPaymentsAndWalletPass'
|
|
228
|
+
}
|
|
225
229
|
});
|
|
226
230
|
case 15:
|
|
227
231
|
case "end":
|
|
@@ -319,7 +323,11 @@ var ToCPay = function ToCPay(props, ref) {
|
|
|
319
323
|
setSubmitLoading(false);
|
|
320
324
|
payCallback({
|
|
321
325
|
key: 'fail',
|
|
322
|
-
data: {
|
|
326
|
+
data: {
|
|
327
|
+
err: _context4.t0,
|
|
328
|
+
orderId: orderId,
|
|
329
|
+
fn: 'paymentInit'
|
|
330
|
+
}
|
|
323
331
|
});
|
|
324
332
|
case 14:
|
|
325
333
|
case "end":
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { CalendarDataItem, ScheduleItem } from "./type";
|
|
3
2
|
import dayjs from "dayjs";
|
|
4
3
|
export interface FormState {
|
|
@@ -69,7 +68,7 @@ export interface FormState {
|
|
|
69
68
|
};
|
|
70
69
|
setGlobalState: Function | null;
|
|
71
70
|
}
|
|
72
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
71
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
73
72
|
state: FormState;
|
|
74
73
|
} & {
|
|
75
74
|
dispatch: (params: {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -83,7 +83,7 @@ var isBooking4Shop = (shopId, renderType) => {
|
|
|
83
83
|
if (renderType === "eventBooking") {
|
|
84
84
|
return false;
|
|
85
85
|
}
|
|
86
|
-
const booking4Shops = [1350, 1401, 3013, 7154, 7572, 7007, 8119, 7320, 7362, 6497, 6087];
|
|
86
|
+
const booking4Shops = [1350, 1401, 3013, 7154, 7572, 7007, 8119, 7320, 7362, 6497, 6087, 6303, 6726];
|
|
87
87
|
return booking4Shops.includes(shopId);
|
|
88
88
|
};
|
|
89
89
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { FormState } from "../model";
|
|
3
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
2
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
4
3
|
state: FormState;
|
|
5
4
|
} & {
|
|
6
5
|
dispatch: (params: {
|
|
@@ -72,7 +72,11 @@ var TDSPay = (props, ref) => {
|
|
|
72
72
|
if (!params) {
|
|
73
73
|
payCallback == null ? void 0 : payCallback({
|
|
74
74
|
key: "fail",
|
|
75
|
-
data: {
|
|
75
|
+
data: {
|
|
76
|
+
res,
|
|
77
|
+
fn: "_fastPayNew1",
|
|
78
|
+
message: import_utils.locales.getText("tocPay.text.getParamsFail")
|
|
79
|
+
}
|
|
76
80
|
});
|
|
77
81
|
return;
|
|
78
82
|
}
|
|
@@ -88,7 +92,14 @@ var TDSPay = (props, ref) => {
|
|
|
88
92
|
(0, import_tds2.startPayment)({ payData: data }, payCallback);
|
|
89
93
|
}
|
|
90
94
|
} catch (e) {
|
|
91
|
-
payCallback == null ? void 0 : payCallback({
|
|
95
|
+
payCallback == null ? void 0 : payCallback({
|
|
96
|
+
key: "fail",
|
|
97
|
+
data: {
|
|
98
|
+
res,
|
|
99
|
+
fn: "_fastPayNew2",
|
|
100
|
+
message: import_utils.locales.getText("tocPay.text.getParamsFail")
|
|
101
|
+
}
|
|
102
|
+
});
|
|
92
103
|
}
|
|
93
104
|
};
|
|
94
105
|
const newCardPay = (res) => {
|
|
@@ -108,7 +119,11 @@ var TDSPay = (props, ref) => {
|
|
|
108
119
|
if (!_cardInfo) {
|
|
109
120
|
payCallback == null ? void 0 : payCallback({
|
|
110
121
|
key: "fail",
|
|
111
|
-
data: {
|
|
122
|
+
data: {
|
|
123
|
+
_cardInfo,
|
|
124
|
+
message: import_utils.locales.getText("tocPay.text.getParamsFail"),
|
|
125
|
+
fn: "newCardPay"
|
|
126
|
+
}
|
|
112
127
|
});
|
|
113
128
|
return;
|
|
114
129
|
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
1
2
|
var __defProp = Object.defineProperty;
|
|
2
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
4
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
7
|
var __export = (target, all) => {
|
|
6
8
|
for (var name in all)
|
|
@@ -14,6 +16,14 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
14
16
|
}
|
|
15
17
|
return to;
|
|
16
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
|
+
));
|
|
17
27
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
28
|
|
|
19
29
|
// src/components/pay/toC/PaymentMethods/MWCreditCard/tds2.tsx
|
|
@@ -29,6 +39,8 @@ __export(tds2_exports, {
|
|
|
29
39
|
});
|
|
30
40
|
module.exports = __toCommonJS(tds2_exports);
|
|
31
41
|
var import_utils = require("../../../../../utils");
|
|
42
|
+
var import_dayjs = __toESM(require("dayjs"));
|
|
43
|
+
var import_utils2 = require("@pisell/utils");
|
|
32
44
|
var import_materials = require("@pisell/materials");
|
|
33
45
|
var import_payGroup = require("../../payGroup");
|
|
34
46
|
var { REACT_APP_API_ENV } = process.env;
|
|
@@ -50,6 +62,18 @@ var paymentInfo = {
|
|
|
50
62
|
var paymentData = {};
|
|
51
63
|
var postmessageUrl = "merchantwarrior";
|
|
52
64
|
var log = (data) => {
|
|
65
|
+
let _template = {
|
|
66
|
+
module,
|
|
67
|
+
contents: {
|
|
68
|
+
path: location.href,
|
|
69
|
+
data,
|
|
70
|
+
date: (0, import_dayjs.default)().format("YYYY-MM-DD HH:mm")
|
|
71
|
+
}
|
|
72
|
+
};
|
|
73
|
+
(0, import_utils2.sendWarningLog)({
|
|
74
|
+
title: "3ds支付失败",
|
|
75
|
+
content: [{ key: "res", value: JSON.stringify(_template) }]
|
|
76
|
+
});
|
|
53
77
|
};
|
|
54
78
|
var startPayment = async ({ orderId, cardInfo, payData }, callback) => {
|
|
55
79
|
let paymentInfo2 = {
|
|
@@ -134,7 +134,14 @@ var ToCPay = (props, ref) => {
|
|
|
134
134
|
}, 100);
|
|
135
135
|
} catch (err) {
|
|
136
136
|
console.log("err", err);
|
|
137
|
-
payCallback({
|
|
137
|
+
payCallback({
|
|
138
|
+
key: "fail",
|
|
139
|
+
data: {
|
|
140
|
+
err,
|
|
141
|
+
order,
|
|
142
|
+
fn: "_getPaymentsAndWalletPass"
|
|
143
|
+
}
|
|
144
|
+
});
|
|
138
145
|
}
|
|
139
146
|
};
|
|
140
147
|
const handlePaymentByType = async (type, payGroup) => {
|
|
@@ -173,7 +180,14 @@ var ToCPay = (props, ref) => {
|
|
|
173
180
|
};
|
|
174
181
|
} catch (err) {
|
|
175
182
|
setSubmitLoading(false);
|
|
176
|
-
payCallback({
|
|
183
|
+
payCallback({
|
|
184
|
+
key: "fail",
|
|
185
|
+
data: {
|
|
186
|
+
err,
|
|
187
|
+
orderId,
|
|
188
|
+
fn: "paymentInit"
|
|
189
|
+
}
|
|
190
|
+
});
|
|
177
191
|
}
|
|
178
192
|
};
|
|
179
193
|
const waitAmount = (0, import_react.useMemo)(() => {
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { CalendarDataItem, ScheduleItem } from "./type";
|
|
3
2
|
import dayjs from "dayjs";
|
|
4
3
|
export interface FormState {
|
|
@@ -69,7 +68,7 @@ export interface FormState {
|
|
|
69
68
|
};
|
|
70
69
|
setGlobalState: Function | null;
|
|
71
70
|
}
|
|
72
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
71
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
|
|
73
72
|
state: FormState;
|
|
74
73
|
} & {
|
|
75
74
|
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.185",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -60,9 +60,9 @@
|
|
|
60
60
|
"rc-virtual-list": "^3.11.3",
|
|
61
61
|
"decimal.js": "^10.4.3",
|
|
62
62
|
"@pisell/utils": "1.0.42",
|
|
63
|
-
"@pisell/icon": "0.0.11",
|
|
64
63
|
"@pisell/date-picker": "1.0.100",
|
|
65
|
-
"@pisell/materials": "3.0.52"
|
|
64
|
+
"@pisell/materials": "3.0.52",
|
|
65
|
+
"@pisell/icon": "0.0.11"
|
|
66
66
|
},
|
|
67
67
|
"peerDependencies": {
|
|
68
68
|
"react": "^18.0.0",
|