@finsys/core 1.5.0 → 1.6.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/index.d.cts CHANGED
@@ -432,4 +432,14 @@ declare function buildFileFieldTables(ihsData: Record<string, unknown>): Record<
432
432
  declare function processIhsDetails(ihsData: Record<string, unknown>): IhsFieldDetail[];
433
433
  declare function groupDetailsByCategory(details: IhsFieldDetail[]): IhsDetailCategory[];
434
434
 
435
- export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DropdownOption, type EditorValidator, 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, type SurveyElementJSON, type SurveyJSON, type SurveyPageJSON, type UnifiedFormConfig, type Validator, applyDynamicTitles, buildFileFieldTables, evaluateExpression, extractTimePeriods, generateRHFSchema, generateSurveyJson, getBaseCategories, getBaseFieldNames, getBaseFieldSpecMap, getBaseFieldSpecs, getCategoryName, getDisplayName, getDisplayNames, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, processIhsDetails, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
435
+ /**
436
+ * Program access roles — shared across finsys-api and finhub-adonisjs.
437
+ * Values must match the database enum column in the `programaccess` table.
438
+ */
439
+ declare enum Role {
440
+ ADMIN = "Admin",
441
+ BORROWER_AGENT = "Borrower Agent",
442
+ LENDER_AGENT = "Lender Agent"
443
+ }
444
+
445
+ export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DropdownOption, type EditorValidator, 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, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, processIhsDetails, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
package/dist/index.d.ts CHANGED
@@ -432,4 +432,14 @@ declare function buildFileFieldTables(ihsData: Record<string, unknown>): Record<
432
432
  declare function processIhsDetails(ihsData: Record<string, unknown>): IhsFieldDetail[];
433
433
  declare function groupDetailsByCategory(details: IhsFieldDetail[]): IhsDetailCategory[];
434
434
 
435
- export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DropdownOption, type EditorValidator, 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, type SurveyElementJSON, type SurveyJSON, type SurveyPageJSON, type UnifiedFormConfig, type Validator, applyDynamicTitles, buildFileFieldTables, evaluateExpression, extractTimePeriods, generateRHFSchema, generateSurveyJson, getBaseCategories, getBaseFieldNames, getBaseFieldSpecMap, getBaseFieldSpecs, getCategoryName, getDisplayName, getDisplayNames, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, processIhsDetails, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
435
+ /**
436
+ * Program access roles — shared across finsys-api and finhub-adonisjs.
437
+ * Values must match the database enum column in the `programaccess` table.
438
+ */
439
+ declare enum Role {
440
+ ADMIN = "Admin",
441
+ BORROWER_AGENT = "Borrower Agent",
442
+ LENDER_AGENT = "Lender Agent"
443
+ }
444
+
445
+ export { BASE_FIELD_SPECS, BasicFormField, type Category, type Choice, DEFAULT_VALIDATOR_DEFINITIONS, type DropdownOption, type EditorValidator, 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, getPastMonthLabel, getPastYearLabel, getStepDefaultValues, getStepSchema, groupColumnsByTimePeriod, groupDetailsByCategory, groupFieldsByCategory, groupFieldsByPattern, processIhsDetails, resolvePageFields, validateFormConfig, validateFormSpec, validatePagesConfig };
package/dist/index.js CHANGED
@@ -9317,6 +9317,7 @@ var FIELD_GROUP_PREFIXES = [
9317
9317
  ["financials", "financials"],
9318
9318
  ["epf_statement", "epf_statements"],
9319
9319
  ["payslip_statement", "payslip_statements"],
9320
+ ["ssm_business_information", "ssm_company_profile"],
9320
9321
  ["ssm", "ssm_documents"],
9321
9322
  ["ic_", "ic_documents"]
9322
9323
  ];
@@ -9341,7 +9342,8 @@ var GROUP_DISPLAY_NAMES = {
9341
9342
  financials: "Audited Financial Statements",
9342
9343
  epf_statements: "EPF Statements",
9343
9344
  payslip_statements: "Payslip Statements",
9344
- ssm_documents: "SSM Company Information",
9345
+ ssm_documents: "Form 9 / Section 17 / Form D",
9346
+ ssm_company_profile: "SSM Company Profile",
9345
9347
  ic_documents: "Identification Card"
9346
9348
  };
9347
9349
  function isNumericField(fieldName) {
@@ -9533,6 +9535,14 @@ function groupDetailsByCategory(details) {
9533
9535
  }))
9534
9536
  }));
9535
9537
  }
9538
+
9539
+ // src/roles.ts
9540
+ var Role = /* @__PURE__ */ ((Role2) => {
9541
+ Role2["ADMIN"] = "Admin";
9542
+ Role2["BORROWER_AGENT"] = "Borrower Agent";
9543
+ Role2["LENDER_AGENT"] = "Lender Agent";
9544
+ return Role2;
9545
+ })(Role || {});
9536
9546
  export {
9537
9547
  BASE_FIELD_SPECS,
9538
9548
  BasicFormField,
@@ -9546,6 +9556,7 @@ export {
9546
9556
  FormFieldValidator,
9547
9557
  FormSpec,
9548
9558
  IhsValueFormat,
9559
+ Role,
9549
9560
  applyDynamicTitles,
9550
9561
  buildFileFieldTables,
9551
9562
  evaluateExpression,