tg-core-components 6.1.15 → 6.1.16-pix-integration.2
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/es/widgets/CashierAccordion/Payment/PaymentAccountForms/index.js +11 -8
- package/es/widgets/CashierAccordion/Payment/index.js +1 -1
- package/lib/widgets/CashierAccordion/Payment/PaymentAccountForms/index.js +11 -8
- package/lib/widgets/CashierAccordion/Payment/index.js +1 -1
- package/package.json +2 -2
|
@@ -322,6 +322,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
322
322
|
intl = _ref8.intl,
|
|
323
323
|
country = _ref8.country,
|
|
324
324
|
method = _ref8.method,
|
|
325
|
+
methodString = _ref8.methodString,
|
|
325
326
|
detail = _ref8.detail,
|
|
326
327
|
change = _ref8.change,
|
|
327
328
|
values = _ref8.values,
|
|
@@ -338,6 +339,8 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
338
339
|
setIsLoading = _useState4[1];
|
|
339
340
|
|
|
340
341
|
useEffect(function () {
|
|
342
|
+
if (method.service === 'PIX') return;
|
|
343
|
+
|
|
341
344
|
setIsLoading(true);
|
|
342
345
|
|
|
343
346
|
axios.post(config.devcode.host + '/directa24/getBanksByCountry', {
|
|
@@ -375,7 +378,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
375
378
|
return React.createElement(
|
|
376
379
|
'div',
|
|
377
380
|
null,
|
|
378
|
-
|
|
381
|
+
methodString === 'withdraw' && methodDetails.idTypes && methodDetails.idTypes.length > 1 && React.createElement(
|
|
379
382
|
Select,
|
|
380
383
|
{
|
|
381
384
|
required: true,
|
|
@@ -416,7 +419,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
416
419
|
defaultMessage: 'nationalId'
|
|
417
420
|
}, intl)
|
|
418
421
|
}),
|
|
419
|
-
|
|
422
|
+
methodString === 'withdraw' && methodDetails.banks && methodDetails.banks.length > 1 && React.createElement(
|
|
420
423
|
Select,
|
|
421
424
|
{
|
|
422
425
|
required: true,
|
|
@@ -445,7 +448,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
445
448
|
);
|
|
446
449
|
})
|
|
447
450
|
),
|
|
448
|
-
|
|
451
|
+
methodString === 'withdraw' && ['BR', 'UY', 'IN'].includes(country) && React.createElement(Input, {
|
|
449
452
|
required: true,
|
|
450
453
|
name: 'bankBranch',
|
|
451
454
|
value: values['bankBranch'],
|
|
@@ -457,7 +460,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
457
460
|
defaultMessage: 'bankBranch'
|
|
458
461
|
}, intl)
|
|
459
462
|
}),
|
|
460
|
-
|
|
463
|
+
methodString === 'withdraw' && methodDetails.accountTypes && methodDetails.accountTypes.length > 1 && React.createElement(
|
|
461
464
|
Select,
|
|
462
465
|
{
|
|
463
466
|
required: true,
|
|
@@ -486,7 +489,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
486
489
|
);
|
|
487
490
|
})
|
|
488
491
|
),
|
|
489
|
-
|
|
492
|
+
methodString === 'withdraw' && React.createElement(Input, {
|
|
490
493
|
required: true,
|
|
491
494
|
name: 'bankAccount',
|
|
492
495
|
value: values['bankAccount'],
|
|
@@ -498,7 +501,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
498
501
|
defaultMessage: 'bankAccount'
|
|
499
502
|
}, intl)
|
|
500
503
|
}),
|
|
501
|
-
|
|
504
|
+
methodString === 'deposit' && methodDetails.services && methodDetails.services.length > 1 && React.createElement(
|
|
502
505
|
Select,
|
|
503
506
|
{
|
|
504
507
|
required: true,
|
|
@@ -861,7 +864,7 @@ export var MobilePayDeposit = {
|
|
|
861
864
|
};
|
|
862
865
|
|
|
863
866
|
export var AstroPayBankDeposit = {
|
|
864
|
-
component: injectMethod({
|
|
867
|
+
component: injectMethod({ methodString: 'deposit' }, injectIntl(AstroPayBank)),
|
|
865
868
|
initialValues: function initialValues(props) {
|
|
866
869
|
var values = {};
|
|
867
870
|
var details = {
|
|
@@ -958,7 +961,7 @@ export var MuchBetterWithdrawal = {
|
|
|
958
961
|
};
|
|
959
962
|
|
|
960
963
|
export var AstroPayBankWithdrawal = {
|
|
961
|
-
component: injectMethod({
|
|
964
|
+
component: injectMethod({ methodString: 'withdraw' }, injectIntl(AstroPayBank)),
|
|
962
965
|
initialValues: function initialValues(props) {
|
|
963
966
|
var values = {};
|
|
964
967
|
var details = {
|
|
@@ -76,7 +76,7 @@ export var getPaymentForm = function getPaymentForm(_ref2) {
|
|
|
76
76
|
var txType = _ref2.txType,
|
|
77
77
|
service = _ref2.service;
|
|
78
78
|
|
|
79
|
-
if (txType === 'BankDeposit' && ['ASTROPAYBANK', 'WEBPAY', 'BOLETO'].includes(service)) return 'AstroPayBankDeposit';
|
|
79
|
+
if (txType === 'BankDeposit' && ['ASTROPAYBANK', 'WEBPAY', 'BOLETO', 'PIX'].includes(service)) return 'AstroPayBankDeposit';
|
|
80
80
|
|
|
81
81
|
return txType;
|
|
82
82
|
};
|
|
@@ -365,6 +365,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
365
365
|
intl = _ref8.intl,
|
|
366
366
|
country = _ref8.country,
|
|
367
367
|
method = _ref8.method,
|
|
368
|
+
methodString = _ref8.methodString,
|
|
368
369
|
detail = _ref8.detail,
|
|
369
370
|
change = _ref8.change,
|
|
370
371
|
values = _ref8.values,
|
|
@@ -381,6 +382,8 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
381
382
|
setIsLoading = _useState4[1];
|
|
382
383
|
|
|
383
384
|
(0, _react.useEffect)(function () {
|
|
385
|
+
if (method.service === 'PIX') return;
|
|
386
|
+
|
|
384
387
|
setIsLoading(true);
|
|
385
388
|
|
|
386
389
|
_axios2.default.post(config.devcode.host + '/directa24/getBanksByCountry', {
|
|
@@ -418,7 +421,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
418
421
|
return _react2.default.createElement(
|
|
419
422
|
'div',
|
|
420
423
|
null,
|
|
421
|
-
|
|
424
|
+
methodString === 'withdraw' && methodDetails.idTypes && methodDetails.idTypes.length > 1 && _react2.default.createElement(
|
|
422
425
|
_Select2.default,
|
|
423
426
|
{
|
|
424
427
|
required: true,
|
|
@@ -459,7 +462,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
459
462
|
defaultMessage: 'nationalId'
|
|
460
463
|
}, intl)
|
|
461
464
|
}),
|
|
462
|
-
|
|
465
|
+
methodString === 'withdraw' && methodDetails.banks && methodDetails.banks.length > 1 && _react2.default.createElement(
|
|
463
466
|
_Select2.default,
|
|
464
467
|
{
|
|
465
468
|
required: true,
|
|
@@ -488,7 +491,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
488
491
|
);
|
|
489
492
|
})
|
|
490
493
|
),
|
|
491
|
-
|
|
494
|
+
methodString === 'withdraw' && ['BR', 'UY', 'IN'].includes(country) && _react2.default.createElement(_Input2.default, {
|
|
492
495
|
required: true,
|
|
493
496
|
name: 'bankBranch',
|
|
494
497
|
value: values['bankBranch'],
|
|
@@ -500,7 +503,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
500
503
|
defaultMessage: 'bankBranch'
|
|
501
504
|
}, intl)
|
|
502
505
|
}),
|
|
503
|
-
|
|
506
|
+
methodString === 'withdraw' && methodDetails.accountTypes && methodDetails.accountTypes.length > 1 && _react2.default.createElement(
|
|
504
507
|
_Select2.default,
|
|
505
508
|
{
|
|
506
509
|
required: true,
|
|
@@ -529,7 +532,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
529
532
|
);
|
|
530
533
|
})
|
|
531
534
|
),
|
|
532
|
-
|
|
535
|
+
methodString === 'withdraw' && _react2.default.createElement(_Input2.default, {
|
|
533
536
|
required: true,
|
|
534
537
|
name: 'bankAccount',
|
|
535
538
|
value: values['bankAccount'],
|
|
@@ -541,7 +544,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
541
544
|
defaultMessage: 'bankAccount'
|
|
542
545
|
}, intl)
|
|
543
546
|
}),
|
|
544
|
-
|
|
547
|
+
methodString === 'deposit' && methodDetails.services && methodDetails.services.length > 1 && _react2.default.createElement(
|
|
545
548
|
_Select2.default,
|
|
546
549
|
{
|
|
547
550
|
required: true,
|
|
@@ -904,7 +907,7 @@ var MobilePayDeposit = exports.MobilePayDeposit = {
|
|
|
904
907
|
};
|
|
905
908
|
|
|
906
909
|
var AstroPayBankDeposit = exports.AstroPayBankDeposit = {
|
|
907
|
-
component: injectMethod({
|
|
910
|
+
component: injectMethod({ methodString: 'deposit' }, (0, _reactIntl.injectIntl)(AstroPayBank)),
|
|
908
911
|
initialValues: function initialValues(props) {
|
|
909
912
|
var values = {};
|
|
910
913
|
var details = {
|
|
@@ -1001,7 +1004,7 @@ var MuchBetterWithdrawal = exports.MuchBetterWithdrawal = {
|
|
|
1001
1004
|
};
|
|
1002
1005
|
|
|
1003
1006
|
var AstroPayBankWithdrawal = exports.AstroPayBankWithdrawal = {
|
|
1004
|
-
component: injectMethod({
|
|
1007
|
+
component: injectMethod({ methodString: 'withdraw' }, (0, _reactIntl.injectIntl)(AstroPayBank)),
|
|
1005
1008
|
initialValues: function initialValues(props) {
|
|
1006
1009
|
var values = {};
|
|
1007
1010
|
var details = {
|
|
@@ -81,7 +81,7 @@ var getPaymentForm = exports.getPaymentForm = function getPaymentForm(_ref2) {
|
|
|
81
81
|
var txType = _ref2.txType,
|
|
82
82
|
service = _ref2.service;
|
|
83
83
|
|
|
84
|
-
if (txType === 'BankDeposit' && ['ASTROPAYBANK', 'WEBPAY', 'BOLETO'].includes(service)) return 'AstroPayBankDeposit';
|
|
84
|
+
if (txType === 'BankDeposit' && ['ASTROPAYBANK', 'WEBPAY', 'BOLETO', 'PIX'].includes(service)) return 'AstroPayBankDeposit';
|
|
85
85
|
|
|
86
86
|
return txType;
|
|
87
87
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tg-core-components",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.16-pix-integration.2",
|
|
4
4
|
"description": "tg-core-components",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -76,5 +76,5 @@
|
|
|
76
76
|
"webpack": "^3.0.0",
|
|
77
77
|
"webpack-blocks": "^1.0.0"
|
|
78
78
|
},
|
|
79
|
-
"gitHead": "
|
|
79
|
+
"gitHead": "b20a4161872f434ee1c3356513abcfdb87bfd8a7"
|
|
80
80
|
}
|