@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.
Files changed (47) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/index.js +1 -1
  5. package/build/lowcode/meta.js +1 -1
  6. package/build/lowcode/preview.js +4 -4
  7. package/build/lowcode/render/default/view.js +13 -11
  8. package/build/lowcode/view.js +12 -10
  9. package/es/components/booking/addons/model.d.ts +2 -1
  10. package/es/components/booking/forms/forms.d.ts +1 -1
  11. package/es/components/booking/forms/model.d.ts +2 -1
  12. package/es/components/booking/info/header/index.js +2 -2
  13. package/es/components/booking/locales.d.ts +6 -6
  14. package/es/components/booking/locales.js +6 -6
  15. package/es/components/booking/notes/index.d.ts +1 -1
  16. package/es/components/booking/notes/model.d.ts +2 -1
  17. package/es/components/booking/payments/model.d.ts +2 -1
  18. package/es/components/eftposPay/store/index.d.ts +4 -4
  19. package/es/components/pay/toC/index.js +96 -24
  20. package/es/components/pay/toC/locales.d.ts +9 -0
  21. package/es/components/pay/toC/locales.js +12 -3
  22. package/es/components/pay/toC/status.d.ts +9 -0
  23. package/es/components/pay/toC/status.js +38 -4
  24. package/es/components/pay/toC/utils.d.ts +8 -0
  25. package/es/components/pay/toC/utils.js +13 -0
  26. package/es/components/schedules/index.d.ts +1 -1
  27. package/es/components/schedules/model.d.ts +2 -1
  28. package/lib/components/booking/addons/model.d.ts +2 -1
  29. package/lib/components/booking/forms/forms.d.ts +1 -1
  30. package/lib/components/booking/forms/model.d.ts +2 -1
  31. package/lib/components/booking/info/header/index.js +1 -1
  32. package/lib/components/booking/locales.d.ts +6 -6
  33. package/lib/components/booking/locales.js +6 -6
  34. package/lib/components/booking/notes/index.d.ts +1 -1
  35. package/lib/components/booking/notes/model.d.ts +2 -1
  36. package/lib/components/booking/payments/model.d.ts +2 -1
  37. package/lib/components/eftposPay/store/index.d.ts +4 -4
  38. package/lib/components/pay/toC/index.js +30 -0
  39. package/lib/components/pay/toC/locales.d.ts +9 -0
  40. package/lib/components/pay/toC/locales.js +12 -3
  41. package/lib/components/pay/toC/status.d.ts +9 -0
  42. package/lib/components/pay/toC/status.js +35 -5
  43. package/lib/components/pay/toC/utils.d.ts +8 -0
  44. package/lib/components/pay/toC/utils.js +9 -2
  45. package/lib/components/schedules/index.d.ts +1 -1
  46. package/lib/components/schedules/model.d.ts +2 -1
  47. package/package.json +4 -4
@@ -1,5 +1,6 @@
1
+ /// <reference types="react" />
1
2
  import { FormState } from "../model";
2
- export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
3
+ export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
3
4
  state: FormState;
