@dynamatix/gb-schemas 2.3.279 → 2.3.280

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.
@@ -1 +1 @@
1
- {"version":3,"file":"applicant-welcome-call.model.d.ts","sourceRoot":"","sources":["../../applicants/applicant-welcome-call.model.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,QAAQ,MAAM,UAAU,CAAC;AAorBhC,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAA4D,CAAC;AAEnF,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"applicant-welcome-call.model.d.ts","sourceRoot":"","sources":["../../applicants/applicant-welcome-call.model.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,QAAQ,MAAM,UAAU,CAAC;AA4rBhC,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAA4D,CAAC;AAEnF,eAAe,gBAAgB,CAAC"}
@@ -556,10 +556,18 @@ welcomeCallSchema.virtual('initialRatePercentage').get(function () {
556
556
  // Virtual property for finance summary HTML
557
557
  welcomeCallSchema.virtual('financeSummaryHtml').get(function () {
558
558
  console.log('financeSummaryHtml virtual field called');
559
- console.log('Current applicationId:', this.applicationId);
560
- // Get application data
561
- if (this.applicationId && typeof this.applicationId === 'object') {
562
- const application = this.applicationId;
559
+ let application = null;
560
+ if (this.applicantId && typeof this.applicantId === 'object' && !(typeof this.applicantId.toHexString === 'function') && this.applicantId.applicationId) {
561
+ application = this.applicantId.applicationId;
562
+ }
563
+ else if (this.applicationId && typeof this.applicationId === 'object') {
564
+ application = this.applicationId;
565
+ }
566
+ else {
567
+ console.log('No application found');
568
+ return 'N/A';
569
+ }
570
+ if (application) {
563
571
  console.log('Application data:', JSON.stringify(application, null, 2));
564
572
  // Initialize summary data
565
573
  let product = 'N/A';
@@ -633,7 +641,7 @@ welcomeCallSchema.virtual('financeSummaryHtml').get(function () {
633
641
  console.log('Final summary content:', summaryContent);
634
642
  return summaryContent;
635
643
  }
636
- console.log('No applicationId found or not populated');
644
+ console.log('No application found');
637
645
  return 'N/A';
638
646
  });
639
647
  applyAuditMiddleware(welcomeCallSchema, "ApplicantWelcomeCall");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamatix/gb-schemas",
3
- "version": "2.3.279",
3
+ "version": "2.3.280",
4
4
  "description": "All the schemas for gatehouse bank back-end",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",