@finsys/core 2.3.1 → 2.5.0
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/data/form-field-base-specs.json +0 -20
- package/dist/index.cjs +61 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +55 -1
- package/dist/index.d.ts +55 -1
- package/dist/index.js +54 -20
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -469,6 +469,60 @@ declare enum ExtractionFileType {
|
|
|
469
469
|
Ic = "ic"
|
|
470
470
|
}
|
|
471
471
|
|
|
472
|
+
/**
|
|
473
|
+
* IHS application status — canonical source of truth, mirroring finsys-api's
|
|
474
|
+
* `IHS_STATUS` enum and `allowedIhsStatus` list in src/utils/appHelper.ts.
|
|
475
|
+
*
|
|
476
|
+
* finsys-api originates these values (it writes them to the `ihs.status`
|
|
477
|
+
* column). Consumer apps (finhub-adonisjs, finsys-client) read them off the
|
|
478
|
+
* wire and use them for validation and display.
|
|
479
|
+
*
|
|
480
|
+
* Lender rejection is not represented by a distinct status: when a lender
|
|
481
|
+
* rejects an application, finsys-api transitions the record back to
|
|
482
|
+
* `APPLICATION_FINALIZED` from `LENDER_EVALUATION`.
|
|
483
|
+
*/
|
|
484
|
+
declare enum IhsStatus {
|
|
485
|
+
CreatingApplication = "CREATING_APPLICATION",
|
|
486
|
+
ApplicationFinalized = "APPLICATION_FINALIZED",
|
|
487
|
+
LenderEvaluation = "LENDER_EVALUATION",
|
|
488
|
+
Approved = "APPROVED",
|
|
489
|
+
LouDelivered = "LOU_DELIVERED",
|
|
490
|
+
AwaitingDisbursement = "AWAITING_DISBURSEMENT",
|
|
491
|
+
Disbursement = "DISBURSEMENT",
|
|
492
|
+
Declined = "DECLINED",
|
|
493
|
+
Expired = "EXPIRED",
|
|
494
|
+
Canceled = "CANCELED"
|
|
495
|
+
}
|
|
496
|
+
/**
|
|
497
|
+
* All valid IHS status values, in display order (earliest lifecycle stage
|
|
498
|
+
* first, terminal states last).
|
|
499
|
+
*/
|
|
500
|
+
declare const IHS_VALID_STATUSES: readonly IhsStatus[];
|
|
501
|
+
/**
|
|
502
|
+
* Terminal statuses — the application lifecycle has completed and no further
|
|
503
|
+
* transitions are expected. Useful for suppressing action UI (e.g. re-extract,
|
|
504
|
+
* status update controls) on the application detail view.
|
|
505
|
+
*/
|
|
506
|
+
declare const IHS_TERMINAL_STATUSES: readonly IhsStatus[];
|
|
507
|
+
/**
|
|
508
|
+
* Failure statuses — a subset of terminal statuses that represent an
|
|
509
|
+
* unsuccessful outcome. Useful for badge colour / messaging.
|
|
510
|
+
*/
|
|
511
|
+
declare const IHS_FAILURE_STATUSES: readonly IhsStatus[];
|
|
512
|
+
/**
|
|
513
|
+
* Type guard: narrows an unknown value to `IhsStatus` iff it is one of the
|
|
514
|
+
* canonical status strings.
|
|
515
|
+
*/
|
|
516
|
+
declare function isValidIhsStatus(status: unknown): status is IhsStatus;
|
|
517
|
+
/**
|
|
518
|
+
* Type guard: terminal (no further transitions expected).
|
|
519
|
+
*/
|
|
520
|
+
declare function isTerminalIhsStatus(status: unknown): status is IhsStatus;
|
|
521
|
+
/**
|
|
522
|
+
* Type guard: terminal and unsuccessful.
|
|
523
|
+
*/
|
|
524
|
+
declare function isFailureIhsStatus(status: unknown): status is IhsStatus;
|
|
525
|
+
|
|
472
526
|
declare enum DocExtractionStatus {
|
|
473
527
|
NotUploaded = "not_uploaded",
|
|
474
528
|
Uploaded = "uploaded",
|
|
@@ -516,4 +570,4 @@ interface ExtractionStatusResult {
|
|
|
516
570
|
*/
|
|
517
571
|
declare function resolveExtractionStatus(ihsRecord: Record<string, unknown>, jobRecords?: ExtractionJobRecord[]): ExtractionStatusResult;
|
|
518
572
|
|
|
519
|
-
export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DocExtractionResult, DocExtractionStatus, type DropdownOption, type EditorValidator, ExtractionFileType, type ExtractionJobRecord, ExtractionJobStatus, type ExtractionStatusResult, FIELD_TYPE_DEFINITIONS, type FieldData, type FieldGroup, type FieldReference, FieldType, type FileFieldTableData, type FileFieldTableItem, FileFieldTableType, FileFormField, FormField, FormFieldCategory, type FormFieldInputType, type FormFieldType, type FormFieldTypeDefinitions, FormFieldValidator, FormSpec, type FormValidatorDefinitions, type IhsDetailCategory, type IhsFieldDetail, IhsValueFormat, type PageConfig, type RHFSchemaOutput, type RHFStep, type ResolvedField, Role, type SurveyElementJSON, type SurveyJSON, type SurveyPageJSON, type UnifiedFormConfig, type Validator, applyDynamicTitles, buildFileFieldTables, evaluateExpression, extractTimePeriods, generateRHFSchema, generateSurveyJson, getBaseCategories, getBaseFieldNames, getBaseFieldSpecMap, getBaseFieldSpecs, getCategoryName, getDisplayName, getDisplayNames, getGroupDisplayNames, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, processIhsDetails, resolveExtractionStatus, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
|
|
573
|
+
export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DocExtractionResult, DocExtractionStatus, type DropdownOption, type EditorValidator, ExtractionFileType, type ExtractionJobRecord, ExtractionJobStatus, type ExtractionStatusResult, FIELD_TYPE_DEFINITIONS, type FieldData, type FieldGroup, type FieldReference, FieldType, type FileFieldTableData, type FileFieldTableItem, FileFieldTableType, FileFormField, FormField, FormFieldCategory, type FormFieldInputType, type FormFieldType, type FormFieldTypeDefinitions, FormFieldValidator, FormSpec, type FormValidatorDefinitions, IHS_FAILURE_STATUSES, IHS_TERMINAL_STATUSES, IHS_VALID_STATUSES, type IhsDetailCategory, type IhsFieldDetail, IhsStatus, IhsValueFormat, type PageConfig, type RHFSchemaOutput, type RHFStep, type ResolvedField, Role, type SurveyElementJSON, type SurveyJSON, type SurveyPageJSON, type UnifiedFormConfig, type Validator, applyDynamicTitles, buildFileFieldTables, evaluateExpression, extractTimePeriods, generateRHFSchema, generateSurveyJson, getBaseCategories, getBaseFieldNames, getBaseFieldSpecMap, getBaseFieldSpecs, getCategoryName, getDisplayName, getDisplayNames, getGroupDisplayNames, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, isFailureIhsStatus, isTerminalIhsStatus, isValidIhsStatus, processIhsDetails, resolveExtractionStatus, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
|
package/dist/index.d.ts
CHANGED
|
@@ -469,6 +469,60 @@ declare enum ExtractionFileType {
|
|
|
469
469
|
Ic = "ic"
|
|
470
470
|
}
|
|
471
471
|
|
|
472
|
+
/**
|
|
473
|
+
* IHS application status — canonical source of truth, mirroring finsys-api's
|
|
474
|
+
* `IHS_STATUS` enum and `allowedIhsStatus` list in src/utils/appHelper.ts.
|
|
475
|
+
*
|
|
476
|
+
* finsys-api originates these values (it writes them to the `ihs.status`
|
|
477
|
+
* column). Consumer apps (finhub-adonisjs, finsys-client) read them off the
|
|
478
|
+
* wire and use them for validation and display.
|
|
479
|
+
*
|
|
480
|
+
* Lender rejection is not represented by a distinct status: when a lender
|
|
481
|
+
* rejects an application, finsys-api transitions the record back to
|
|
482
|
+
* `APPLICATION_FINALIZED` from `LENDER_EVALUATION`.
|
|
483
|
+
*/
|
|
484
|
+
declare enum IhsStatus {
|
|
485
|
+
CreatingApplication = "CREATING_APPLICATION",
|
|
486
|
+
ApplicationFinalized = "APPLICATION_FINALIZED",
|
|
487
|
+
LenderEvaluation = "LENDER_EVALUATION",
|
|
488
|
+
Approved = "APPROVED",
|
|
489
|
+
LouDelivered = "LOU_DELIVERED",
|
|
490
|
+
AwaitingDisbursement = "AWAITING_DISBURSEMENT",
|
|
491
|
+
Disbursement = "DISBURSEMENT",
|
|
492
|
+
Declined = "DECLINED",
|
|
493
|
+
Expired = "EXPIRED",
|
|
494
|
+
Canceled = "CANCELED"
|
|
495
|
+
}
|
|
496
|
+
/**
|
|
497
|
+
* All valid IHS status values, in display order (earliest lifecycle stage
|
|
498
|
+
* first, terminal states last).
|
|
499
|
+
*/
|
|
500
|
+
declare const IHS_VALID_STATUSES: readonly IhsStatus[];
|
|
501
|
+
/**
|
|
502
|
+
* Terminal statuses — the application lifecycle has completed and no further
|
|
503
|
+
* transitions are expected. Useful for suppressing action UI (e.g. re-extract,
|
|
504
|
+
* status update controls) on the application detail view.
|
|
505
|
+
*/
|
|
506
|
+
declare const IHS_TERMINAL_STATUSES: readonly IhsStatus[];
|
|
507
|
+
/**
|
|
508
|
+
* Failure statuses — a subset of terminal statuses that represent an
|
|
509
|
+
* unsuccessful outcome. Useful for badge colour / messaging.
|
|
510
|
+
*/
|
|
511
|
+
declare const IHS_FAILURE_STATUSES: readonly IhsStatus[];
|
|
512
|
+
/**
|
|
513
|
+
* Type guard: narrows an unknown value to `IhsStatus` iff it is one of the
|
|
514
|
+
* canonical status strings.
|
|
515
|
+
*/
|
|
516
|
+
declare function isValidIhsStatus(status: unknown): status is IhsStatus;
|
|
517
|
+
/**
|
|
518
|
+
* Type guard: terminal (no further transitions expected).
|
|
519
|
+
*/
|
|
520
|
+
declare function isTerminalIhsStatus(status: unknown): status is IhsStatus;
|
|
521
|
+
/**
|
|
522
|
+
* Type guard: terminal and unsuccessful.
|
|
523
|
+
*/
|
|
524
|
+
declare function isFailureIhsStatus(status: unknown): status is IhsStatus;
|
|
525
|
+
|
|
472
526
|
declare enum DocExtractionStatus {
|
|
473
527
|
NotUploaded = "not_uploaded",
|
|
474
528
|
Uploaded = "uploaded",
|
|
@@ -516,4 +570,4 @@ interface ExtractionStatusResult {
|
|
|
516
570
|
*/
|
|
517
571
|
declare function resolveExtractionStatus(ihsRecord: Record<string, unknown>, jobRecords?: ExtractionJobRecord[]): ExtractionStatusResult;
|
|
518
572
|
|
|
519
|
-
export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DocExtractionResult, DocExtractionStatus, type DropdownOption, type EditorValidator, ExtractionFileType, type ExtractionJobRecord, ExtractionJobStatus, type ExtractionStatusResult, FIELD_TYPE_DEFINITIONS, type FieldData, type FieldGroup, type FieldReference, FieldType, type FileFieldTableData, type FileFieldTableItem, FileFieldTableType, FileFormField, FormField, FormFieldCategory, type FormFieldInputType, type FormFieldType, type FormFieldTypeDefinitions, FormFieldValidator, FormSpec, type FormValidatorDefinitions, type IhsDetailCategory, type IhsFieldDetail, IhsValueFormat, type PageConfig, type RHFSchemaOutput, type RHFStep, type ResolvedField, Role, type SurveyElementJSON, type SurveyJSON, type SurveyPageJSON, type UnifiedFormConfig, type Validator, applyDynamicTitles, buildFileFieldTables, evaluateExpression, extractTimePeriods, generateRHFSchema, generateSurveyJson, getBaseCategories, getBaseFieldNames, getBaseFieldSpecMap, getBaseFieldSpecs, getCategoryName, getDisplayName, getDisplayNames, getGroupDisplayNames, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, processIhsDetails, resolveExtractionStatus, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
|
|
573
|
+
export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DocExtractionResult, DocExtractionStatus, type DropdownOption, type EditorValidator, ExtractionFileType, type ExtractionJobRecord, ExtractionJobStatus, type ExtractionStatusResult, FIELD_TYPE_DEFINITIONS, type FieldData, type FieldGroup, type FieldReference, FieldType, type FileFieldTableData, type FileFieldTableItem, FileFieldTableType, FileFormField, FormField, FormFieldCategory, type FormFieldInputType, type FormFieldType, type FormFieldTypeDefinitions, FormFieldValidator, FormSpec, type FormValidatorDefinitions, IHS_FAILURE_STATUSES, IHS_TERMINAL_STATUSES, IHS_VALID_STATUSES, type IhsDetailCategory, type IhsFieldDetail, IhsStatus, IhsValueFormat, type PageConfig, type RHFSchemaOutput, type RHFStep, type ResolvedField, Role, type SurveyElementJSON, type SurveyJSON, type SurveyPageJSON, type UnifiedFormConfig, type Validator, applyDynamicTitles, buildFileFieldTables, evaluateExpression, extractTimePeriods, generateRHFSchema, generateSurveyJson, getBaseCategories, getBaseFieldNames, getBaseFieldSpecMap, getBaseFieldSpecs, getCategoryName, getDisplayName, getDisplayNames, getGroupDisplayNames, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, isFailureIhsStatus, isTerminalIhsStatus, isValidIhsStatus, processIhsDetails, resolveExtractionStatus, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
|
package/dist/index.js
CHANGED
|
@@ -7888,7 +7888,6 @@ var form_field_base_specs_default = {
|
|
|
7888
7888
|
name: "bank_statement_t1",
|
|
7889
7889
|
displayName: "Bank Statement (Month T-1)",
|
|
7890
7890
|
type: "file",
|
|
7891
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7892
7891
|
ihs_column_names: [
|
|
7893
7892
|
"accountHolderNameT1",
|
|
7894
7893
|
"statementDateT1",
|
|
@@ -7905,7 +7904,6 @@ var form_field_base_specs_default = {
|
|
|
7905
7904
|
name: "bank_statement_t2",
|
|
7906
7905
|
displayName: "Bank Statement (Month T-2)",
|
|
7907
7906
|
type: "file",
|
|
7908
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7909
7907
|
ihs_column_names: [
|
|
7910
7908
|
"accountHolderNameT2",
|
|
7911
7909
|
"statementDateT2",
|
|
@@ -7922,7 +7920,6 @@ var form_field_base_specs_default = {
|
|
|
7922
7920
|
name: "bank_statement_t3",
|
|
7923
7921
|
displayName: "Bank Statement (Month T-3)",
|
|
7924
7922
|
type: "file",
|
|
7925
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7926
7923
|
ihs_column_names: [
|
|
7927
7924
|
"accountHolderNameT3",
|
|
7928
7925
|
"statementDateT3",
|
|
@@ -7939,7 +7936,6 @@ var form_field_base_specs_default = {
|
|
|
7939
7936
|
name: "bank_statement_t4",
|
|
7940
7937
|
displayName: "Bank Statement (Month T-4)",
|
|
7941
7938
|
type: "file",
|
|
7942
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7943
7939
|
ihs_column_names: [
|
|
7944
7940
|
"accountHolderNameT4",
|
|
7945
7941
|
"statementDateT4",
|
|
@@ -7956,7 +7952,6 @@ var form_field_base_specs_default = {
|
|
|
7956
7952
|
name: "bank_statement_t5",
|
|
7957
7953
|
displayName: "Bank Statement (Month T-5)",
|
|
7958
7954
|
type: "file",
|
|
7959
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7960
7955
|
ihs_column_names: [
|
|
7961
7956
|
"accountHolderNameT5",
|
|
7962
7957
|
"statementDateT5",
|
|
@@ -7973,7 +7968,6 @@ var form_field_base_specs_default = {
|
|
|
7973
7968
|
name: "bank_statement_t6",
|
|
7974
7969
|
displayName: "Bank Statement (Month T-6)",
|
|
7975
7970
|
type: "file",
|
|
7976
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7977
7971
|
ihs_column_names: [
|
|
7978
7972
|
"accountHolderNameT6",
|
|
7979
7973
|
"statementDateT6",
|
|
@@ -7990,7 +7984,6 @@ var form_field_base_specs_default = {
|
|
|
7990
7984
|
name: "financials",
|
|
7991
7985
|
displayName: "Audited Financial Statement",
|
|
7992
7986
|
type: "file",
|
|
7993
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
7994
7987
|
ihs_column_names: [
|
|
7995
7988
|
"shareCapital",
|
|
7996
7989
|
"totalEquityT1",
|
|
@@ -8012,7 +8005,6 @@ var form_field_base_specs_default = {
|
|
|
8012
8005
|
name: "financials_fincap_t1",
|
|
8013
8006
|
displayName: "Audited Financial Statement (T-1) (FinCap)",
|
|
8014
8007
|
type: "file",
|
|
8015
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8016
8008
|
ihs_column_names: [
|
|
8017
8009
|
"nonCurrentAssetsSubsidiaryCompaniesT1",
|
|
8018
8010
|
"nonCurrentAssetsAssociatedCompaniesT1",
|
|
@@ -8257,7 +8249,6 @@ var form_field_base_specs_default = {
|
|
|
8257
8249
|
name: "financials_fincap_t2",
|
|
8258
8250
|
displayName: "Audited Financial Statement (T-2) (FinCap)",
|
|
8259
8251
|
type: "file",
|
|
8260
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8261
8252
|
ihs_column_names: [
|
|
8262
8253
|
"nonCurrentAssetsSubsidiaryCompaniesT3",
|
|
8263
8254
|
"nonCurrentAssetsAssociatedCompaniesT3",
|
|
@@ -8384,7 +8375,6 @@ var form_field_base_specs_default = {
|
|
|
8384
8375
|
name: "form9",
|
|
8385
8376
|
displayName: "Form 9 / Section 17 / Form D",
|
|
8386
8377
|
type: "file",
|
|
8387
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8388
8378
|
ihs_column_names: [
|
|
8389
8379
|
"incorporatedDate",
|
|
8390
8380
|
"companyName",
|
|
@@ -8396,7 +8386,6 @@ var form_field_base_specs_default = {
|
|
|
8396
8386
|
name: "ssm",
|
|
8397
8387
|
displayName: "SSM Company Profile",
|
|
8398
8388
|
type: "file",
|
|
8399
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8400
8389
|
ihs_column_names: [
|
|
8401
8390
|
"ssmCompanyName",
|
|
8402
8391
|
"ssmCompanyRegNo",
|
|
@@ -8421,7 +8410,6 @@ var form_field_base_specs_default = {
|
|
|
8421
8410
|
name: "ic",
|
|
8422
8411
|
displayName: "Identification Card (Front)",
|
|
8423
8412
|
type: "file",
|
|
8424
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8425
8413
|
ihs_column_names: [
|
|
8426
8414
|
"icNumber",
|
|
8427
8415
|
"icName",
|
|
@@ -8439,7 +8427,6 @@ var form_field_base_specs_default = {
|
|
|
8439
8427
|
name: "epf_statement_t1",
|
|
8440
8428
|
displayName: "Employees' Provident Fund (T-1)",
|
|
8441
8429
|
type: "file",
|
|
8442
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8443
8430
|
ihs_column_names: [
|
|
8444
8431
|
"epfAccountHolderNameT1",
|
|
8445
8432
|
"epfAccountHolderAddressT1",
|
|
@@ -8457,7 +8444,6 @@ var form_field_base_specs_default = {
|
|
|
8457
8444
|
name: "epf_statement_t2",
|
|
8458
8445
|
displayName: "Employees' Provident Fund (T-2)",
|
|
8459
8446
|
type: "file",
|
|
8460
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8461
8447
|
ihs_column_names: [
|
|
8462
8448
|
"epfAccountHolderNameT2",
|
|
8463
8449
|
"epfAccountHolderAddressT2",
|
|
@@ -8475,7 +8461,6 @@ var form_field_base_specs_default = {
|
|
|
8475
8461
|
name: "payslip_statement_t1",
|
|
8476
8462
|
displayName: "Payslip Statement (Month T-1)",
|
|
8477
8463
|
type: "file",
|
|
8478
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8479
8464
|
ihs_column_names: [
|
|
8480
8465
|
"payslipEmployerNameT1",
|
|
8481
8466
|
"payslipEmployeeNameT1",
|
|
@@ -8499,7 +8484,6 @@ var form_field_base_specs_default = {
|
|
|
8499
8484
|
name: "payslip_statement_t2",
|
|
8500
8485
|
displayName: "Payslip Statement (Month T-2)",
|
|
8501
8486
|
type: "file",
|
|
8502
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8503
8487
|
ihs_column_names: [
|
|
8504
8488
|
"payslipEmployerNameT2",
|
|
8505
8489
|
"payslipEmployeeNameT2",
|
|
@@ -8523,7 +8507,6 @@ var form_field_base_specs_default = {
|
|
|
8523
8507
|
name: "payslip_statement_t3",
|
|
8524
8508
|
displayName: "Payslip Statement (Month T-3)",
|
|
8525
8509
|
type: "file",
|
|
8526
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8527
8510
|
ihs_column_names: [
|
|
8528
8511
|
"payslipEmployerNameT3",
|
|
8529
8512
|
"payslipEmployeeNameT3",
|
|
@@ -8547,7 +8530,6 @@ var form_field_base_specs_default = {
|
|
|
8547
8530
|
name: "payslip_statement_t4",
|
|
8548
8531
|
displayName: "Payslip Statement (Month T-4)",
|
|
8549
8532
|
type: "file",
|
|
8550
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8551
8533
|
ihs_column_names: [
|
|
8552
8534
|
"payslipEmployerNameT4",
|
|
8553
8535
|
"payslipEmployeeNameT4",
|
|
@@ -8571,7 +8553,6 @@ var form_field_base_specs_default = {
|
|
|
8571
8553
|
name: "payslip_statement_t5",
|
|
8572
8554
|
displayName: "Payslip Statement (Month T-5)",
|
|
8573
8555
|
type: "file",
|
|
8574
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8575
8556
|
ihs_column_names: [
|
|
8576
8557
|
"payslipEmployerNameT5",
|
|
8577
8558
|
"payslipEmployeeNameT5",
|
|
@@ -8595,7 +8576,6 @@ var form_field_base_specs_default = {
|
|
|
8595
8576
|
name: "payslip_statement_t6",
|
|
8596
8577
|
displayName: "Payslip Statement (Month T-6)",
|
|
8597
8578
|
type: "file",
|
|
8598
|
-
enableIf: "{formOfDisclosure} contains 'consented'",
|
|
8599
8579
|
ihs_column_names: [
|
|
8600
8580
|
"payslipEmployerNameT6",
|
|
8601
8581
|
"payslipEmployeeNameT6",
|
|
@@ -9573,6 +9553,53 @@ var ExtractionFileType = /* @__PURE__ */ ((ExtractionFileType2) => {
|
|
|
9573
9553
|
return ExtractionFileType2;
|
|
9574
9554
|
})(ExtractionFileType || {});
|
|
9575
9555
|
|
|
9556
|
+
// src/ihs-status.ts
|
|
9557
|
+
var IhsStatus = /* @__PURE__ */ ((IhsStatus2) => {
|
|
9558
|
+
IhsStatus2["CreatingApplication"] = "CREATING_APPLICATION";
|
|
9559
|
+
IhsStatus2["ApplicationFinalized"] = "APPLICATION_FINALIZED";
|
|
9560
|
+
IhsStatus2["LenderEvaluation"] = "LENDER_EVALUATION";
|
|
9561
|
+
IhsStatus2["Approved"] = "APPROVED";
|
|
9562
|
+
IhsStatus2["LouDelivered"] = "LOU_DELIVERED";
|
|
9563
|
+
IhsStatus2["AwaitingDisbursement"] = "AWAITING_DISBURSEMENT";
|
|
9564
|
+
IhsStatus2["Disbursement"] = "DISBURSEMENT";
|
|
9565
|
+
IhsStatus2["Declined"] = "DECLINED";
|
|
9566
|
+
IhsStatus2["Expired"] = "EXPIRED";
|
|
9567
|
+
IhsStatus2["Canceled"] = "CANCELED";
|
|
9568
|
+
return IhsStatus2;
|
|
9569
|
+
})(IhsStatus || {});
|
|
9570
|
+
var IHS_VALID_STATUSES = [
|
|
9571
|
+
"CREATING_APPLICATION" /* CreatingApplication */,
|
|
9572
|
+
"APPLICATION_FINALIZED" /* ApplicationFinalized */,
|
|
9573
|
+
"LENDER_EVALUATION" /* LenderEvaluation */,
|
|
9574
|
+
"APPROVED" /* Approved */,
|
|
9575
|
+
"LOU_DELIVERED" /* LouDelivered */,
|
|
9576
|
+
"AWAITING_DISBURSEMENT" /* AwaitingDisbursement */,
|
|
9577
|
+
"DISBURSEMENT" /* Disbursement */,
|
|
9578
|
+
"DECLINED" /* Declined */,
|
|
9579
|
+
"EXPIRED" /* Expired */,
|
|
9580
|
+
"CANCELED" /* Canceled */
|
|
9581
|
+
];
|
|
9582
|
+
var IHS_TERMINAL_STATUSES = [
|
|
9583
|
+
"DISBURSEMENT" /* Disbursement */,
|
|
9584
|
+
"DECLINED" /* Declined */,
|
|
9585
|
+
"EXPIRED" /* Expired */,
|
|
9586
|
+
"CANCELED" /* Canceled */
|
|
9587
|
+
];
|
|
9588
|
+
var IHS_FAILURE_STATUSES = [
|
|
9589
|
+
"DECLINED" /* Declined */,
|
|
9590
|
+
"EXPIRED" /* Expired */,
|
|
9591
|
+
"CANCELED" /* Canceled */
|
|
9592
|
+
];
|
|
9593
|
+
function isValidIhsStatus(status) {
|
|
9594
|
+
return typeof status === "string" && IHS_VALID_STATUSES.includes(status);
|
|
9595
|
+
}
|
|
9596
|
+
function isTerminalIhsStatus(status) {
|
|
9597
|
+
return typeof status === "string" && IHS_TERMINAL_STATUSES.includes(status);
|
|
9598
|
+
}
|
|
9599
|
+
function isFailureIhsStatus(status) {
|
|
9600
|
+
return typeof status === "string" && IHS_FAILURE_STATUSES.includes(status);
|
|
9601
|
+
}
|
|
9602
|
+
|
|
9576
9603
|
// src/extraction-status.ts
|
|
9577
9604
|
var DocExtractionStatus = /* @__PURE__ */ ((DocExtractionStatus2) => {
|
|
9578
9605
|
DocExtractionStatus2["NotUploaded"] = "not_uploaded";
|
|
@@ -9738,6 +9765,10 @@ export {
|
|
|
9738
9765
|
FormFieldCategory,
|
|
9739
9766
|
FormFieldValidator,
|
|
9740
9767
|
FormSpec,
|
|
9768
|
+
IHS_FAILURE_STATUSES,
|
|
9769
|
+
IHS_TERMINAL_STATUSES,
|
|
9770
|
+
IHS_VALID_STATUSES,
|
|
9771
|
+
IhsStatus,
|
|
9741
9772
|
IhsValueFormat,
|
|
9742
9773
|
Role,
|
|
9743
9774
|
applyDynamicTitles,
|
|
@@ -9762,6 +9793,9 @@ export {
|
|
|
9762
9793
|
groupDetailsByCategory,
|
|
9763
9794
|
groupFieldsByCategory,
|
|
9764
9795
|
groupFieldsByPattern,
|
|
9796
|
+
isFailureIhsStatus,
|
|
9797
|
+
isTerminalIhsStatus,
|
|
9798
|
+
isValidIhsStatus,
|
|
9765
9799
|
processIhsDetails,
|
|
9766
9800
|
resolveExtractionStatus,
|
|
9767
9801
|
resolvePageFields,
|