@dyedurham/search-and-file-widget 2.0.79 → 2.0.81
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/dnd-filing-shell.js +171 -127
- package/package.json +1 -1
package/dnd-filing-shell.js
CHANGED
|
@@ -57884,7 +57884,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
57884
57884
|
|
|
57885
57885
|
// src/app/utils/common.utils.ts
|
|
57886
57886
|
function buildValidationError(httpStatus, r) {
|
|
57887
|
-
const msgs = (r.Errors ?? []).map((e) => e.ErrorMessage || e.Message || e.message || e.Code || JSON.stringify(e)).filter(Boolean);
|
|
57887
|
+
const msgs = (r.Errors ?? r.errors ?? []).map((e) => e.ErrorMessage || e.Message || e.message || e.Code || JSON.stringify(e)).filter(Boolean);
|
|
57888
57888
|
const status = r.Status ? String(r.Status) : "ValidationFailed";
|
|
57889
57889
|
return new Error(msgs.length ? `eCore validation failed (HTTP ${httpStatus}, ${status}): ${msgs.join(" | ")}` : `eCore validation failed (HTTP ${httpStatus}, ${status}).`);
|
|
57890
57890
|
}
|
|
@@ -58123,7 +58123,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
58123
58123
|
return `${prefix}AnnualReturn`;
|
|
58124
58124
|
}
|
|
58125
58125
|
if (isChangeOfPrincipalsTask(task)) {
|
|
58126
|
-
return `${prefix}NoticeOfChangeOfDirectors`;
|
|
58126
|
+
return prefix === "bc" ? "bcChangeOfDirectors" : `${prefix}NoticeOfChangeOfDirectors`;
|
|
58127
58127
|
}
|
|
58128
58128
|
return void 0;
|
|
58129
58129
|
}
|
|
@@ -84330,7 +84330,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
84330
84330
|
}
|
|
84331
84331
|
const password = request.password ?? "";
|
|
84332
84332
|
if (password.length < BC_PASSWORD_MIN_LENGTH || password.length > BC_PASSWORD_MAX_LENGTH || !/^[A-Za-z0-9]+$/.test(password)) {
|
|
84333
|
-
issues.push(`
|
|
84333
|
+
issues.push(`Company Password must be ${BC_PASSWORD_MIN_LENGTH} to ${BC_PASSWORD_MAX_LENGTH} letters or digits only. Enter it in Corporation Details.`);
|
|
84334
84334
|
}
|
|
84335
84335
|
return issues;
|
|
84336
84336
|
}
|
|
@@ -84722,10 +84722,14 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
84722
84722
|
// Prefilled from the entity's Business Email when Athennian has one; otherwise the user
|
|
84723
84723
|
// enters it here (the API requires it).
|
|
84724
84724
|
[BCFormationFormControls.CompanyEmail]: new FormControl(deltaData?.companyEmail ?? companyEmail, [Validators.required, Validators.email, Validators.maxLength(BC_COMPANY_EMAIL_MAX_LENGTH)]),
|
|
84725
|
-
//
|
|
84726
|
-
//
|
|
84727
|
-
|
|
84728
|
-
|
|
84725
|
+
// The registry ID is only a suggestion: it is used when it already satisfies the BC
|
|
84726
|
+
// password rule, otherwise the field starts empty for the user to fill in.
|
|
84727
|
+
[BCFormationFormControls.CompanyPassword]: new FormControl(deltaData?.password ?? this.suggestPassword(task.entity._profile.registry_id), [
|
|
84728
|
+
Validators.required,
|
|
84729
|
+
Validators.minLength(BC_PASSWORD_MIN_LENGTH),
|
|
84730
|
+
Validators.maxLength(BC_PASSWORD_MAX_LENGTH),
|
|
84731
|
+
Validators.pattern(BC_PASSWORD_PATTERN)
|
|
84732
|
+
]),
|
|
84729
84733
|
[BCFormationFormControls.UsesNameTranslation]: new FormControl(usesNameTranslation),
|
|
84730
84734
|
[BCFormationFormControls.NameTranslations]: new FormArray(translationRows)
|
|
84731
84735
|
});
|
|
@@ -84827,15 +84831,6 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
84827
84831
|
})
|
|
84828
84832
|
});
|
|
84829
84833
|
}
|
|
84830
|
-
/**
|
|
84831
|
-
* Company Email dropdown options: the task's `emailOptions` (distinct addresses), plus the
|
|
84832
|
-
* current value when it is not among them (a saved or fallback-prefilled address).
|
|
84833
|
-
*/
|
|
84834
|
-
static buildCompanyEmailOptions(task, currentValue) {
|
|
84835
|
-
const emails = (task?.entity.emailOptions ?? []).map((option) => option.value?.trim());
|
|
84836
|
-
const current = currentValue?.trim();
|
|
84837
|
-
return [...new Set([...emails, current].filter((email) => Boolean(email)))].map((email) => ({ label: email, value: email }));
|
|
84838
|
-
}
|
|
84839
84834
|
static suggestPassword(registryId) {
|
|
84840
84835
|
const value = registryId?.trim() ?? "";
|
|
84841
84836
|
return value.length >= BC_PASSWORD_MIN_LENGTH && value.length <= BC_PASSWORD_MAX_LENGTH && BC_PASSWORD_PATTERN.test(value) ? value : "";
|
|
@@ -86146,15 +86141,27 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
86146
86141
|
dynamicLabel: (_, t) => t("There is an additional fee of {{fee}} for an effective date in the future.").replace("{{fee}}", BC_FUTURE_EFFECTIVE_DATE_FEE)
|
|
86147
86142
|
},
|
|
86148
86143
|
{
|
|
86149
|
-
|
|
86150
|
-
|
|
86144
|
+
type: FormType.Input,
|
|
86145
|
+
inputType: "email",
|
|
86151
86146
|
label: "Company Email",
|
|
86152
86147
|
formControlName: BCFormationFormControls.CompanyEmail,
|
|
86153
86148
|
required: true,
|
|
86154
|
-
|
|
86149
|
+
maxLength: BC_COMPANY_EMAIL_MAX_LENGTH,
|
|
86150
|
+
errorMessage: "Enter a valid email address",
|
|
86151
|
+
showRequiredMessage: true,
|
|
86152
|
+
class: "span-6"
|
|
86153
|
+
},
|
|
86154
|
+
{
|
|
86155
|
+
type: FormType.Input,
|
|
86156
|
+
inputType: "password",
|
|
86157
|
+
label: "Company Password",
|
|
86158
|
+
formControlName: BCFormationFormControls.CompanyPassword,
|
|
86159
|
+
required: true,
|
|
86160
|
+
maxLength: BC_PASSWORD_MAX_LENGTH,
|
|
86161
|
+
errorMessage: "Company Password must be 8 to 15 characters",
|
|
86162
|
+
showRequiredMessage: true,
|
|
86155
86163
|
class: "span-6"
|
|
86156
86164
|
}
|
|
86157
|
-
// The company password is not shown: it is taken from the entity's registry ID.
|
|
86158
86165
|
];
|
|
86159
86166
|
BC_FORMATION_DELTA_CARD_FORM_NAME_TRANSLATION_FIELDS = [
|
|
86160
86167
|
{
|
|
@@ -86513,7 +86520,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
86513
86520
|
const corporationDetails_r11 = \u0275\u0275readContextLet(6);
|
|
86514
86521
|
\u0275\u0275property("isValid", ctx_r0.sectionValidity["corpDetails"] && ctx_r0.sectionValidity["nameTranslation"] && ctx_r0.areNameTranslationsValid())("isStatusIcon", ctx_r0.statusIcon())("title", ctx_r0.groups.CorporationDetails);
|
|
86515
86522
|
\u0275\u0275advance(2);
|
|
86516
|
-
\u0275\u0275property("isSubmitted", ctx_r0.isSubmitted())("form", corporationDetails_r11)("config", ctx_r0.corporationDetailsFields
|
|
86523
|
+
\u0275\u0275property("isSubmitted", ctx_r0.isSubmitted())("form", corporationDetails_r11)("config", ctx_r0.corporationDetailsFields);
|
|
86517
86524
|
\u0275\u0275advance(2);
|
|
86518
86525
|
\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(5, 11, "Name Translation"));
|
|
86519
86526
|
\u0275\u0275advance(2);
|
|
@@ -86748,12 +86755,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
86748
86755
|
groups = BCFormationFormGroups;
|
|
86749
86756
|
controls = BCFormationFormControls;
|
|
86750
86757
|
referenceNumbersFields = BC_FORMATION_DELTA_CARD_FORM_REFERENCE_NUMBERS_FIELDS;
|
|
86751
|
-
|
|
86752
|
-
corporationDetailsFields = computed(() => {
|
|
86753
|
-
const currentEmail = this.form().get(this.groups.CorporationDetails)?.get(this.controls.CompanyEmail)?.value;
|
|
86754
|
-
const emailOptions = BritishColumbiaFormationFormHelper.buildCompanyEmailOptions(this.task(), currentEmail);
|
|
86755
|
-
return BC_FORMATION_DELTA_CARD_FORM_CORPORATION_DETAILS_FIELDS.map((field) => field.formControlName === this.controls.CompanyEmail ? __spreadProps(__spreadValues({}, field), { options: emailOptions }) : field);
|
|
86756
|
-
});
|
|
86758
|
+
corporationDetailsFields = BC_FORMATION_DELTA_CARD_FORM_CORPORATION_DETAILS_FIELDS;
|
|
86757
86759
|
nameTranslationFields = BC_FORMATION_DELTA_CARD_FORM_NAME_TRANSLATION_FIELDS;
|
|
86758
86760
|
nameTranslationRowFields = BC_FORMATION_DELTA_CARD_FORM_NAME_TRANSLATION_ROW_FIELDS;
|
|
86759
86761
|
registeredOfficeFields = BC_FORMATION_CARD_FORM_REGISTERED_OFFICE_FIELDS;
|
|
@@ -86943,7 +86945,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
86943
86945
|
<filing-form-group\r
|
|
86944
86946
|
[isSubmitted]="isSubmitted()"\r
|
|
86945
86947
|
[form]="corporationDetails"\r
|
|
86946
|
-
[config]="corporationDetailsFields
|
|
86948
|
+
[config]="corporationDetailsFields"\r
|
|
86947
86949
|
(visiblyValidChange)="onSectionValidChange('corpDetails', $event)"\r
|
|
86948
86950
|
/>\r
|
|
86949
86951
|
\r
|
|
@@ -87368,7 +87370,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87368
87370
|
function BritishColumbiaComponent_Conditional_1_Conditional_0_Template(rf, ctx) {
|
|
87369
87371
|
if (rf & 1) {
|
|
87370
87372
|
const _r1 = \u0275\u0275getCurrentView();
|
|
87371
|
-
\u0275\u0275elementStart(0, "british-columbia-change-of-directors-delta-form",
|
|
87373
|
+
\u0275\u0275elementStart(0, "british-columbia-change-of-directors-delta-form", 2);
|
|
87372
87374
|
\u0275\u0275listener("validate", function BritishColumbiaComponent_Conditional_1_Conditional_0_Template_british_columbia_change_of_directors_delta_form_validate_0_listener() {
|
|
87373
87375
|
\u0275\u0275restoreView(_r1);
|
|
87374
87376
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
@@ -87393,7 +87395,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87393
87395
|
function BritishColumbiaComponent_Conditional_1_Conditional_1_Template(rf, ctx) {
|
|
87394
87396
|
if (rf & 1) {
|
|
87395
87397
|
const _r4 = \u0275\u0275getCurrentView();
|
|
87396
|
-
\u0275\u0275elementStart(0, "british-columbia-change-of-directors-preview-form",
|
|
87398
|
+
\u0275\u0275elementStart(0, "british-columbia-change-of-directors-preview-form", 3);
|
|
87397
87399
|
\u0275\u0275listener("close", function BritishColumbiaComponent_Conditional_1_Conditional_1_Template_british_columbia_change_of_directors_preview_form_close_0_listener() {
|
|
87398
87400
|
\u0275\u0275restoreView(_r4);
|
|
87399
87401
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
@@ -87401,7 +87403,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87401
87403
|
})("file", function BritishColumbiaComponent_Conditional_1_Conditional_1_Template_british_columbia_change_of_directors_preview_form_file_0_listener() {
|
|
87402
87404
|
\u0275\u0275restoreView(_r4);
|
|
87403
87405
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87404
|
-
return \u0275\u0275resetView(ctx_r1.
|
|
87406
|
+
return \u0275\u0275resetView(ctx_r1.onChangeOfDirectorsSubmit());
|
|
87405
87407
|
});
|
|
87406
87408
|
\u0275\u0275elementEnd();
|
|
87407
87409
|
}
|
|
@@ -87411,57 +87413,31 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87411
87413
|
\u0275\u0275property("task", taskData_r3)("form", ctx_r1.previewForm())("actionsDisabled", ctx_r1.actionsDisabled())("errors", ctx_r1.errors());
|
|
87412
87414
|
}
|
|
87413
87415
|
}
|
|
87414
|
-
function BritishColumbiaComponent_Conditional_1_Conditional_2_Template(rf, ctx) {
|
|
87415
|
-
if (rf & 1) {
|
|
87416
|
-
const _r5 = \u0275\u0275getCurrentView();
|
|
87417
|
-
\u0275\u0275elementStart(0, "terms-and-conditions", 5);
|
|
87418
|
-
\u0275\u0275listener("prev", function BritishColumbiaComponent_Conditional_1_Conditional_2_Template_terms_and_conditions_prev_0_listener() {
|
|
87419
|
-
\u0275\u0275restoreView(_r5);
|
|
87420
|
-
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87421
|
-
return \u0275\u0275resetView(ctx_r1.prevStep.emit());
|
|
87422
|
-
})("close", function BritishColumbiaComponent_Conditional_1_Conditional_2_Template_terms_and_conditions_close_0_listener() {
|
|
87423
|
-
\u0275\u0275restoreView(_r5);
|
|
87424
|
-
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87425
|
-
return \u0275\u0275resetView(ctx_r1.close.emit());
|
|
87426
|
-
})("confirm", function BritishColumbiaComponent_Conditional_1_Conditional_2_Template_terms_and_conditions_confirm_0_listener($event) {
|
|
87427
|
-
\u0275\u0275restoreView(_r5);
|
|
87428
|
-
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87429
|
-
return \u0275\u0275resetView(ctx_r1.onChangeOfDirectorsSubmit($event));
|
|
87430
|
-
});
|
|
87431
|
-
\u0275\u0275elementEnd();
|
|
87432
|
-
}
|
|
87433
|
-
if (rf & 2) {
|
|
87434
|
-
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87435
|
-
\u0275\u0275property("errors", ctx_r1.errors());
|
|
87436
|
-
}
|
|
87437
|
-
}
|
|
87438
87416
|
function BritishColumbiaComponent_Conditional_1_Template(rf, ctx) {
|
|
87439
87417
|
if (rf & 1) {
|
|
87440
|
-
\u0275\u0275template(0, BritishColumbiaComponent_Conditional_1_Conditional_0_Template, 1, 5, "british-columbia-change-of-directors-delta-form", 0)(1, BritishColumbiaComponent_Conditional_1_Conditional_1_Template, 1, 4, "british-columbia-change-of-directors-preview-form", 1)
|
|
87418
|
+
\u0275\u0275template(0, BritishColumbiaComponent_Conditional_1_Conditional_0_Template, 1, 5, "british-columbia-change-of-directors-delta-form", 0)(1, BritishColumbiaComponent_Conditional_1_Conditional_1_Template, 1, 4, "british-columbia-change-of-directors-preview-form", 1);
|
|
87441
87419
|
}
|
|
87442
87420
|
if (rf & 2) {
|
|
87443
87421
|
const ctx_r1 = \u0275\u0275nextContext();
|
|
87444
87422
|
\u0275\u0275conditional(ctx_r1.activeStep() === ctx_r1.steps.Validate ? 0 : -1);
|
|
87445
87423
|
\u0275\u0275advance();
|
|
87446
87424
|
\u0275\u0275conditional(ctx_r1.activeStep() === ctx_r1.steps.FilingPreview ? 1 : -1);
|
|
87447
|
-
\u0275\u0275advance();
|
|
87448
|
-
\u0275\u0275conditional(ctx_r1.activeStep() === ctx_r1.steps.TermsAndConditions ? 2 : -1);
|
|
87449
87425
|
}
|
|
87450
87426
|
}
|
|
87451
87427
|
function BritishColumbiaComponent_Conditional_2_Conditional_0_Template(rf, ctx) {
|
|
87452
87428
|
if (rf & 1) {
|
|
87453
|
-
const
|
|
87454
|
-
\u0275\u0275elementStart(0, "british-columbia-incorporation-delta-form",
|
|
87429
|
+
const _r5 = \u0275\u0275getCurrentView();
|
|
87430
|
+
\u0275\u0275elementStart(0, "british-columbia-incorporation-delta-form", 6);
|
|
87455
87431
|
\u0275\u0275listener("validate", function BritishColumbiaComponent_Conditional_2_Conditional_0_Template_british_columbia_incorporation_delta_form_validate_0_listener() {
|
|
87456
|
-
\u0275\u0275restoreView(
|
|
87432
|
+
\u0275\u0275restoreView(_r5);
|
|
87457
87433
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87458
87434
|
return \u0275\u0275resetView(ctx_r1.onFormationValidate());
|
|
87459
87435
|
})("close", function BritishColumbiaComponent_Conditional_2_Conditional_0_Template_british_columbia_incorporation_delta_form_close_0_listener() {
|
|
87460
|
-
\u0275\u0275restoreView(
|
|
87436
|
+
\u0275\u0275restoreView(_r5);
|
|
87461
87437
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87462
87438
|
return \u0275\u0275resetView(ctx_r1.onClose());
|
|
87463
87439
|
})("save", function BritishColumbiaComponent_Conditional_2_Conditional_0_Template_british_columbia_incorporation_delta_form_save_0_listener() {
|
|
87464
|
-
\u0275\u0275restoreView(
|
|
87440
|
+
\u0275\u0275restoreView(_r5);
|
|
87465
87441
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87466
87442
|
return \u0275\u0275resetView(ctx_r1.onFormationSave());
|
|
87467
87443
|
});
|
|
@@ -87475,14 +87451,14 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87475
87451
|
}
|
|
87476
87452
|
function BritishColumbiaComponent_Conditional_2_Conditional_1_Template(rf, ctx) {
|
|
87477
87453
|
if (rf & 1) {
|
|
87478
|
-
const
|
|
87479
|
-
\u0275\u0275elementStart(0, "british-columbia-incorporation-preview-form",
|
|
87454
|
+
const _r6 = \u0275\u0275getCurrentView();
|
|
87455
|
+
\u0275\u0275elementStart(0, "british-columbia-incorporation-preview-form", 7);
|
|
87480
87456
|
\u0275\u0275listener("next", function BritishColumbiaComponent_Conditional_2_Conditional_1_Template_british_columbia_incorporation_preview_form_next_0_listener() {
|
|
87481
|
-
\u0275\u0275restoreView(
|
|
87457
|
+
\u0275\u0275restoreView(_r6);
|
|
87482
87458
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87483
87459
|
return \u0275\u0275resetView(ctx_r1.onFormationSubmit());
|
|
87484
87460
|
})("close", function BritishColumbiaComponent_Conditional_2_Conditional_1_Template_british_columbia_incorporation_preview_form_close_0_listener() {
|
|
87485
|
-
\u0275\u0275restoreView(
|
|
87461
|
+
\u0275\u0275restoreView(_r6);
|
|
87486
87462
|
const ctx_r1 = \u0275\u0275nextContext(2);
|
|
87487
87463
|
return \u0275\u0275resetView(ctx_r1.close.emit());
|
|
87488
87464
|
});
|
|
@@ -87496,7 +87472,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87496
87472
|
}
|
|
87497
87473
|
function BritishColumbiaComponent_Conditional_2_Template(rf, ctx) {
|
|
87498
87474
|
if (rf & 1) {
|
|
87499
|
-
\u0275\u0275template(0, BritishColumbiaComponent_Conditional_2_Conditional_0_Template, 1, 5, "british-columbia-incorporation-delta-form",
|
|
87475
|
+
\u0275\u0275template(0, BritishColumbiaComponent_Conditional_2_Conditional_0_Template, 1, 5, "british-columbia-incorporation-delta-form", 4)(1, BritishColumbiaComponent_Conditional_2_Conditional_1_Template, 1, 4, "british-columbia-incorporation-preview-form", 5);
|
|
87500
87476
|
}
|
|
87501
87477
|
if (rf & 2) {
|
|
87502
87478
|
const ctx_r1 = \u0275\u0275nextContext();
|
|
@@ -87520,7 +87496,6 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87520
87496
|
init_delta_state_service();
|
|
87521
87497
|
init_common_utils();
|
|
87522
87498
|
init_confirm_modal_component();
|
|
87523
|
-
init_terms_and_conditions_component();
|
|
87524
87499
|
init_change_of_directors_delta_form_component();
|
|
87525
87500
|
init_change_of_directors_preview_form_component();
|
|
87526
87501
|
init_british_columbia_incorporation_delta_form_component();
|
|
@@ -87595,11 +87570,8 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87595
87570
|
this.deltaState.setBCChangeOfDirectorsInitialDelta(delta);
|
|
87596
87571
|
this.saveCodDeltaData.emit(delta);
|
|
87597
87572
|
}
|
|
87598
|
-
onChangeOfDirectorsSubmit(
|
|
87599
|
-
this.codSubmit.emit(
|
|
87600
|
-
signatoryFirstName: termsAndConditions.firstName,
|
|
87601
|
-
signatoryLastName: termsAndConditions.lastName
|
|
87602
|
-
}));
|
|
87573
|
+
onChangeOfDirectorsSubmit() {
|
|
87574
|
+
this.codSubmit.emit();
|
|
87603
87575
|
}
|
|
87604
87576
|
onFormationValidate() {
|
|
87605
87577
|
markFormGroupTouched(this.deltaForm());
|
|
@@ -87710,24 +87682,23 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87710
87682
|
static \u0275fac = function BritishColumbiaComponent_Factory(__ngFactoryType__) {
|
|
87711
87683
|
return new (__ngFactoryType__ || _BritishColumbiaComponent)();
|
|
87712
87684
|
};
|
|
87713
|
-
static \u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _BritishColumbiaComponent, selectors: [["british-columbia"]], inputs: { task: [1, "task"], currentUser: [1, "currentUser"], activeStep: [1, "activeStep"], isNote: [1, "isNote"], actionsDisabled: [1, "actionsDisabled"], errors: [1, "errors"] }, outputs: { close: "close", codValidate: "codValidate", saveCodDeltaData: "saveCodDeltaData", codSubmit: "codSubmit", formationValidate: "formationValidate", formationSubmit: "formationSubmit", saveFormationDeltaData: "saveFormationDeltaData", nextStep: "nextStep", prevStep: "prevStep" }, decls: 3, vars: 3, consts: [[3, "task", "form", "actionsDisabled", "errors", "isNote"], [3, "task", "form", "actionsDisabled", "errors"], [3, "
|
|
87685
|
+
static \u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _BritishColumbiaComponent, selectors: [["british-columbia"]], inputs: { task: [1, "task"], currentUser: [1, "currentUser"], activeStep: [1, "activeStep"], isNote: [1, "isNote"], actionsDisabled: [1, "actionsDisabled"], errors: [1, "errors"] }, outputs: { close: "close", codValidate: "codValidate", saveCodDeltaData: "saveCodDeltaData", codSubmit: "codSubmit", formationValidate: "formationValidate", formationSubmit: "formationSubmit", saveFormationDeltaData: "saveFormationDeltaData", nextStep: "nextStep", prevStep: "prevStep" }, decls: 3, vars: 3, consts: [[3, "task", "form", "actionsDisabled", "errors", "isNote"], [3, "task", "form", "actionsDisabled", "errors"], [3, "validate", "close", "save", "task", "form", "actionsDisabled", "errors", "isNote"], [3, "close", "file", "task", "form", "actionsDisabled", "errors"], [3, "task", "errors", "isNote", "actionsDisabled", "form"], [3, "task", "form", "errors", "actionsDisabled"], [3, "validate", "close", "save", "task", "errors", "isNote", "actionsDisabled", "form"], [3, "next", "close", "task", "form", "errors", "actionsDisabled"]], template: function BritishColumbiaComponent_Template(rf, ctx) {
|
|
87714
87686
|
if (rf & 1) {
|
|
87715
87687
|
\u0275\u0275declareLet(0);
|
|
87716
|
-
\u0275\u0275template(1, BritishColumbiaComponent_Conditional_1_Template,
|
|
87688
|
+
\u0275\u0275template(1, BritishColumbiaComponent_Conditional_1_Template, 2, 2)(2, BritishColumbiaComponent_Conditional_2_Template, 2, 2);
|
|
87717
87689
|
}
|
|
87718
87690
|
if (rf & 2) {
|
|
87719
|
-
const
|
|
87691
|
+
const taskData_r7 = \u0275\u0275storeLet(ctx.task());
|
|
87720
87692
|
\u0275\u0275advance();
|
|
87721
|
-
\u0275\u0275conditional(ctx.isChangeOfDirectorsTask(
|
|
87693
|
+
\u0275\u0275conditional(ctx.isChangeOfDirectorsTask(taskData_r7) ? 1 : -1);
|
|
87722
87694
|
\u0275\u0275advance();
|
|
87723
|
-
\u0275\u0275conditional(ctx.isFormationTask(
|
|
87695
|
+
\u0275\u0275conditional(ctx.isFormationTask(taskData_r7) ? 2 : -1);
|
|
87724
87696
|
}
|
|
87725
87697
|
}, dependencies: [
|
|
87726
87698
|
BritishColumbiaChangeOfDirectorsDeltaFormComponent,
|
|
87727
87699
|
BritishColumbiaChangeOfDirectorsPreviewFormComponent,
|
|
87728
87700
|
BritishColumbiaIncorporationDeltaFormComponent,
|
|
87729
|
-
BritishColumbiaIncorporationPreviewFormComponent
|
|
87730
|
-
TermsAndConditionsComponent
|
|
87701
|
+
BritishColumbiaIncorporationPreviewFormComponent
|
|
87731
87702
|
], styles: ["\n\n[_nghost-%COMP%] {\n display: contents;\n}\n/*# sourceMappingURL=british-columbia.component.css.map */"], changeDetection: 0 });
|
|
87732
87703
|
};
|
|
87733
87704
|
(() => {
|
|
@@ -87737,13 +87708,12 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
87737
87708
|
BritishColumbiaChangeOfDirectorsDeltaFormComponent,
|
|
87738
87709
|
BritishColumbiaChangeOfDirectorsPreviewFormComponent,
|
|
87739
87710
|
BritishColumbiaIncorporationDeltaFormComponent,
|
|
87740
|
-
BritishColumbiaIncorporationPreviewFormComponent
|
|
87741
|
-
|
|
87742
|
-
], template: '@let taskData = this.task();\r\n\r\n@if (isChangeOfDirectorsTask(taskData)) {\r\n @if (activeStep() === steps.Validate) {\r\n <british-columbia-change-of-directors-delta-form\r\n [task]="taskData"\r\n [form]="deltaForm()"\r\n [actionsDisabled]="actionsDisabled()"\r\n [errors]="errors()"\r\n [isNote]="isNote()"\r\n (validate)="onChangeOfDirectorsValidate()"\r\n (close)="onClose()"\r\n (save)="onChangeOfDirectorsSave()"\r\n />\r\n }\r\n\r\n @if (activeStep() === steps.FilingPreview) {\r\n <british-columbia-change-of-directors-preview-form\r\n [task]="taskData"\r\n [form]="previewForm()"\r\n [actionsDisabled]="actionsDisabled()"\r\n [errors]="errors()"\r\n (close)="close.emit()"\r\n (file)="nextStep.emit()"\r\n />\r\n }\r\n\r\n @if (activeStep() === steps.TermsAndConditions) {\r\n <terms-and-conditions\r\n [errors]="errors()"\r\n (prev)="prevStep.emit()"\r\n (close)="close.emit()"\r\n (confirm)="onChangeOfDirectorsSubmit($event)"\r\n />\r\n }\r\n}\r\n\r\n@if (isFormationTask(taskData)) {\r\n @if (activeStep() === steps.Validate) {\r\n <british-columbia-incorporation-delta-form\r\n [task]="taskData"\r\n [errors]="errors()"\r\n [isNote]="isNote()"\r\n [actionsDisabled]="actionsDisabled()"\r\n [form]="deltaForm()"\r\n (validate)="onFormationValidate()"\r\n (close)="onClose()"\r\n (save)="onFormationSave()"\r\n />\r\n }\r\n\r\n @if (activeStep() === steps.FilingPreview) {\r\n <british-columbia-incorporation-preview-form\r\n [task]="taskData"\r\n [form]="previewForm()"\r\n [errors]="errors()"\r\n [actionsDisabled]="actionsDisabled()"\r\n (next)="onFormationSubmit()"\r\n (close)="close.emit()"\r\n />\r\n }\r\n}\r\n', styles: ["/* src/app/components/british-columbia/british-columbia.component.scss */\n:host {\n display: contents;\n}\n/*# sourceMappingURL=british-columbia.component.css.map */\n"] }]
|
|
87711
|
+
BritishColumbiaIncorporationPreviewFormComponent
|
|
87712
|
+
], template: '@let taskData = this.task();\r\n\r\n@if (isChangeOfDirectorsTask(taskData)) {\r\n @if (activeStep() === steps.Validate) {\r\n <british-columbia-change-of-directors-delta-form\r\n [task]="taskData"\r\n [form]="deltaForm()"\r\n [actionsDisabled]="actionsDisabled()"\r\n [errors]="errors()"\r\n [isNote]="isNote()"\r\n (validate)="onChangeOfDirectorsValidate()"\r\n (close)="onClose()"\r\n (save)="onChangeOfDirectorsSave()"\r\n />\r\n }\r\n\r\n @if (activeStep() === steps.FilingPreview) {\r\n <british-columbia-change-of-directors-preview-form\r\n [task]="taskData"\r\n [form]="previewForm()"\r\n [actionsDisabled]="actionsDisabled()"\r\n [errors]="errors()"\r\n (close)="close.emit()"\r\n (file)="onChangeOfDirectorsSubmit()"\r\n />\r\n }\r\n}\r\n\r\n@if (isFormationTask(taskData)) {\r\n @if (activeStep() === steps.Validate) {\r\n <british-columbia-incorporation-delta-form\r\n [task]="taskData"\r\n [errors]="errors()"\r\n [isNote]="isNote()"\r\n [actionsDisabled]="actionsDisabled()"\r\n [form]="deltaForm()"\r\n (validate)="onFormationValidate()"\r\n (close)="onClose()"\r\n (save)="onFormationSave()"\r\n />\r\n }\r\n\r\n @if (activeStep() === steps.FilingPreview) {\r\n <british-columbia-incorporation-preview-form\r\n [task]="taskData"\r\n [form]="previewForm()"\r\n [errors]="errors()"\r\n [actionsDisabled]="actionsDisabled()"\r\n (next)="onFormationSubmit()"\r\n (close)="close.emit()"\r\n />\r\n }\r\n}\r\n', styles: ["/* src/app/components/british-columbia/british-columbia.component.scss */\n:host {\n display: contents;\n}\n/*# sourceMappingURL=british-columbia.component.css.map */\n"] }]
|
|
87743
87713
|
}], () => [], null);
|
|
87744
87714
|
})();
|
|
87745
87715
|
(() => {
|
|
87746
|
-
(typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(BritishColumbiaComponent, { className: "BritishColumbiaComponent", filePath: "src/app/components/british-columbia/british-columbia.component.ts", lineNumber:
|
|
87716
|
+
(typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(BritishColumbiaComponent, { className: "BritishColumbiaComponent", filePath: "src/app/components/british-columbia/british-columbia.component.ts", lineNumber: 62 });
|
|
87747
87717
|
})();
|
|
87748
87718
|
}
|
|
87749
87719
|
});
|
|
@@ -93967,6 +93937,47 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
93967
93937
|
setConfig(config2) {
|
|
93968
93938
|
this.config = config2;
|
|
93969
93939
|
}
|
|
93940
|
+
/**
|
|
93941
|
+
* Orders the corporation's current data extract and waits until it is ready, returning the
|
|
93942
|
+
* `currentDataServiceOrderId` that Validate Filing needs. The registry bot can take a while,
|
|
93943
|
+
* so the extract is polled every `intervalMs` for up to `maxAttempts` times.
|
|
93944
|
+
*/
|
|
93945
|
+
ensureCurrentDataExtract(_0, _1) {
|
|
93946
|
+
return __async(this, arguments, function* (signature, order, opts = {}, { intervalMs = 3e3, maxAttempts = 40 } = {}) {
|
|
93947
|
+
ensureAuthInputs(signature);
|
|
93948
|
+
const fetchFn = opts.fetchImpl ?? fetch;
|
|
93949
|
+
const dataExtractUrl = `${this.getOnbisOrigin()}/filings/ca/bc/data-extract`;
|
|
93950
|
+
const orderResp = yield fetchWithJwtRetry(signature, () => postJson(fetchFn, signature.proxyApiUrl, signature.jwtToken, order, __spreadValues({
|
|
93951
|
+
"x-target-url": `${dataExtractUrl}/order`
|
|
93952
|
+
}, opts.headers ?? {})));
|
|
93953
|
+
const ordered = yield this.readJson(orderResp, "BC current data extract order");
|
|
93954
|
+
const orderId = ordered.currentDataServiceOrderId;
|
|
93955
|
+
if (!orderResp.ok || !orderId || ordered.status === "failed") {
|
|
93956
|
+
throw buildGenericError(orderResp.status, "BC current data extract order failed", __spreadProps(__spreadValues({}, ordered), {
|
|
93957
|
+
errors: ordered.errors?.length ? ordered.errors : (ordered.additionalInformation ?? []).map((message) => ({ message }))
|
|
93958
|
+
}));
|
|
93959
|
+
}
|
|
93960
|
+
for (let attempt = 0; attempt < maxAttempts; attempt++) {
|
|
93961
|
+
const extractResp = yield fetchWithJwtRetry(signature, () => fetchFn(signature.proxyApiUrl, {
|
|
93962
|
+
method: "GET",
|
|
93963
|
+
headers: __spreadValues({
|
|
93964
|
+
Authorization: `Bearer ${signature.jwtToken}`,
|
|
93965
|
+
"x-target-url": `${dataExtractUrl}/${encodeURIComponent(orderId)}`
|
|
93966
|
+
}, opts.headers ?? {})
|
|
93967
|
+
}));
|
|
93968
|
+
const extract = yield this.readJson(extractResp, "BC current data extract");
|
|
93969
|
+
if (extractResp.ok && extract.status === "success") {
|
|
93970
|
+
return orderId;
|
|
93971
|
+
}
|
|
93972
|
+
if (!extractResp.ok || extract.status === "failed" || extract.status === "sourceUnavailable") {
|
|
93973
|
+
const reasons = extract.additionalInformation ?? [];
|
|
93974
|
+
throw new Error(`BC current data extract ${extract.status ?? "failed"} (HTTP ${extractResp.status})${reasons.length ? `: ${reasons.join(" | ")}` : "."}`);
|
|
93975
|
+
}
|
|
93976
|
+
yield new Promise((resolve) => setTimeout(resolve, intervalMs));
|
|
93977
|
+
}
|
|
93978
|
+
throw new Error("BC current data extract is still processing. Please try again in a moment.");
|
|
93979
|
+
});
|
|
93980
|
+
}
|
|
93970
93981
|
validate(_0, _1) {
|
|
93971
93982
|
return __async(this, arguments, function* (signature, requestBody, opts = {}) {
|
|
93972
93983
|
ensureAuthInputs(signature);
|
|
@@ -93984,8 +93995,12 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
93984
93995
|
throw err2;
|
|
93985
93996
|
}
|
|
93986
93997
|
const payload = unwrapRequestResults(parsed.value);
|
|
93987
|
-
if (resp.ok && !payload.Errors?.length) {
|
|
93988
|
-
return payload
|
|
93998
|
+
if (resp.ok && !payload.Errors?.length && !payload["errors"]?.length) {
|
|
93999
|
+
return __spreadProps(__spreadValues({}, payload), {
|
|
94000
|
+
Status: payload.Status ?? payload["status"],
|
|
94001
|
+
ServiceOrderId: payload.ServiceOrderId ?? payload["serviceOrderId"],
|
|
94002
|
+
Draft: payload.Draft ?? payload["draft"]
|
|
94003
|
+
});
|
|
93989
94004
|
}
|
|
93990
94005
|
const err = buildValidationError(resp.status, payload);
|
|
93991
94006
|
err.validateResult = payload;
|
|
@@ -94045,6 +94060,16 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94045
94060
|
throw err;
|
|
94046
94061
|
});
|
|
94047
94062
|
}
|
|
94063
|
+
readJson(resp, what) {
|
|
94064
|
+
return __async(this, null, function* () {
|
|
94065
|
+
const raw = yield resp.text();
|
|
94066
|
+
const parsed = tryParseJson(raw);
|
|
94067
|
+
if (!parsed.ok) {
|
|
94068
|
+
throw new Error(`${what} returned ${resp.status} ${resp.statusText}: ${raw || "(empty response)"}`);
|
|
94069
|
+
}
|
|
94070
|
+
return unwrapRequestResults(parsed.value);
|
|
94071
|
+
});
|
|
94072
|
+
}
|
|
94048
94073
|
getOnbisOrigin() {
|
|
94049
94074
|
const filingUrl = this.config?.BCFiling;
|
|
94050
94075
|
if (!filingUrl) {
|
|
@@ -94069,7 +94094,30 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94069
94094
|
});
|
|
94070
94095
|
|
|
94071
94096
|
// src/app/helpers/mappers/british-columbia-change-of-directors.mapper.ts
|
|
94072
|
-
function
|
|
94097
|
+
function getBritishColumbiaAccessCode(task) {
|
|
94098
|
+
return task.entity._profile.registry_id?.trim() ?? "";
|
|
94099
|
+
}
|
|
94100
|
+
function buildBritishColumbiaDataExtractOrder(task) {
|
|
94101
|
+
const incorporationDate = toYyyyMmDd(task.entity._compliance.incorporation_date) ?? "";
|
|
94102
|
+
const request = {
|
|
94103
|
+
corporationNumber: task.entity._profile.corp_number?.trim() ?? "",
|
|
94104
|
+
accessCodeOrPassword: getBritishColumbiaAccessCode(task),
|
|
94105
|
+
incorporationDate: /^\d{4}-\d{2}-\d{2}$/.test(incorporationDate) ? incorporationDate : "",
|
|
94106
|
+
filingType: "changeOfDirectorsFiling"
|
|
94107
|
+
};
|
|
94108
|
+
const issues = [];
|
|
94109
|
+
if (!request.corporationNumber) {
|
|
94110
|
+
issues.push("The corporation number is missing on the entity.");
|
|
94111
|
+
}
|
|
94112
|
+
if (!/^[A-Za-z0-9]+$/.test(request.accessCodeOrPassword)) {
|
|
94113
|
+
issues.push("The company's BC Online access code or password is missing or contains characters other than letters and numbers.");
|
|
94114
|
+
}
|
|
94115
|
+
if (!request.incorporationDate) {
|
|
94116
|
+
issues.push("The incorporation date is missing on the entity.");
|
|
94117
|
+
}
|
|
94118
|
+
return { request, issues };
|
|
94119
|
+
}
|
|
94120
|
+
function buildBritishColumbiaChangeOfDirectorsValidationRequest(task, deltaData, currentDataServiceOrderId) {
|
|
94073
94121
|
const source = task.changeDirectors ?? task.deltaData?.changeDirectors ?? task.deltaData?.validatedData?.ChangeDirectors ?? task.deltaData?.validatedData?.filing;
|
|
94074
94122
|
const incomingDirectors = (task.incomingAffiliations ?? []).filter(isDirectorAffiliation);
|
|
94075
94123
|
const outgoingDirectors = (task.outgoingAffiliations ?? []).filter(isDirectorAffiliation);
|
|
@@ -94077,25 +94125,32 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94077
94125
|
const ceasedDirectors = [...source?.CeasedDirectors ?? [], ...source?.CeaseDirector ?? [], ...source?.ceaseDirectors ?? []];
|
|
94078
94126
|
const editedDirectors = [...source?.EditedDirectors ?? [], ...source?.EditDirector ?? [], ...source?.editDirectors ?? []];
|
|
94079
94127
|
const companyEmail = findCompanyEmail(task);
|
|
94080
|
-
const
|
|
94081
|
-
|
|
94128
|
+
const addDirectors = (incomingDirectors.length ? incomingDirectors : addedDirectors).map((affiliation) => buildDirector(affiliation));
|
|
94129
|
+
const ceaseDirectors = (outgoingDirectors.length ? outgoingDirectors : ceasedDirectors).map((affiliation) => buildCeasedDirector(affiliation));
|
|
94130
|
+
return {
|
|
94082
94131
|
filingType: "changeOfDirectorsFiling",
|
|
94083
|
-
|
|
94132
|
+
currentDataServiceOrderId,
|
|
94133
|
+
filing: __spreadProps(__spreadValues({
|
|
94134
|
+
corporationNumber: task.entity._profile.corp_number ?? "",
|
|
94135
|
+
accessCodeOrPassword: getBritishColumbiaAccessCode(task),
|
|
94084
94136
|
reference: deltaData.referenceNumbers.referenceNumber ?? null,
|
|
94085
|
-
docket: deltaData.referenceNumbers.docketNumber ?? null
|
|
94086
|
-
|
|
94087
|
-
|
|
94088
|
-
|
|
94089
|
-
ceaseDirectors: (outgoingDirectors.length ? outgoingDirectors : ceasedDirectors).map((affiliation) => buildDirector(affiliation)),
|
|
94137
|
+
docket: deltaData.referenceNumbers.docketNumber ?? null
|
|
94138
|
+
}, addDirectors.length || ceaseDirectors.length ? { effectiveDate: toYyyyMmDd(deltaData.filingDetails.changeDate) ?? toYyyyMmDd(/* @__PURE__ */ new Date()) } : {}), {
|
|
94139
|
+
addDirectors,
|
|
94140
|
+
ceaseDirectors,
|
|
94090
94141
|
editDirectors: editedDirectors.length ? editedDirectors.map((director) => buildDirector(director)) : [],
|
|
94091
94142
|
companyEmail,
|
|
94092
94143
|
isAnnualReportReminderRequired: deltaData.annualReportReminder === BCAnnualReportReminder.Yes
|
|
94093
|
-
}
|
|
94094
|
-
}
|
|
94144
|
+
})
|
|
94145
|
+
};
|
|
94095
94146
|
}
|
|
94096
94147
|
function isDirectorAffiliation(affiliation) {
|
|
94097
94148
|
return isPrincipalAffiliation2(affiliation) && affiliation.role?.role_name === "Director";
|
|
94098
94149
|
}
|
|
94150
|
+
function buildCeasedDirector(affiliation) {
|
|
94151
|
+
const _a = buildDirector(affiliation), { isDeliveryAddressSameAsMailing: _omitted } = _a, director = __objRest(_a, ["isDeliveryAddressSameAsMailing"]);
|
|
94152
|
+
return __spreadProps(__spreadValues({}, director), { deliveryAddress: director.deliveryAddress ?? director.mailingAddress });
|
|
94153
|
+
}
|
|
94099
94154
|
function buildDirector(affiliation) {
|
|
94100
94155
|
if (affiliation?.PersonName || affiliation?.personName || affiliation?.firstName || affiliation?.FirstName) {
|
|
94101
94156
|
const name = affiliation.PersonName ?? affiliation.personName ?? affiliation;
|
|
@@ -94104,7 +94159,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94104
94159
|
middleName: name.MiddleName ?? name.middleName ?? "",
|
|
94105
94160
|
lastName: name.LastName ?? name.lastName ?? "",
|
|
94106
94161
|
mailingAddress: affiliation.mailingAddress ?? affiliation.MailingAddress,
|
|
94107
|
-
deliveryAddress: affiliation.deliveryAddress ?? affiliation.DeliveryAddress,
|
|
94162
|
+
deliveryAddress: affiliation.isDeliveryAddressSameAsMailing ? void 0 : affiliation.deliveryAddress ?? affiliation.DeliveryAddress,
|
|
94108
94163
|
isDeliveryAddressSameAsMailing: affiliation.isDeliveryAddressSameAsMailing
|
|
94109
94164
|
};
|
|
94110
94165
|
}
|
|
@@ -94112,38 +94167,19 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94112
94167
|
const addresses = getAffiliationAddresses(affiliation);
|
|
94113
94168
|
const mailingAddress = mapAddress4(BritishColumbiaFormationFormHelper.pickAddress(addresses, "Mailing"));
|
|
94114
94169
|
const deliveryAddress = mapAddress4(BritishColumbiaFormationFormHelper.pickAddress(addresses, "Delivery"));
|
|
94170
|
+
const isSameAsMailing = isDeliveryAddressSameAsMailing(addresses);
|
|
94115
94171
|
return {
|
|
94116
94172
|
firstName: profile.firstName ?? "",
|
|
94117
94173
|
middleName: profile.middleName ?? "",
|
|
94118
94174
|
lastName: profile.lastName ?? "",
|
|
94119
94175
|
mailingAddress,
|
|
94120
|
-
|
|
94121
|
-
|
|
94176
|
+
// The API rejects a delivery address when it is the same as the mailing address.
|
|
94177
|
+
deliveryAddress: isSameAsMailing ? void 0 : deliveryAddress,
|
|
94178
|
+
isDeliveryAddressSameAsMailing: isSameAsMailing
|
|
94122
94179
|
};
|
|
94123
94180
|
}
|
|
94124
94181
|
function mapAddress4(address) {
|
|
94125
|
-
|
|
94126
|
-
return void 0;
|
|
94127
|
-
const raw = address;
|
|
94128
|
-
const postalAddress = raw.PostalAddress ?? raw.postalAddress;
|
|
94129
|
-
const source = postalAddress?.AddressCA ?? postalAddress?.AddressUS ?? postalAddress?.AddressINTL ?? raw;
|
|
94130
|
-
const streetNumber = address.components?.find((component) => component.name === "Street Number Only")?.value;
|
|
94131
|
-
const streetName = address.components?.find((component) => component.name === "Street Only")?.value;
|
|
94132
|
-
const suite = address.components?.find((component) => component.name === "Suite/Apartment")?.value;
|
|
94133
|
-
const streetAddress = [streetNumber, streetName].filter(Boolean).join(" ") || address.components?.find((component) => component.name === "Street Address")?.value || source.streetAddress || source.Address1 || raw.street || "";
|
|
94134
|
-
const country = source.country ?? source.CountryCodeName ?? raw.country ?? "";
|
|
94135
|
-
const postal = source.postalOrZipCode ?? source.PostCode ?? source.postalZip ?? raw.postal_zip ?? "";
|
|
94136
|
-
return {
|
|
94137
|
-
streetAddress: [streetAddress, suite].filter(Boolean).join(", "),
|
|
94138
|
-
city: source.city ?? source.CityTown ?? raw.city ?? "",
|
|
94139
|
-
provinceState: source.provinceState ?? source.RegionName ?? raw.province_state ?? "",
|
|
94140
|
-
country,
|
|
94141
|
-
postalOrZipCode: country === "CA" ? normalizeCanadianPostal(postal) : postal
|
|
94142
|
-
};
|
|
94143
|
-
}
|
|
94144
|
-
function normalizeCanadianPostal(value) {
|
|
94145
|
-
const compact = value.replace(/[\s-]+/g, "").toUpperCase();
|
|
94146
|
-
return /^[A-Z]\d[A-Z]\d[A-Z]\d$/.test(compact) ? `${compact.slice(0, 3)} ${compact.slice(3)}` : value;
|
|
94182
|
+
return address ? mapAddress(address) : void 0;
|
|
94147
94183
|
}
|
|
94148
94184
|
function findCompanyEmail(task) {
|
|
94149
94185
|
const affiliations = task.entity.affiliations ?? [];
|
|
@@ -94162,6 +94198,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94162
94198
|
"src/app/helpers/mappers/british-columbia-change-of-directors.mapper.ts"() {
|
|
94163
94199
|
init_BritishColumbiaConstants();
|
|
94164
94200
|
init_common_models();
|
|
94201
|
+
init_british_columbia_formation_mapper();
|
|
94165
94202
|
init_british_columbia_formation_form_helper();
|
|
94166
94203
|
init_common_utils();
|
|
94167
94204
|
}
|
|
@@ -94638,8 +94675,15 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94638
94675
|
try {
|
|
94639
94676
|
this.isLoading.set(true);
|
|
94640
94677
|
this.errors.set([]);
|
|
94641
|
-
const
|
|
94642
|
-
const
|
|
94678
|
+
const options = this.validateOptions() ?? {};
|
|
94679
|
+
const { request: extractOrder, issues } = buildBritishColumbiaDataExtractOrder(task);
|
|
94680
|
+
if (issues.length) {
|
|
94681
|
+
this.errors.set(issues);
|
|
94682
|
+
return;
|
|
94683
|
+
}
|
|
94684
|
+
const currentDataServiceOrderId = yield this.britishColumbiaChangeOfDirectorsService.ensureCurrentDataExtract(signature, extractOrder, options);
|
|
94685
|
+
const requestBody = buildBritishColumbiaChangeOfDirectorsValidationRequest(task, deltaData, currentDataServiceOrderId);
|
|
94686
|
+
const response = yield this.britishColumbiaChangeOfDirectorsService.validate(signature, requestBody, options);
|
|
94643
94687
|
if (this.hasResponseErrors(response))
|
|
94644
94688
|
return;
|
|
94645
94689
|
const serviceOrderId = response.ServiceOrderId ?? "";
|
|
@@ -94648,7 +94692,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
94648
94692
|
searchOrFilingType: getSearchOrFilingType(task),
|
|
94649
94693
|
serviceOrderId,
|
|
94650
94694
|
validatedOn: /* @__PURE__ */ new Date(),
|
|
94651
|
-
provider: "
|
|
94695
|
+
provider: "bcreg",
|
|
94652
94696
|
draftPdf: response.Draft,
|
|
94653
94697
|
documentName: this.validateOptions()?.documentName ?? "BC Change of Directors Draft",
|
|
94654
94698
|
documentType: "pdf"
|
|
@@ -95327,7 +95371,7 @@ Note: Recommended intrinsic image size is calculated assuming a maximum DPR of $
|
|
|
95327
95371
|
}], () => [], null);
|
|
95328
95372
|
})();
|
|
95329
95373
|
(() => {
|
|
95330
|
-
(typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(FilingComponent, { className: "FilingComponent", filePath: "src/app/components/filing/filing.component.ts", lineNumber:
|
|
95374
|
+
(typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(FilingComponent, { className: "FilingComponent", filePath: "src/app/components/filing/filing.component.ts", lineNumber: 89 });
|
|
95331
95375
|
})();
|
|
95332
95376
|
}
|
|
95333
95377
|
});
|