ordering-components-external 13.2.23 → 13.2.24
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/_bundles/{7.ordering-component.7eadc8f0cb2d9320da3a.js → 7.ordering-component.0599c79450fa3a01dd9f.js} +1 -1
- package/_bundles/{ordering-component.7eadc8f0cb2d9320da3a.js → ordering-component.0599c79450fa3a01dd9f.js} +2 -2
- package/_modules/components/PaymentOptionStripeLink/index.js +10 -1
- package/package.json +1 -1
- package/src/components/PaymentOptionStripeLink/index.js +10 -1
- /package/_bundles/{0.ordering-component.7eadc8f0cb2d9320da3a.js → 0.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{1.ordering-component.7eadc8f0cb2d9320da3a.js → 1.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{2.ordering-component.7eadc8f0cb2d9320da3a.js → 2.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{4.ordering-component.7eadc8f0cb2d9320da3a.js → 4.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{5.ordering-component.7eadc8f0cb2d9320da3a.js → 5.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{6.ordering-component.7eadc8f0cb2d9320da3a.js → 6.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{7.ordering-component.7eadc8f0cb2d9320da3a.js.LICENSE.txt → 7.ordering-component.0599c79450fa3a01dd9f.js.LICENSE.txt} +0 -0
- /package/_bundles/{8.ordering-component.7eadc8f0cb2d9320da3a.js → 8.ordering-component.0599c79450fa3a01dd9f.js} +0 -0
- /package/_bundles/{ordering-component.7eadc8f0cb2d9320da3a.js.LICENSE.txt → ordering-component.0599c79450fa3a01dd9f.js.LICENSE.txt} +0 -0
|
@@ -34,7 +34,8 @@ function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
|
34
34
|
*/
|
|
35
35
|
var PaymentOptionStripeLink = exports.PaymentOptionStripeLink = function PaymentOptionStripeLink(props) {
|
|
36
36
|
var UIComponent = props.UIComponent,
|
|
37
|
-
paymentURL = props.paymentURL
|
|
37
|
+
paymentURL = props.paymentURL,
|
|
38
|
+
cartTotal = props.cartTotal;
|
|
38
39
|
var _useApi = (0, _ApiContext.useApi)(),
|
|
39
40
|
_useApi2 = _slicedToArray(_useApi, 1),
|
|
40
41
|
ordering = _useApi2[0];
|
|
@@ -78,6 +79,14 @@ var PaymentOptionStripeLink = exports.PaymentOptionStripeLink = function Payment
|
|
|
78
79
|
provider: customProviders.includes(ordering === null || ordering === void 0 ? void 0 : ordering.project) ? 'custom' : 'twilio',
|
|
79
80
|
country_phone_code: userInfo.country_phone_code,
|
|
80
81
|
cellphone: userInfo.cellphone,
|
|
82
|
+
payment_url: paymentURL,
|
|
83
|
+
user: {
|
|
84
|
+
name: userInfo === null || userInfo === void 0 ? void 0 : userInfo.name,
|
|
85
|
+
lastname: userInfo === null || userInfo === void 0 ? void 0 : userInfo.lastname
|
|
86
|
+
},
|
|
87
|
+
cart: {
|
|
88
|
+
total: cartTotal !== null && cartTotal !== void 0 ? cartTotal : 0
|
|
89
|
+
},
|
|
81
90
|
message: t('LINK_TO_PAY_MESSAGE', 'Hello there _name_ _lastname_, click on the following link to complete the payment: _link_').replace('_name_', userInfo === null || userInfo === void 0 ? void 0 : userInfo.name).replace('_lastname_', userInfo === null || userInfo === void 0 ? void 0 : userInfo.lastname).replace('_link_', paymentURL)
|
|
82
91
|
};
|
|
83
92
|
_context.next = 6;
|
package/package.json
CHANGED
|
@@ -11,7 +11,8 @@ import { useSession } from '../../contexts/SessionContext'
|
|
|
11
11
|
export const PaymentOptionStripeLink = (props) => {
|
|
12
12
|
const {
|
|
13
13
|
UIComponent,
|
|
14
|
-
paymentURL
|
|
14
|
+
paymentURL,
|
|
15
|
+
cartTotal
|
|
15
16
|
} = props
|
|
16
17
|
|
|
17
18
|
const [ordering] = useApi()
|
|
@@ -35,6 +36,14 @@ export const PaymentOptionStripeLink = (props) => {
|
|
|
35
36
|
provider: customProviders.includes(ordering?.project) ? 'custom' : 'twilio',
|
|
36
37
|
country_phone_code: userInfo.country_phone_code,
|
|
37
38
|
cellphone: userInfo.cellphone,
|
|
39
|
+
payment_url: paymentURL,
|
|
40
|
+
user: {
|
|
41
|
+
name: userInfo?.name,
|
|
42
|
+
lastname: userInfo?.lastname
|
|
43
|
+
},
|
|
44
|
+
cart: {
|
|
45
|
+
total: cartTotal ?? 0
|
|
46
|
+
},
|
|
38
47
|
message: t('LINK_TO_PAY_MESSAGE',
|
|
39
48
|
'Hello there _name_ _lastname_, click on the following link to complete the payment: _link_')
|
|
40
49
|
.replace('_name_', userInfo?.name)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|