@justifi/webcomponents 6.14.1 → 6.14.3
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/dist/cjs/{Analytics-8X9v2COT.js → Analytics-CBiQK20S.js} +2 -2
- package/dist/cjs/{Api-DdeSr34D.js → Api-ITroQ-Qg.js} +1 -1
- package/dist/cjs/additional-questions-form-step_15.cjs.entry.js +125 -129
- package/dist/cjs/bank-account-form.cjs.entry.js +2 -2
- package/dist/cjs/{business.service-OqWV2MwK.js → business.service-DnO0rTiK.js} +1 -1
- package/dist/cjs/card-form.cjs.entry.js +2 -2
- package/dist/cjs/{check-pkg-version-CeW26qxO.js → check-pkg-version-Ijgd8_6m.js} +1 -1
- package/dist/cjs/{checkout.service-CKgEKcmm.js → checkout.service-DWCv6eht.js} +1 -1
- package/dist/cjs/dispute-notification_2.cjs.entry.js +5 -5
- package/dist/cjs/{event-types-B8fM9Mqe.js → event-types-NzIs_zS2.js} +1 -1
- package/dist/cjs/{get-subaccounts-C1LbGVo_.js → get-subaccounts-Bxc3Vt13.js} +1 -1
- package/dist/cjs/hidden-input_2.cjs.entry.js +1 -1
- package/dist/cjs/justifi-apple-pay_11.cjs.entry.js +7 -7
- package/dist/cjs/justifi-bank-account-billing-form-simple.cjs.entry.js +5 -5
- package/dist/cjs/justifi-bank-account-form.cjs.entry.js +5 -5
- package/dist/cjs/justifi-billing-form-full.cjs.entry.js +1 -1
- package/dist/cjs/justifi-billing-form.cjs.entry.js +1 -1
- package/dist/cjs/justifi-business-details.cjs.entry.js +6 -6
- package/dist/cjs/justifi-business-form.cjs.entry.js +6 -6
- package/dist/cjs/justifi-card-billing-form-simple.cjs.entry.js +1 -1
- package/dist/cjs/justifi-card-form.cjs.entry.js +5 -5
- package/dist/cjs/justifi-checkout-qr-code.cjs.entry.js +4 -4
- package/dist/cjs/justifi-checkout.cjs.entry.js +5 -5
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +1 -1
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +7 -7
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +6 -6
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +5 -5
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +7 -7
- package/dist/cjs/justifi-payment-details.cjs.entry.js +6 -6
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +6 -6
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +6 -6
- package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +1 -1
- package/dist/cjs/justifi-payments-list.cjs.entry.js +6 -6
- package/dist/cjs/justifi-payout-details.cjs.entry.js +6 -6
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +6 -6
- package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +1 -1
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +7 -7
- package/dist/cjs/justifi-qr-terminal.cjs.entry.js +5 -5
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +6 -6
- package/dist/cjs/justifi-save-new-payment-method.cjs.entry.js +1 -1
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +5 -5
- package/dist/cjs/justifi-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +1 -1
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +5 -5
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +1 -1
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +7 -7
- package/dist/cjs/{package-CorQZH2M.js → package-D_dxBnW3.js} +1 -1
- package/dist/cjs/payment-method-option.cjs.entry.js +1 -1
- package/dist/cjs/{payment.service-B7x7eK6m.js → payment.service-DzCk-u8-.js} +1 -1
- package/dist/cjs/{payout.service-gzGWoXeh.js → payout.service-DQMp2E-M.js} +1 -1
- package/dist/cjs/{plaid.service-BphWvNSP.js → plaid.service-DobTNSxz.js} +1 -1
- package/dist/cjs/{styled-host-Ch0-dxF-.js → styled-host-CW1WUnUq.js} +1 -1
- package/dist/cjs/{terminal.service-BPrlu7uq.js → terminal.service-DMYipLNi.js} +1 -1
- package/dist/collection/api/ComponentEvents.js +17 -1
- package/dist/collection/components/business-forms/payment-provisioning/additional-questions/additional-questions-form-step.js +16 -19
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.js +15 -18
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +16 -19
- package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.js +16 -19
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +16 -18
- package/dist/collection/components/business-forms/payment-provisioning/document-upload/document-upload-form-step.js +15 -18
- package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.js +16 -19
- package/dist/docs.json +1 -1
- package/dist/esm/{Analytics-DY8rzGkY.js → Analytics-ru8vB8qb.js} +2 -2
- package/dist/esm/{Api-C6pVpXue.js → Api-7JrBn4d6.js} +1 -1
- package/dist/esm/additional-questions-form-step_15.entry.js +125 -129
- package/dist/esm/bank-account-form.entry.js +2 -2
- package/dist/esm/{business.service-DVaWaxuN.js → business.service-CR9Dcsks.js} +1 -1
- package/dist/esm/card-form.entry.js +2 -2
- package/dist/esm/{check-pkg-version-BYwiz3xi.js → check-pkg-version-BaPcn-Te.js} +1 -1
- package/dist/esm/{checkout.service-DCg5TSgj.js → checkout.service-BsrkzNvN.js} +1 -1
- package/dist/esm/dispute-notification_2.entry.js +5 -5
- package/dist/esm/{event-types-DV6dBcPL.js → event-types-CkRe9UDl.js} +1 -1
- package/dist/esm/{get-subaccounts-B1B7EBG1.js → get-subaccounts-OY5uSEGM.js} +1 -1
- package/dist/esm/hidden-input_2.entry.js +1 -1
- package/dist/esm/justifi-apple-pay_11.entry.js +7 -7
- package/dist/esm/justifi-bank-account-billing-form-simple.entry.js +5 -5
- package/dist/esm/justifi-bank-account-form.entry.js +5 -5
- package/dist/esm/justifi-billing-form-full.entry.js +1 -1
- package/dist/esm/justifi-billing-form.entry.js +1 -1
- package/dist/esm/justifi-business-details.entry.js +6 -6
- package/dist/esm/justifi-business-form.entry.js +6 -6
- package/dist/esm/justifi-card-billing-form-simple.entry.js +1 -1
- package/dist/esm/justifi-card-form.entry.js +5 -5
- package/dist/esm/justifi-checkout-qr-code.entry.js +4 -4
- package/dist/esm/justifi-checkout.entry.js +5 -5
- package/dist/esm/justifi-checkouts-list-filters.entry.js +1 -1
- package/dist/esm/justifi-checkouts-list.entry.js +7 -7
- package/dist/esm/justifi-dispute-management.entry.js +6 -6
- package/dist/esm/justifi-gross-payment-chart.entry.js +5 -5
- package/dist/esm/justifi-order-terminals.entry.js +7 -7
- package/dist/esm/justifi-payment-details.entry.js +6 -6
- package/dist/esm/justifi-payment-provisioning.entry.js +6 -6
- package/dist/esm/justifi-payment-transactions-list.entry.js +6 -6
- package/dist/esm/justifi-payments-list-filters.entry.js +1 -1
- package/dist/esm/justifi-payments-list.entry.js +6 -6
- package/dist/esm/justifi-payout-details.entry.js +6 -6
- package/dist/esm/justifi-payout-transactions-list.entry.js +6 -6
- package/dist/esm/justifi-payouts-list-filters.entry.js +1 -1
- package/dist/esm/justifi-payouts-list.entry.js +7 -7
- package/dist/esm/justifi-qr-terminal.entry.js +5 -5
- package/dist/esm/justifi-refund-payment.entry.js +6 -6
- package/dist/esm/justifi-save-new-payment-method.entry.js +1 -1
- package/dist/esm/justifi-season-interruption-insurance.entry.js +5 -5
- package/dist/esm/justifi-skeleton.entry.js +1 -1
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +1 -1
- package/dist/esm/justifi-terminal-orders-list.entry.js +5 -5
- package/dist/esm/justifi-terminals-list-filters.entry.js +1 -1
- package/dist/esm/justifi-terminals-list.entry.js +7 -7
- package/dist/esm/{package-DmrfgGzv.js → package-BmY4mdZN.js} +1 -1
- package/dist/esm/payment-method-option.entry.js +1 -1
- package/dist/esm/{payment.service-Dj3Jgj2F.js → payment.service-s-CoA47b.js} +1 -1
- package/dist/esm/{payout.service-CdcAA0_l.js → payout.service-CwsSsd0U.js} +1 -1
- package/dist/esm/{plaid.service-CwS4SIQb.js → plaid.service-D_D6sUFJ.js} +1 -1
- package/dist/esm/{styled-host-D84RBv1W.js → styled-host-RvPhw8Gu.js} +1 -1
- package/dist/esm/{terminal.service-DQz6FWpx.js → terminal.service-D5sQPp7g.js} +1 -1
- package/dist/module/Plaid.js +1 -1
- package/dist/module/additional-questions-form-step2.js +16 -20
- package/dist/module/business-bank-account-form-step2.js +16 -19
- package/dist/module/business-core-info-form-step2.js +16 -20
- package/dist/module/business-owners-form-step2.js +16 -20
- package/dist/module/business-representative-form-step2.js +17 -20
- package/dist/module/business-terms-conditions-form-step2.js +1 -1
- package/dist/module/dispute-response2.js +1 -1
- package/dist/module/document-upload-form-step2.js +16 -19
- package/dist/module/justifi-business-details.js +1 -1
- package/dist/module/justifi-business-form.js +1 -1
- package/dist/module/justifi-checkout-qr-code2.js +1 -1
- package/dist/module/justifi-checkouts-list.js +1 -1
- package/dist/module/justifi-dispute-management.js +1 -1
- package/dist/module/justifi-gross-payment-chart.js +1 -1
- package/dist/module/justifi-modular-checkout2.js +1 -1
- package/dist/module/justifi-order-terminals.js +1 -1
- package/dist/module/justifi-payment-details.js +1 -1
- package/dist/module/justifi-payment-provisioning.js +1 -1
- package/dist/module/justifi-payment-transactions-list.js +1 -1
- package/dist/module/justifi-payments-list.js +1 -1
- package/dist/module/justifi-payout-details.js +1 -1
- package/dist/module/justifi-payout-transactions-list.js +1 -1
- package/dist/module/justifi-payouts-list.js +1 -1
- package/dist/module/justifi-plaid-payment-method2.js +1 -1
- package/dist/module/justifi-qr-terminal.js +1 -1
- package/dist/module/justifi-refund-payment.js +1 -1
- package/dist/module/justifi-season-interruption-insurance.js +1 -1
- package/dist/module/justifi-terminal-orders-list.js +1 -1
- package/dist/module/justifi-terminals-list.js +1 -1
- package/dist/module/justifi-tokenize-payment-method2.js +1 -1
- package/dist/module/legal-address-form-step2.js +16 -20
- package/dist/module/package.js +1 -1
- package/dist/module/payment-provisioning-loading.js +19 -1
- package/dist/module/plaid-verification2.js +1 -1
- package/dist/module/styled-host.js +1 -1
- package/dist/module/utils3.js +1 -1
- package/dist/types/api/ComponentEvents.d.ts +2 -0
- package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +3 -3
- package/dist/webcomponents/{p-5257de4d.entry.js → p-0019df0b.entry.js} +1 -1
- package/dist/webcomponents/{p-DzEdYT8R.js → p-05AWudQe.js} +1 -1
- package/dist/webcomponents/{p-1cd30181.entry.js → p-08823a4a.entry.js} +1 -1
- package/dist/webcomponents/{p-f3c40c22.entry.js → p-0c1cc1e9.entry.js} +1 -1
- package/dist/webcomponents/{p-8b85daf8.entry.js → p-17806b1a.entry.js} +1 -1
- package/dist/webcomponents/{p-4781669c.entry.js → p-18066ad4.entry.js} +1 -1
- package/dist/webcomponents/{p-e1382f38.entry.js → p-1cff91b7.entry.js} +1 -1
- package/dist/webcomponents/{p-6a98c472.entry.js → p-1da47bad.entry.js} +4 -4
- package/dist/webcomponents/{p-3e1d3af4.entry.js → p-1e458958.entry.js} +1 -1
- package/dist/webcomponents/{p-c7b96d6f.entry.js → p-1e4c4b66.entry.js} +1 -1
- package/dist/webcomponents/{p-e659f030.entry.js → p-21674cdb.entry.js} +1 -1
- package/dist/webcomponents/{p-ae223a12.entry.js → p-220691ad.entry.js} +1 -1
- package/dist/webcomponents/{p-eaf179a0.entry.js → p-2926e9f7.entry.js} +1 -1
- package/dist/webcomponents/{p-f7258258.entry.js → p-31090560.entry.js} +1 -1
- package/dist/webcomponents/{p-df21d9b7.entry.js → p-3a723fa1.entry.js} +1 -1
- package/dist/webcomponents/{p-6c1e40e7.entry.js → p-45c05453.entry.js} +1 -1
- package/dist/webcomponents/{p-4791c6d7.entry.js → p-49f279c3.entry.js} +1 -1
- package/dist/webcomponents/{p-055640f9.entry.js → p-4f54d1b2.entry.js} +1 -1
- package/dist/webcomponents/{p-1d6c0821.entry.js → p-58e8d646.entry.js} +1 -1
- package/dist/webcomponents/p-5daa1e58.entry.js +1 -0
- package/dist/webcomponents/{p-2908f0e4.entry.js → p-7046686a.entry.js} +1 -1
- package/dist/webcomponents/{p-154bbb18.entry.js → p-7cd4ce1f.entry.js} +1 -1
- package/dist/webcomponents/p-8252a23b.entry.js +1 -0
- package/dist/webcomponents/{p-cc8ad073.entry.js → p-87c50070.entry.js} +1 -1
- package/dist/webcomponents/p-8fabef40.entry.js +1 -0
- package/dist/webcomponents/{p-7883f20e.entry.js → p-9551b11e.entry.js} +1 -1
- package/dist/webcomponents/{p-a1528ee7.entry.js → p-9cc293aa.entry.js} +1 -1
- package/dist/webcomponents/{p-IADrgGjR.js → p-BBn_-9nI.js} +1 -1
- package/dist/webcomponents/{p-DB4q0kxv.js → p-BDGCS3ww.js} +1 -1
- package/dist/webcomponents/{p-CoY0w4be.js → p-BSvONk1S.js} +1 -1
- package/dist/webcomponents/{p-C_YFlFQQ.js → p-BWJBtO9q.js} +1 -1
- package/dist/webcomponents/p-BmY4mdZN.js +1 -0
- package/dist/webcomponents/{p-CGTKc-Ra.js → p-CWnGGCoB.js} +1 -1
- package/dist/webcomponents/p-CqEly_AV.js +1 -0
- package/dist/webcomponents/{p-n4OrTH9l.js → p-CqS9uUYr.js} +1 -1
- package/dist/webcomponents/{p-CiIGpNnJ.js → p-DAvw3oWq.js} +1 -1
- package/dist/webcomponents/p-DsbNHsF7.js +1 -0
- package/dist/webcomponents/{p-ClGSzzda.js → p-WJlbuZRF.js} +1 -1
- package/dist/webcomponents/{p-BJIJZgZH.js → p-Y2iBsvwn.js} +1 -1
- package/dist/webcomponents/{p-ef3f9a80.entry.js → p-a6526002.entry.js} +1 -1
- package/dist/webcomponents/p-c851ae4f.entry.js +1 -0
- package/dist/webcomponents/{p-6d218257.entry.js → p-d4157eb2.entry.js} +1 -1
- package/dist/webcomponents/p-d4712e79.entry.js +1 -0
- package/dist/webcomponents/{p-762b1b7b.entry.js → p-da21ae43.entry.js} +1 -1
- package/dist/webcomponents/{p-62604f23.entry.js → p-dc0cc4aa.entry.js} +1 -1
- package/dist/webcomponents/{p-bebfcbdf.entry.js → p-deb20bae.entry.js} +1 -1
- package/dist/webcomponents/{p-6f0bca42.entry.js → p-e7cfee5a.entry.js} +1 -1
- package/dist/webcomponents/{p-4fd708ff.entry.js → p-e8917d14.entry.js} +1 -1
- package/dist/webcomponents/{p-c60c4bed.entry.js → p-ec6978cb.entry.js} +1 -1
- package/dist/webcomponents/{p-ab0449a9.entry.js → p-f373d313.entry.js} +1 -1
- package/dist/webcomponents/p-f4ce1bf4.entry.js +1 -0
- package/dist/webcomponents/{p-ad72e7c0.entry.js → p-f7ddb952.entry.js} +1 -1
- package/dist/webcomponents/{p-52f605a9.entry.js → p-f7ed42be.entry.js} +1 -1
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +3 -2
- package/dist/webcomponents/p-21fcf763.entry.js +0 -1
- package/dist/webcomponents/p-24a39581.entry.js +0 -1
- package/dist/webcomponents/p-5da3adf2.entry.js +0 -1
- package/dist/webcomponents/p-6c3e9ebd.entry.js +0 -1
- package/dist/webcomponents/p-981dcbc9.entry.js +0 -1
- package/dist/webcomponents/p-B9a-6Pn9.js +0 -1
- package/dist/webcomponents/p-DmrfgGzv.js +0 -1
- package/dist/webcomponents/p-RmBpI2DR.js +0 -1
- package/dist/webcomponents/p-ee3e88bc.entry.js +0 -1
|
@@ -1 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
import { ComponentErrorCodes, ComponentErrorSeverity } from "./ComponentError";
|
|
2
|
+
// Emits a MISSING_PROPS error naming each falsy prop. Returns true when all props are present.
|
|
3
|
+
// `props` keys are the public attribute names, e.g. { 'auth-token': this.authToken }.
|
|
4
|
+
export function validateRequiredProps(errorEvent, props) {
|
|
5
|
+
const missingProps = Object.entries(props)
|
|
6
|
+
.filter(([, value]) => !value)
|
|
7
|
+
.map(([name]) => name);
|
|
8
|
+
if (missingProps.length) {
|
|
9
|
+
errorEvent.emit({
|
|
10
|
+
message: `Missing required props: ${missingProps.join(', ')}`,
|
|
11
|
+
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
12
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
13
|
+
});
|
|
14
|
+
return false;
|
|
15
|
+
}
|
|
16
|
+
return true;
|
|
17
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import {
|
|
2
|
+
import { validateRequiredProps } from "../../../../api/ComponentEvents";
|
|
3
3
|
import { makeGetBusiness, makePatchBusiness } from "../payment-provisioning-actions";
|
|
4
4
|
import { BusinessService } from "../../../../api/services/business.service";
|
|
5
5
|
import { additionalQuestionsSchema } from "../../schemas/business-additional-questions-schema";
|
|
@@ -93,25 +93,22 @@ export class AdditionalQuestionsFormStep {
|
|
|
93
93
|
});
|
|
94
94
|
}
|
|
95
95
|
initializeApi() {
|
|
96
|
-
if (this.
|
|
97
|
-
this.
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
});
|
|
102
|
-
this.patchBusiness = makePatchBusiness({
|
|
103
|
-
authToken: this.authToken,
|
|
104
|
-
businessId: this.businessId,
|
|
105
|
-
service: new BusinessService()
|
|
106
|
-
});
|
|
107
|
-
}
|
|
108
|
-
else {
|
|
109
|
-
this.errorEvent.emit({
|
|
110
|
-
message: 'Missing required props',
|
|
111
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
112
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
113
|
-
});
|
|
96
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
97
|
+
'auth-token': this.authToken,
|
|
98
|
+
'business-id': this.businessId,
|
|
99
|
+
})) {
|
|
100
|
+
return;
|
|
114
101
|
}
|
|
102
|
+
this.getBusiness = makeGetBusiness({
|
|
103
|
+
authToken: this.authToken,
|
|
104
|
+
businessId: this.businessId,
|
|
105
|
+
service: new BusinessService()
|
|
106
|
+
});
|
|
107
|
+
this.patchBusiness = makePatchBusiness({
|
|
108
|
+
authToken: this.authToken,
|
|
109
|
+
businessId: this.businessId,
|
|
110
|
+
service: new BusinessService()
|
|
111
|
+
});
|
|
115
112
|
}
|
|
116
113
|
render() {
|
|
117
114
|
var _a, _b, _c, _d, _e;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import { ComponentErrorCodes, ComponentErrorSeverity, BankAccount } from "../../../../api";
|
|
2
|
+
import { ComponentErrorCodes, ComponentErrorSeverity, BankAccount, validateRequiredProps } from "../../../../api";
|
|
3
3
|
import { makeGetBusiness, makePostBankAccount } from "../payment-provisioning-actions";
|
|
4
4
|
import { BusinessService, BusinessBankAccountService } from "../../../../api/services/business.service";
|
|
5
5
|
import { CountryCode } from "../../../../utils/country-codes";
|
|
@@ -105,24 +105,21 @@ export class BusinessBankAccountFormStep {
|
|
|
105
105
|
});
|
|
106
106
|
}
|
|
107
107
|
initializeApi() {
|
|
108
|
-
if (this.
|
|
109
|
-
this.
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
});
|
|
114
|
-
this.postBankAccount = makePostBankAccount({
|
|
115
|
-
authToken: this.authToken,
|
|
116
|
-
service: new BusinessBankAccountService()
|
|
117
|
-
});
|
|
118
|
-
}
|
|
119
|
-
else {
|
|
120
|
-
this.errorEvent.emit({
|
|
121
|
-
message: 'Missing required props',
|
|
122
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
123
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
124
|
-
});
|
|
108
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
109
|
+
'auth-token': this.authToken,
|
|
110
|
+
'business-id': this.businessId,
|
|
111
|
+
})) {
|
|
112
|
+
return;
|
|
125
113
|
}
|
|
114
|
+
this.getBusiness = makeGetBusiness({
|
|
115
|
+
authToken: this.authToken,
|
|
116
|
+
businessId: this.businessId,
|
|
117
|
+
service: new BusinessService()
|
|
118
|
+
});
|
|
119
|
+
this.postBankAccount = makePostBankAccount({
|
|
120
|
+
authToken: this.authToken,
|
|
121
|
+
service: new BusinessBankAccountService()
|
|
122
|
+
});
|
|
126
123
|
}
|
|
127
124
|
get postPayload() {
|
|
128
125
|
const values = this.formController.values.getValue();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import { ComponentErrorCodes, ComponentErrorSeverity } from "../../../../api/ComponentError";
|
|
3
2
|
import { makeGetBusiness, makePatchBusiness } from "../payment-provisioning-actions";
|
|
4
3
|
import { BusinessService } from "../../../../api/services/business.service";
|
|
4
|
+
import { validateRequiredProps } from "../../../../api/ComponentEvents";
|
|
5
5
|
import { CountryCode } from "../../../../utils/country-codes";
|
|
6
6
|
import { businessCoreInfoSchemaUSA, businessCoreInfoSchemaCAN } from "../../schemas/business-core-info-schema";
|
|
7
7
|
import { FormController } from "../../../../ui-components/form/form";
|
|
@@ -102,25 +102,22 @@ export class BusinessCoreInfoFormStep {
|
|
|
102
102
|
});
|
|
103
103
|
}
|
|
104
104
|
initializeApi() {
|
|
105
|
-
if (this.
|
|
106
|
-
this.
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
});
|
|
111
|
-
this.patchBusiness = makePatchBusiness({
|
|
112
|
-
authToken: this.authToken,
|
|
113
|
-
businessId: this.businessId,
|
|
114
|
-
service: new BusinessService()
|
|
115
|
-
});
|
|
116
|
-
}
|
|
117
|
-
else {
|
|
118
|
-
this.errorEvent.emit({
|
|
119
|
-
message: 'Missing required props',
|
|
120
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
121
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
122
|
-
});
|
|
105
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
106
|
+
'auth-token': this.authToken,
|
|
107
|
+
'business-id': this.businessId,
|
|
108
|
+
})) {
|
|
109
|
+
return;
|
|
123
110
|
}
|
|
111
|
+
this.getBusiness = makeGetBusiness({
|
|
112
|
+
authToken: this.authToken,
|
|
113
|
+
businessId: this.businessId,
|
|
114
|
+
service: new BusinessService()
|
|
115
|
+
});
|
|
116
|
+
this.patchBusiness = makePatchBusiness({
|
|
117
|
+
authToken: this.authToken,
|
|
118
|
+
businessId: this.businessId,
|
|
119
|
+
service: new BusinessService()
|
|
120
|
+
});
|
|
124
121
|
}
|
|
125
122
|
render() {
|
|
126
123
|
var _a, _b;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
|
-
import { ComponentErrorCodes, ComponentErrorSeverity } from "../../../../api/ComponentError";
|
|
3
2
|
import { makeGetBusiness, makePatchBusiness } from "../payment-provisioning-actions";
|
|
4
3
|
import { BusinessService } from "../../../../api/services/business.service";
|
|
4
|
+
import { validateRequiredProps } from "../../../../api/ComponentEvents";
|
|
5
5
|
import { Button } from "../../../../ui-components";
|
|
6
6
|
import { heading2, alert } from "../../../../styles/parts";
|
|
7
7
|
import { PaymentProvisioningLoading } from "../payment-provisioning-loading";
|
|
@@ -162,25 +162,22 @@ export class BusinessOwnersFormStep {
|
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
164
|
initializeApi() {
|
|
165
|
-
if (this.
|
|
166
|
-
this.
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
});
|
|
171
|
-
this.patchBusiness = makePatchBusiness({
|
|
172
|
-
authToken: this.authToken,
|
|
173
|
-
businessId: this.businessId,
|
|
174
|
-
service: new BusinessService()
|
|
175
|
-
});
|
|
176
|
-
}
|
|
177
|
-
else {
|
|
178
|
-
this.errorEvent.emit({
|
|
179
|
-
message: 'Missing required props',
|
|
180
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
181
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
182
|
-
});
|
|
165
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
166
|
+
'auth-token': this.authToken,
|
|
167
|
+
'business-id': this.businessId,
|
|
168
|
+
})) {
|
|
169
|
+
return;
|
|
183
170
|
}
|
|
171
|
+
this.getBusiness = makeGetBusiness({
|
|
172
|
+
authToken: this.authToken,
|
|
173
|
+
businessId: this.businessId,
|
|
174
|
+
service: new BusinessService()
|
|
175
|
+
});
|
|
176
|
+
this.patchBusiness = makePatchBusiness({
|
|
177
|
+
authToken: this.authToken,
|
|
178
|
+
businessId: this.businessId,
|
|
179
|
+
service: new BusinessService()
|
|
180
|
+
});
|
|
184
181
|
}
|
|
185
182
|
ownersWatcher() {
|
|
186
183
|
this.manageRefs();
|
|
@@ -4,6 +4,7 @@ import { makeGetBusiness, makePatchBusiness } from "../payment-provisioning-acti
|
|
|
4
4
|
import { BusinessService } from "../../../../api/services/business.service";
|
|
5
5
|
import { Representative } from "../../../../api/Identity";
|
|
6
6
|
import { FormController } from "../../../../ui-components/form/form";
|
|
7
|
+
import { validateRequiredProps } from "../../../../api/ComponentEvents";
|
|
7
8
|
import { identitySchemaByCountry } from "../../schemas/business-identity-schema";
|
|
8
9
|
import { PaymentProvisioningLoading } from "../payment-provisioning-loading";
|
|
9
10
|
import { BusinessFormStep } from "../../utils";
|
|
@@ -72,25 +73,22 @@ export class BusinessRepresentativeFormStep {
|
|
|
72
73
|
this.initializeForm();
|
|
73
74
|
}
|
|
74
75
|
initializeApi() {
|
|
75
|
-
if (this.
|
|
76
|
-
this.
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
});
|
|
81
|
-
this.patchBusiness = makePatchBusiness({
|
|
82
|
-
authToken: this.authToken,
|
|
83
|
-
businessId: this.businessId,
|
|
84
|
-
service: new BusinessService()
|
|
85
|
-
});
|
|
86
|
-
}
|
|
87
|
-
else {
|
|
88
|
-
this.errorEvent.emit({
|
|
89
|
-
message: 'Missing required props',
|
|
90
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
91
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
92
|
-
});
|
|
76
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
77
|
+
'auth-token': this.authToken,
|
|
78
|
+
'business-id': this.businessId,
|
|
79
|
+
})) {
|
|
80
|
+
return;
|
|
93
81
|
}
|
|
82
|
+
this.getBusiness = makeGetBusiness({
|
|
83
|
+
authToken: this.authToken,
|
|
84
|
+
businessId: this.businessId,
|
|
85
|
+
service: new BusinessService()
|
|
86
|
+
});
|
|
87
|
+
this.patchBusiness = makePatchBusiness({
|
|
88
|
+
authToken: this.authToken,
|
|
89
|
+
businessId: this.businessId,
|
|
90
|
+
service: new BusinessService()
|
|
91
|
+
});
|
|
94
92
|
}
|
|
95
93
|
initializeForm() {
|
|
96
94
|
const schemaFactory = identitySchemaByCountry[this.country];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import { ComponentErrorCodes, ComponentErrorSeverity, EntityDocument, } from "../../../../api";
|
|
2
|
+
import { ComponentErrorCodes, ComponentErrorSeverity, validateRequiredProps, EntityDocument, } from "../../../../api";
|
|
3
3
|
import { makeGetBusiness, makePostDocumentRecord } from "../payment-provisioning-actions";
|
|
4
4
|
import { BusinessService, DocumentRecordService } from "../../../../api/services/business.service";
|
|
5
5
|
import { CountryCode } from "../../../../utils/country-codes";
|
|
@@ -163,24 +163,21 @@ export class DocumentUploadFormStep {
|
|
|
163
163
|
}
|
|
164
164
|
}
|
|
165
165
|
initializeApi() {
|
|
166
|
-
if (this.
|
|
167
|
-
this.
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
});
|
|
172
|
-
this.postDocumentRecord = makePostDocumentRecord({
|
|
173
|
-
authToken: this.authToken,
|
|
174
|
-
service: new DocumentRecordService()
|
|
175
|
-
});
|
|
176
|
-
}
|
|
177
|
-
else {
|
|
178
|
-
this.errorEvent.emit({
|
|
179
|
-
message: 'Missing required props',
|
|
180
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
181
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
182
|
-
});
|
|
166
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
167
|
+
'auth-token': this.authToken,
|
|
168
|
+
'business-id': this.businessId,
|
|
169
|
+
})) {
|
|
170
|
+
return;
|
|
183
171
|
}
|
|
172
|
+
this.getBusiness = makeGetBusiness({
|
|
173
|
+
authToken: this.authToken,
|
|
174
|
+
businessId: this.businessId,
|
|
175
|
+
service: new BusinessService()
|
|
176
|
+
});
|
|
177
|
+
this.postDocumentRecord = makePostDocumentRecord({
|
|
178
|
+
authToken: this.authToken,
|
|
179
|
+
service: new DocumentRecordService()
|
|
180
|
+
});
|
|
184
181
|
}
|
|
185
182
|
get categoryOptions() {
|
|
186
183
|
return [
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import { ComponentErrorCodes, ComponentErrorSeverity } from "../../../../api/ComponentError";
|
|
3
2
|
import { makeGetBusiness, makePatchBusiness } from "../payment-provisioning-actions";
|
|
4
3
|
import { BusinessService } from "../../../../api/services/business.service";
|
|
4
|
+
import { validateRequiredProps } from "../../../../api/ComponentEvents";
|
|
5
5
|
import { addressSchemaByCountry } from "../../schemas/business-address-schema";
|
|
6
6
|
import { FormController } from "../../../../ui-components/form/form";
|
|
7
7
|
import { Address } from "../../../../api/Business";
|
|
@@ -87,25 +87,22 @@ export class LegalAddressFormStep {
|
|
|
87
87
|
});
|
|
88
88
|
}
|
|
89
89
|
initializeApi() {
|
|
90
|
-
if (this.
|
|
91
|
-
this.
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
});
|
|
96
|
-
this.patchBusiness = makePatchBusiness({
|
|
97
|
-
authToken: this.authToken,
|
|
98
|
-
businessId: this.businessId,
|
|
99
|
-
service: new BusinessService()
|
|
100
|
-
});
|
|
101
|
-
}
|
|
102
|
-
else {
|
|
103
|
-
this.errorEvent.emit({
|
|
104
|
-
message: 'Missing required props',
|
|
105
|
-
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
106
|
-
severity: ComponentErrorSeverity.ERROR,
|
|
107
|
-
});
|
|
90
|
+
if (!validateRequiredProps(this.errorEvent, {
|
|
91
|
+
'auth-token': this.authToken,
|
|
92
|
+
'business-id': this.businessId,
|
|
93
|
+
})) {
|
|
94
|
+
return;
|
|
108
95
|
}
|
|
96
|
+
this.getBusiness = makeGetBusiness({
|
|
97
|
+
authToken: this.authToken,
|
|
98
|
+
businessId: this.businessId,
|
|
99
|
+
service: new BusinessService()
|
|
100
|
+
});
|
|
101
|
+
this.patchBusiness = makePatchBusiness({
|
|
102
|
+
authToken: this.authToken,
|
|
103
|
+
businessId: this.businessId,
|
|
104
|
+
service: new BusinessService()
|
|
105
|
+
});
|
|
109
106
|
}
|
|
110
107
|
render() {
|
|
111
108
|
var _a;
|
package/dist/docs.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { p as packageJson } from './package-
|
|
2
|
-
import { A as Api } from './Api-
|
|
1
|
+
import { p as packageJson } from './package-BmY4mdZN.js';
|
|
2
|
+
import { A as Api } from './Api-7JrBn4d6.js';
|
|
3
3
|
import './Plaid-D389VmvK.js';
|
|
4
4
|
import './Pagination-CLHwhyvu.js';
|
|
5
5
|
import './Business-BcNb9bVO.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { w as waitForConfig, c as configState } from './config-state-kKn89dp1.js';
|
|
2
2
|
import { g as generateId } from './utils-D8J8OvxY.js';
|
|
3
|
-
import { p as packageJson } from './package-
|
|
3
|
+
import { p as packageJson } from './package-BmY4mdZN.js';
|
|
4
4
|
|
|
5
5
|
const Api = () => {
|
|
6
6
|
async function getAuthorizationHeader(authToken) {
|