4
5
  } & {
5
6
  dispatch: (params: {
@@ -21,5 +21,5 @@ export interface InfoProps {
21
21
  * @Author: zhiwei.Wang
22
22
  * @Date: 2024-01-30 17:10
23
23
  */
24
- declare const Forms: (props: any) => JSX.Element;
24
+ declare const Forms: (props: any) => any;
25
25
  export default Forms;
@@ -1,5 +1,6 @@
1
+ /// <reference types="react" />
1
2
  import { FormState } from "../model";
2
- export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
3
+ export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
3
4
  state: FormState;
4
5
  } & {
5
6
  dispatch: (params: {
@@ -370,9 +370,9 @@ var header = function header(_ref) {
370
370
  className: "go-payments-modal-content"
371
371
  }, /*#__PURE__*/React.createElement("div", {
372
372
  className: "go-payments-modal-content-title"
373
- }, locales.getText('page.booking.text.unconfirmed-payements')), /*#__PURE__*/React.createElement("div", {
373
+ }, locales.getText('page.booking.text.unconfirmed-payments')), /*#__PURE__*/React.createElement("div", {
374
374
  className: "go-payments-modal-content-desc"
375
- }, locales.getText('page.booking.text.unconfirmed-payements.msg')), /*#__PURE__*/React.createElement("div", {
375
+ }, locales.getText('page.booking.text.unconfirmed-payments.msg')), /*#__PURE__*/React.createElement("div", {
376
376
  className: "go-payments-footer"
377
377
  }, /*#__PURE__*/React.createElement(Button, {
378
378
  className: "go-payments-footer-btn",
@@ -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-payements': string;
183
- 'page.booking.text.unconfirmed-payements.msg': string;
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-payements': string;
378
- 'page.booking.text.unconfirmed-payements.msg': string;
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-payements': string;
573
- 'page.booking.text.unconfirmed-payements.msg': string;
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;
@@ -206,8 +206,8 @@ export default {
206
206
  return "".concat(customerName || '', " has already enrolled in the ").concat(title, " ").concat(listStr.join(','), ", Are you sure you want to enroll again\uFF1F");
207
207
  },
208
208
  'page.event.booking.text.duplicate-enrollment-confirm': 'Confirm',
209
- 'page.booking.text.unconfirmed-payements': 'Unconfirmed payements',
210
- 'page.booking.text.unconfirmed-payements.msg': 'There are unconfirmed payments, please confirm or void the payments first.',
209
+ 'page.booking.text.unconfirmed-payments': 'Unconfirmed payments',
210
+ 'page.booking.text.unconfirmed-payments.msg': 'There are unconfirmed payments, please confirm or void the payments first.',
211
211
  'page.booking.text.go-to-payments': 'Go to payments',
212
212
  'page.booking.text.cancel-only': 'Cancel only',
213
213
  'page.booking.text.refund': 'Refund',
@@ -434,8 +434,8 @@ export default {
434
434
  return "".concat(customerName || '', "\u5DF2\u62A5\u540D").concat(title, " ").concat(listStr.join(','), ", \u786E\u5B9A\u8981\u518D\u6B21\u62A5\u540D\u5417\uFF1F");
435
435
  },
436
436
  'page.event.booking.text.duplicate-enrollment-confirm': '确认',
437
- 'page.booking.text.unconfirmed-payements': '未确认的付款',
438
- 'page.booking.text.unconfirmed-payements.msg': '存在未确认的付款,请先确认收款或作废。',
437
+ 'page.booking.text.unconfirmed-payments': '未确认的付款',
438
+ 'page.booking.text.unconfirmed-payments.msg': '存在未确认的付款,请先确认收款或作废。',
439
439
  'page.booking.text.go-to-payments': '前往收款界面',
440
440
  'page.booking.text.cancel-only': '仅取消',
441
441
  'page.booking.text.refund': '退款',
@@ -662,8 +662,8 @@ export default {
662
662
  return "".concat(customerName || '', "\u5DF2\u5831\u540D").concat(title, " ").concat(listStr.join(','), ", \u78BA\u5B9A\u8981\u518D\u6B21\u5831\u540D\u55CE\uFF1F");
663
663
  },
664
664
  'page.event.booking.text.duplicate-enrollment-confirm': '確認',
665
- 'page.booking.text.unconfirmed-payements': '未確認的付款',
666
- 'page.booking.text.unconfirmed-payements.msg': '存在未確認的付款,請先確認收款或作廢。',
665
+ 'page.booking.text.unconfirmed-payments': '未確認的付款',
666
+ 'page.booking.text.unconfirmed-payments.msg': '存在未確認的付款,請先確認收款或作廢。',
667
667
  'page.booking.text.go-to-payments': '前往收款界面',
668
668
  'page.booking.text.cancel-only': '僅取消',
669
669
  'page.booking.text.refund': '退款',
@@ -4,5 +4,5 @@ export interface InfoProps {
4
4
  globalState: any;
5
5
  setGlobalState: any;
6
6
  }
7
- declare const Notes: (props: any) => JSX.Element;
7
+ declare const Notes: (props: any) => any;
8
8
  export default Notes;
@@ -1,5 +1,6 @@
1
+ /// <reference types="react" />
1
2
  import { FormState } from "../model";
2
- export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
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) => JSX.Element, Context: import("react").Context<{
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: "loading" | "success" | "warn" | "fail" | "question";
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?: "refund" | "pay" | "query" | undefined;
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?: "unset" | "step" | undefined;
198
+ type?: "step" | "unset" | undefined;
199
199
  render?: boolean | undefined;
200
200
  component?: string | undefined;
201
201
  lastComponent?: string | undefined;
202
- status?: "loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
202
+ status?: "success" | "warn" | "loading" | "fail" | "pedding" | "resove" | "reject" | "question" | undefined;
203
203
  warn?: ReactNode;
204
204
  steps?: {
205
205
  /** 用于重置当前步骤 */
@@ -16,8 +16,8 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
16
16
  import React, { useState, useMemo, useContext, useRef, useImperativeHandle, forwardRef } from 'react';
17
17
  import { Decimal } from 'decimal.js';
18
18
  import { useMemoizedFn, useUpdateEffect } from 'ahooks';
19
- import { PisellModal, PisellText, PisellContainer, PisellLoading } from '@pisell/materials';
20
- import { locales } from '@pisell/utils';
19
+ import { PisellModal, PisellText, PisellContainer, PisellLoading, PisellToast } from '@pisell/materials';
20
+ import { detectIncognito, locales, copyToClipboard } from '@pisell/utils';
21
21
  import PayCountdown from "./PayCountdown";
22
22
  import PayAmount from "./PayAmount";
23
23
  import WalletPassBlock from "./WalletPassBlock";
@@ -29,6 +29,7 @@ import useEngineContext from "../../../hooks/useEngineContext";
29
29
  import { request } from "../../../utils";
30
30
  import { removePayGroupFromStorage } from "./payGroup";
31
31
  import localeTexts from "./locales";
32
+ import { getIsWalletPassAndTripartitePayment } from "./utils";
32
33
  import "./index.less";
33
34
  /**
34
35
  * @title: C端支付
@@ -76,6 +77,11 @@ var ToCPay = function ToCPay(props, ref) {
76
77
  _useState10 = _slicedToArray(_useState9, 2),
77
78
  showInformation = _useState10[0],
78
79
  setShowInformation = _useState10[1];
80
+ // 隐私模式提示
81
+ var _useState11 = useState(false),
82
+ _useState12 = _slicedToArray(_useState11, 2),
83
+ showDetectIncognitoConfirm = _useState12[0],
84
+ setShowDetectIncognitoConfirm = _useState12[1];
79
85
  // lowCode utils
80
86
  var utils = context.appHelper.utils || {};
81
87
  // stope
@@ -373,6 +379,36 @@ var ToCPay = function ToCPay(props, ref) {
373
379
  }
374
380
  }, [state.payGroup, waitAmount, isWalletPassPay]);
375
381
 
382
+ /**
383
+ * @title: 获取是否提示无痕模式
384
+ * @description: walletPass和三方支付的组合支付在无痕模式浏览器需要给出提示
385
+ * @return: *
386
+ * @Author: shengjie.zuo
387
+ * @Date: 2024-08-30 10:23:48
388
+ */
389
+ var getIsShowDetectIncognitoConfirm = /*#__PURE__*/function () {
390
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(payGroup) {
391
+ var _yield$detectIncognit, isPrivate;
392
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
393
+ while (1) switch (_context5.prev = _context5.next) {
394
+ case 0:
395
+ _context5.next = 2;
396
+ return detectIncognito();
397
+ case 2:
398
+ _yield$detectIncognit = _context5.sent;
399
+ isPrivate = _yield$detectIncognit.isPrivate;
400
+ return _context5.abrupt("return", ((payGroup === null || payGroup === void 0 ? void 0 : payGroup.wait_amount) || 0) > 0 && getIsWalletPassAndTripartitePayment(payGroup) && isPrivate);
401
+ case 5:
402
+ case "end":
403
+ return _context5.stop();
404
+ }
405
+ }, _callee5);
406
+ }));
407
+ return function getIsShowDetectIncognitoConfirm(_x7) {
408
+ return _ref6.apply(this, arguments);
409
+ };
410
+ }();
411
+
376
412
  /**
377
413
  * @title: 提交
378
414
  * @description:
@@ -381,32 +417,43 @@ var ToCPay = function ToCPay(props, ref) {
381
417
  * @Date: 2024-08-15 13:25
382
418
  */
383
419
  var onSubmit = /*#__PURE__*/function () {
384
- var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(newOrderId) {
420
+ var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(newOrderId) {
385
421
  var _state$payGroup9;
386
- var newPayGroup;
387
- return _regeneratorRuntime().wrap(function _callee5$(_context5) {
388
- while (1) switch (_context5.prev = _context5.next) {
422
+ var newPayGroup, result;
423
+ return _regeneratorRuntime().wrap(function _callee6$(_context6) {
424
+ while (1) switch (_context6.prev = _context6.next) {
389
425
  case 0:
390
- newPayGroup = state.payGroup; // 如果未创建交易组, 则先创建交易组
426
+ newPayGroup = state.payGroup; // 是否要展示无痕模式提示
427
+ _context6.next = 3;
428
+ return getIsShowDetectIncognitoConfirm(newPayGroup);
429
+ case 3:
430
+ result = _context6.sent;
431
+ if (!result) {
432
+ _context6.next = 7;
433
+ break;
434
+ }
435
+ setShowDetectIncognitoConfirm(true);
436
+ return _context6.abrupt("return");
437
+ case 7:
391
438
  if ((_state$payGroup9 = state.payGroup) !== null && _state$payGroup9 !== void 0 && _state$payGroup9.payment_group_id) {
392
- _context5.next = 5;
439
+ _context6.next = 11;
393
440
  break;
394
441
  }
395
- _context5.next = 4;
442
+ _context6.next = 10;
396
443
  return paymentInit(newOrderId);
397
- case 4:
398
- newPayGroup = _context5.sent;
399
- case 5:
444
+ case 10:
445
+ newPayGroup = _context6.sent;
446
+ case 11:
400
447
  // 调用支付
401
448
  handlePaymentByType(undefined, newPayGroup);
402
- case 6:
449
+ case 12:
403
450
  case "end":
404
- return _context5.stop();
451
+ return _context6.stop();
405
452
  }
406
- }, _callee5);
453
+ }, _callee6);
407
454
  }));
408
- return function onSubmit(_x7) {
409
- return _ref6.apply(this, arguments);
455
+ return function onSubmit(_x8) {
456
+ return _ref7.apply(this, arguments);
410
457
  };
411
458
  }();
412
459
 
@@ -463,10 +510,10 @@ var ToCPay = function ToCPay(props, ref) {
463
510
  * @Date: 2024-08-09 14:25
464
511
  */
465
512
  var payCallback = /*#__PURE__*/function () {
466
- var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(res) {
513
+ var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee7(res) {
467
514
  var _props$callback;
468
- return _regeneratorRuntime().wrap(function _callee6$(_context6) {
469
- while (1) switch (_context6.prev = _context6.next) {
515
+ return _regeneratorRuntime().wrap(function _callee7$(_context7) {
516
+ while (1) switch (_context7.prev = _context7.next) {
470
517
  case 0:
471
518
  // 取消支付,关闭弹窗
472
519
  if (res.key === 'cancel') {
@@ -477,12 +524,12 @@ var ToCPay = function ToCPay(props, ref) {
477
524
  (_props$callback = props.callback) === null || _props$callback === void 0 ? void 0 : _props$callback.call(props, res);
478
525
  case 2:
479
526
  case "end":
480
- return _context6.stop();
527
+ return _context7.stop();
481
528
  }
482
- }, _callee6);
529
+ }, _callee7);
483
530
  }));
484
- return function payCallback(_x8) {
485
- return _ref7.apply(this, arguments);
531
+ return function payCallback(_x9) {
532
+ return _ref8.apply(this, arguments);
486
533
  };
487
534
  }();
488
535
 
@@ -619,6 +666,31 @@ var ToCPay = function ToCPay(props, ref) {
619
666
  onOk: function onOk() {
620
667
  setShowInformation(false);
621
668
  }
669
+ }), /*#__PURE__*/React.createElement(PisellModal.Information, {
670
+ open: showDetectIncognitoConfirm,
671
+ describe: locales.getText('tocPay.text.detectIncognitoConfirm'),
672
+ okText: locales.getText('tocPay.text.copyLink'),
673
+ closable: true,
674
+ maskClosable: false,
675
+ onCancel: function onCancel() {
676
+ setShowDetectIncognitoConfirm(false);
677
+ },
678
+ onOk: /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee8() {
679
+ return _regeneratorRuntime().wrap(function _callee8$(_context8) {
680
+ while (1) switch (_context8.prev = _context8.next) {
681
+ case 0:
682
+ _context8.next = 2;
683
+ return copyToClipboard(window.location.href);
684
+ case 2:
685
+ PisellToast({
686
+ content: locales.getText('tocPay.text.copySuccess')
687
+ });
688
+ case 3:
689
+ case "end":
690
+ return _context8.stop();
691
+ }
692
+ }, _callee8);
693
+ }))
622
694
  }), /*#__PURE__*/React.createElement(PisellLoading, {
623
695
  loading: loading,
624
696
  mask: true
@@ -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;
@@ -66,7 +66,10 @@ export default {
66
66
  'tocPay.text.walletPassNoExtraPay': 'No extra pay needed',
67
67
  'tocPay.text.walletCanPay': 'You can use the balance in your wallet pass or other eligible types of voucher to pay.',
68
68
  'tocPay.text.paymentInstructions': 'Instructions',
69
- 'tocPay.text.walletSearchEmpty': 'No results found.'
69
+ 'tocPay.text.walletSearchEmpty': 'No results found.',
70
+ '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.',
71
+ 'tocPay.text.copyLink': 'Copy link',
72
+ 'tocPay.text.copySuccess': 'Copy Success'
70
73
  },
71
74
  'zh-CN': {
72
75
  'tocPay.text.checkout': '结账',
@@ -134,7 +137,10 @@ export default {
134
137
  'tocPay.text.walletPassCompleteTitle': '请点击底部的“提交”按钮完成支付',
135
138
  'tocPay.text.walletPassNoExtraPay': '无需额外支付金额',
136
139
  'tocPay.text.walletCanPay': '您可以使用钱包内的余额或其他符合条件的代金券进行支付。',
137
- 'tocPay.text.walletSearchEmpty': '没有查询到任何结果。'
140
+ 'tocPay.text.walletSearchEmpty': '没有查询到任何结果。',
141
+ 'tocPay.text.detectIncognitoConfirm': '当前处于无痕模式,钱包支付可能失败,请复制链接在非无痕模式下继续支付。',
142
+ 'tocPay.text.copyLink': '复制链接',
143
+ 'tocPay.text.copySuccess': '复制成功'
138
144
  },
139
145
  'zh-HK': {
140
146
  'tocPay.text.checkout': '結帳',
@@ -202,6 +208,9 @@ export default {
202
208
  'tocPay.text.walletPassCompleteTitle': '請點擊底部的“提交”按鈕完成支付',
203
209
  'tocPay.text.walletPassNoExtraPay': '無需額外支付金額',
204
210
  'tocPay.text.walletCanPay': '您可以使用錢包內的餘額或其他符合資格的代金券進行支付。',
205
- 'tocPay.text.walletSearchEmpty': '沒有查詢到任何結果。'
211
+ 'tocPay.text.walletSearchEmpty': '沒有查詢到任何結果。',
212
+ 'tocPay.text.detectIncognitoConfirm': '目前處於無痕模式,錢包支付可能失敗,請複製連結在非無痕模式下繼續支付。',
213
+ 'tocPay.text.copyLink': '復製链接',
214
+ 'tocPay.text.copySuccess': '復製成功'
206
215
  }
207
216
  };
@@ -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;
@@ -21,48 +21,61 @@ export var paymentServices = {
21
21
  // stripe支付
22
22
  stripe: {
23
23
  // url: stripe,
24
+ isTripartitePayment: true
24
25
  },
25
26
  // 微信支付
26
27
  'globepay.wechat.jsapi': {
27
28
  // url: wxpay,
29
+ isTripartitePayment: true
28
30
  },
29
31
  // 微信H5支付
30
32
  'superpay.wechat.h5': {
31
33
  // url: wxpay,
32
- channel: ['wx']
34
+ channel: ['wx'],
35
+ isTripartitePayment: true
33
36
  },
34
37
  // 支付包H5支付
35
38
  'globepay.alipay.h5': {
36
39
  // url: alipay,
37
- channel: ['nowx', 'phone', 'ios']
40
+ channel: ['nowx', 'phone', 'ios'],
41
+ isTripartitePayment: true
38
42
  },
39
43
  'globepay.paypal.h5': {
40
44
  // url: paypal,
41
- channel: ['wx', 'nowx', 'phone', 'ios']
45
+ channel: ['wx', 'nowx', 'phone', 'ios'],
46
+ isTripartitePayment: false
42
47
  },
43
48
  'superpay.alipay.h5': {
44
49
  // url: alipay,
50
+ isTripartitePayment: true
45
51
  },
46
52
  'mw.google': {
47
53
  // url: google_pay,
54
+ isTripartitePayment: true
48
55
  },
49
56
  'mw.apple': {
50
57
  // url: apple_pay,
58
+ isTripartitePayment: true
51
59
  },
52
60
  'mw.credit_card': {
53
61
  // url: credit_card,
62
+ isTripartitePayment: true
54
63
  },
55
64
  'pisell.bank_deposit': {
56
65
  // url: bank_deposit,
66
+ isTripartitePayment: false
57
67
  },
58
68
  'pisell.offline_payment': {
59
69
  // url: offline_payment,
70
+ isTripartitePayment: false
60
71
  },
61
72
  'pisell.other.cashmanual': {
62
73
  // url: custom,
74
+ isTripartitePayment: false
63
75
  },
64
76
  'pisell.custom_payment': {
65
77
  // url: custom,
78
+ isTripartitePayment: false
66
79
  }
67
80
  };
68
81
  var getPaymentTypes = function getPaymentTypes() {
@@ -74,9 +87,30 @@ var getPaymentTypes = function getPaymentTypes() {
74
87
  }
75
88
  return arr;
76
89
  };
90
+ var getTripartitePaymentKeys = function getTripartitePaymentKeys() {
91
+ var arr = [];
92
+ for (var key in paymentServices) {
93
+ if (paymentServices[key].isTripartitePayment) {
94
+ arr.push(key);
95
+ }
96
+ }
97
+ return arr;
98
+ };
77
99
 
78
100
  //支付类型列表
79
101
  export var paymentTypes = getPaymentTypes();
102
+ export var tripartitePaymentKeys = getTripartitePaymentKeys();
80
103
  export var paymentKeys = Object.keys(paymentServices);
81
104
 
82
- // H5 分为 微信环境 非微信环境 手机环境 IOS环境
105
+ // H5 分为 微信环境 非微信环境 手机环境 IOS环境
106
+
107
+ /**
108
+ * @title: 判断是否是三方支付
109
+ * @description:
110
+ * @return: *
111
+ * @Author: shengjie.zuo
112
+ * @Date: 2024-08-30 10:16:26
113
+ */
114
+ export var isTripartitePayment = function isTripartitePayment(service) {
115
+ return tripartitePaymentKeys.includes(service);
116
+ };
@@ -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;
@@ -1,4 +1,5 @@
1
1
  import { Decimal } from 'decimal.js';
2
+ import { isTripartitePayment } from "./status";
2
3
  /**
3
4
  * 计算walletPass列表数据的总金额
4
5
  * @param list
@@ -45,4 +46,16 @@ export var formatWalletPassParams = function formatWalletPassParams(payGroup) {
45
46
  payment_group_id: payment_group_id,
46
47
  payments: payments
47
48
  };
49
+ };
50
+
51
+ /**
52
+ * @title: 获取是否walletPass和三方支付的组合支付
53
+ * @description: 三方支付 (stripe 支付宝 微信 苹果 谷歌)
54
+ * @return: *
55
+ * @Author: shengjie.zuo
56
+ * @Date: 2024-08-30 10:06:17
57
+ */
58
+ export var getIsWalletPassAndTripartitePayment = function getIsWalletPassAndTripartitePayment(payGroup) {
59
+ var _payGroup$walletPass, _payGroup$walletPass$, _payGroup$otherPaymen;
60
+ return (payGroup === null || payGroup === void 0 ? void 0 : (_payGroup$walletPass = payGroup.walletPass) === null || _payGroup$walletPass === void 0 ? void 0 : (_payGroup$walletPass$ = _payGroup$walletPass.cards) === null || _payGroup$walletPass$ === void 0 ? void 0 : _payGroup$walletPass$.length) && isTripartitePayment(payGroup === null || payGroup === void 0 ? void 0 : (_payGroup$otherPaymen = payGroup.otherPayment) === null || _payGroup$otherPaymen === void 0 ? void 0 : _payGroup$otherPaymen.service);
48
61
  };
@@ -1,3 +1,3 @@
1
1
  import "./index.less";
2
- declare const Schedules: (props: any) => JSX.Element;
2
+ declare const Schedules: (props: any) => any;
3
3
  export default Schedules;
@@ -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) => JSX.Element, Context: import("react").Context<{
72
+ export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
72
73
  state: FormState;
73
74
  } & {
74
75
  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) => JSX.Element, Context: import("react").Context<{
3
+ export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
3
4
  state: FormState;
4
5
  } & {
5
6
  dispatch: (params: {
@@ -21,5 +21,5 @@ export interface InfoProps {
21
21
  * @Author: zhiwei.Wang
22
22
  * @Date: 2024-01-30 17:10
23
23
  */
24
- declare const Forms: (props: any) => JSX.Element;
24
+ declare const Forms: (props: any) => any;
25
25
  export default Forms;
@@ -1,5 +1,6 @@
1
+ /// <reference types="react" />
1
2
  import { FormState } from "../model";
2
- export declare const Provider: (ComponentUi: any) => (props: any) => JSX.Element, Context: import("react").Context<{
3
+ export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
3
4
  state: FormState;
4
5
  } & {
5
6
  dispatch: (params: {
@@ -208,7 +208,7 @@ var header = ({ state, dispatch }) => {
208
208
  onCancel: () => {
209
209
  setModalContentState({ open: false });
210
210
  },
211
- children: /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-modal-content" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-modal-content-title" }, import_utils.locales.getText("page.booking.text.unconfirmed-payements")), /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-modal-content-desc" }, import_utils.locales.getText("page.booking.text.unconfirmed-payements.msg")), /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-footer" }, /* @__PURE__ */ import_react.default.createElement(
211
+ children: /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-modal-content" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-modal-content-title" }, import_utils.locales.getText("page.booking.text.unconfirmed-payments")), /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-modal-content-desc" }, import_utils.locales.getText("page.booking.text.unconfirmed-payments.msg")), /* @__PURE__ */ import_react.default.createElement("div", { className: "go-payments-footer" }, /* @__PURE__ */ import_react.default.createElement(
212
212
  import_antd.Button,
213
213
  {
214
214
  className: "go-payments-footer-btn",