Upgrade/angular 14 (#1853)

* Fix Loan product Payment Allocation

* Upgrade to Angular 14

---------

Co-authored-by: Jose Alberto Hernandez <alberto@blue-daemon.local>
This commit is contained in:
José Alberto Hernández
2023-08-29 19:51:32 -06:00
committed by GitHub
co-authored by Jose Alberto Hernandez
parent 2dab3b70ca
commit 80936a3ea9
336 changed files with 6657 additions and 5698 deletions
@@ -25,7 +25,9 @@ export class LoanDetailsResolver implements Resolve<Object> {
*/
resolve(route: ActivatedRouteSnapshot): Observable<any> {
const loanId = route.paramMap.get('loanId') || route.parent.paramMap.get('loanId');
return this.loansService.getLoanAccountAssociationDetails(loanId);
if (!isNaN(+loanId)) {
return this.loansService.getLoanAccountAssociationDetails(loanId);
}
}
}
@@ -1,6 +1,6 @@
import { Component, OnInit, Inject } from '@angular/core';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
@Component({
selector: 'mifosx-loans-account-add-collateral-dialog',
@@ -15,7 +15,7 @@ export class LoansAccountAddCollateralDialogComponent implements OnInit {
addButtonText: 'Add'
};
addCollateralForm: FormGroup;
addCollateralForm: UntypedFormGroup;
/** All Collateral Options */
collateralTypeData: any;
/** Selected Collateral */
@@ -25,7 +25,7 @@ export class LoansAccountAddCollateralDialogComponent implements OnInit {
constructor(public dialogRef: MatDialogRef<LoansAccountAddCollateralDialogComponent>,
@Inject(MAT_DIALOG_DATA) public data: any,
private formBuilder: FormBuilder) {
private formBuilder: UntypedFormBuilder) {
this.createAddCollateralForm();
}
@@ -1,5 +1,5 @@
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { LoansService } from 'app/loans/loans.service';
import { SettingsService } from 'app/settings/settings.service';
@@ -29,7 +29,7 @@ export class GlimDetailsStepComponent implements OnInit {
/** For edit loan accounts form */
isFieldOfficerPatched = false;
/** Loans Account Details Form */
loansAccountDetailsForm: FormGroup;
loansAccountDetailsForm: UntypedFormGroup;
/** Loans Account Template with product data */
@Output() loansAccountProductTemplate = new EventEmitter();
@@ -39,7 +39,7 @@ export class GlimDetailsStepComponent implements OnInit {
* @param {LoansService} loansService Loans Service.
* @param {SettingsService} settingsService SettingsService
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loansService: LoansService,
private settingsService: SettingsService) {
this.createLoansAccountDetailsForm();
@@ -1,5 +1,5 @@
import { Component, Input, OnInit, OnChanges } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormArray } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, FormArray } from '@angular/forms';
import { SettingsService } from 'app/settings/settings.service';
@Component({
@@ -19,7 +19,7 @@ export class GlimTermsStepComponent implements OnInit, OnChanges {
/** Maximum date allowed. */
maxDate = new Date(2100, 0, 1);
/** Loans Account Terms Form */
loansAccountTermsForm: FormGroup;
loansAccountTermsForm: UntypedFormGroup;
/** Term Frequency Type Data */
termFrequencyTypeData: any;
/** Repayment Frequency Nth Day Type Data */
@@ -42,7 +42,7 @@ export class GlimTermsStepComponent implements OnInit, OnChanges {
* @param formBuilder FormBuilder
* @param {SettingsService} settingsService SettingsService
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private settingsService: SettingsService) {
this.createloansAccountTermsForm();
}
@@ -1,5 +1,5 @@
import { Component, Input, OnInit } from '@angular/core';
import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
import { Dates } from 'app/core/utils/dates';
import { SettingsService } from 'app/settings/settings.service';
@@ -12,11 +12,11 @@ export class LoansAccountDatatableStepComponent implements OnInit {
/** Input Fields Data */
@Input() datatableData: any;
/** Create Input Form */
datatableForm: FormGroup;
datatableForm: UntypedFormGroup;
datatableInputs: any = [];
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private settingsService: SettingsService,
private dateUtils: Dates) { }
@@ -29,12 +29,12 @@ export class LoansAccountDatatableStepComponent implements OnInit {
input.controlName = this.getInputName(input);
if (!input.isColumnNullable) {
if (this.isNumeric(input.columnDisplayType)) {
inputItems[input.controlName] = new FormControl(0, [Validators.required]);
inputItems[input.controlName] = new UntypedFormControl(0, [Validators.required]);
} else {
inputItems[input.controlName] = new FormControl('', [Validators.required]);
inputItems[input.controlName] = new UntypedFormControl('', [Validators.required]);
}
} else {
inputItems[input.controlName] = new FormControl('');
inputItems[input.controlName] = new UntypedFormControl('');
}
});
this.datatableForm = this.formBuilder.group(inputItems);
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { ActivatedRoute } from '@angular/router';
import { SettingsService } from 'app/settings/settings.service';
import { TooltipPosition } from '@angular/material/tooltip';
@@ -38,7 +38,7 @@ export class LoansAccountDetailsStepComponent implements OnInit {
/** For edit loan accounts form */
isFieldOfficerPatched = false;
/** Loans Account Details Form */
loansAccountDetailsForm: FormGroup;
loansAccountDetailsForm: UntypedFormGroup;
loanId: any = null;
@@ -52,7 +52,7 @@ export class LoansAccountDetailsStepComponent implements OnInit {
* @param {LoansService} loansService Loans Service.
* @param {SettingsService} settingsService SettingsService
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loansService: LoansService,
private route: ActivatedRoute,
private settingsService: SettingsService) {
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input, OnChanges } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormArray } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, FormArray } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { ActivatedRoute, Router } from '@angular/router';
import { LoansAccountAddCollateralDialogComponent } from 'app/loans/custom-dialog/loans-account-add-collateral-dialog/loans-account-add-collateral-dialog.component';
@@ -42,7 +42,7 @@ export class LoansAccountTermsStepComponent implements OnInit, OnChanges {
/** Maximum date allowed. */
maxDate = new Date(2100, 0, 1);
/** Loans Account Terms Form */
loansAccountTermsForm: FormGroup;
loansAccountTermsForm: UntypedFormGroup;
/** Term Frequency Type Data */
termFrequencyTypeData: any;
/** Repayment Frequency Nth Day Type Data */
@@ -87,7 +87,7 @@ export class LoansAccountTermsStepComponent implements OnInit, OnChanges {
* @param formBuilder FormBuilder
* @param {SettingsService} settingsService SettingsService
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private settingsService: SettingsService,
private route: ActivatedRoute,
public dialog: MatDialog) {
-1
View File
@@ -60,7 +60,6 @@ import { LoanArrearDelinquencyResolver } from './common-resolvers/loan-arrear-de
import { ExternalAssetOwnerTabComponent } from './loans-view/external-asset-owner-tab/external-asset-owner-tab.component';
import { ExternalAssetOwnerResolver } from './common-resolvers/external-asset-owner.resolver';
import { ExternalAssetOwnerActiveTransferResolver } from './common-resolvers/external-asset-owner-active-transfer.resolver';
import { ExternalAssetOwnerJournalEntryResolver } from './common-resolvers/external-asset-owner-journal-entry.resolver';
import { LoanCollateralsResolver } from './common-resolvers/loan-collaterals.resolver';
/** Loans Route. */
@@ -1,6 +1,6 @@
/** Angular Imports. */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services. */
@@ -19,7 +19,7 @@ export class AddCollateralComponent implements OnInit {
@Input() dataObject: any;
/** Collateral form. */
collateralForm: FormGroup;
collateralForm: UntypedFormGroup;
/** Loan Id. */
loanId: string;
@@ -30,7 +30,7 @@ export class AddCollateralComponent implements OnInit {
* @param {ActivatedRoute} route Activated Route.
* @param {LoansService} LoansService loans service.
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private router: Router,
private route: ActivatedRoute,
private loanService: LoansService ) { }
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
/** Custom Services */
@@ -23,7 +23,7 @@ export class AddLoanChargeComponent implements OnInit {
/** Maximum Due Date allowed. */
maxDate = new Date();
/** Add Loan Charge form. */
loanChargeForm: FormGroup;
loanChargeForm: UntypedFormGroup;
/** loan charge options. */
loanChargeOptions: {
id: number;
@@ -51,7 +51,7 @@ export class AddLoanChargeComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private route: ActivatedRoute,
private router: Router,
private dateUtils: Dates,
@@ -74,7 +74,7 @@ export class AddLoanChargeComponent implements OnInit {
return option.id === chargeId;
});
if (chargeDetails.chargeTimeType.id === 2) {
this.loanChargeForm.addControl('dueDate', new FormControl('', Validators.required));
this.loanChargeForm.addControl('dueDate', new UntypedFormControl('', Validators.required));
} else {
this.loanChargeForm.removeControl('dueDate');
}
@@ -1,5 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { LoansService } from 'app/loans/loans.service';
import { OrganizationService } from 'app/organization/organization.service';
@@ -27,7 +27,7 @@ export class AdjustLoanChargeComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Repayment Loan Form */
adjustLoanChargeForm: FormGroup;
adjustLoanChargeForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -36,7 +36,7 @@ export class AdjustLoanChargeComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -84,11 +84,11 @@ export class AdjustLoanChargeComponent implements OnInit {
addPaymentDetails() {
this.showPaymentDetails = !this.showPaymentDetails;
if (this.showPaymentDetails) {
this.adjustLoanChargeForm.addControl('accountNumber', new FormControl(''));
this.adjustLoanChargeForm.addControl('checkNumber', new FormControl(''));
this.adjustLoanChargeForm.addControl('routingCode', new FormControl(''));
this.adjustLoanChargeForm.addControl('receiptNumber', new FormControl(''));
this.adjustLoanChargeForm.addControl('bankNumber', new FormControl(''));
this.adjustLoanChargeForm.addControl('accountNumber', new UntypedFormControl(''));
this.adjustLoanChargeForm.addControl('checkNumber', new UntypedFormControl(''));
this.adjustLoanChargeForm.addControl('routingCode', new UntypedFormControl(''));
this.adjustLoanChargeForm.addControl('receiptNumber', new UntypedFormControl(''));
this.adjustLoanChargeForm.addControl('bankNumber', new UntypedFormControl(''));
} else {
this.adjustLoanChargeForm.removeControl('accountNumber');
this.adjustLoanChargeForm.removeControl('checkNumber');
@@ -1,6 +1,6 @@
/** Angular Imports. */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, FormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
@@ -19,7 +19,7 @@ import { SettingsService } from 'app/settings/settings.service';
export class ApproveLoanComponent implements OnInit {
/** Approve Loan form. */
approveLoanForm: FormGroup;
approveLoanForm: UntypedFormGroup;
/** Loan data. */
loanData: any = new Object();
/** Association Data */
@@ -38,7 +38,7 @@ export class ApproveLoanComponent implements OnInit {
* @param router Router.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private route: ActivatedRoute,
private dateUtils: Dates,
private loanService: LoansService,
@@ -1,5 +1,5 @@
import { Component, Input, OnInit } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
import { ExternalAssetOwnerService } from 'app/loans/services/external-asset-owner.service';
@@ -23,9 +23,9 @@ export class AssetTransferLoanComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Sell Loan Form */
saleLoanForm: FormGroup;
saleLoanForm: UntypedFormGroup;
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private externalAssetOwnerService: ExternalAssetOwnerService,
private route: ActivatedRoute,
private router: Router,
@@ -1,7 +1,7 @@
import { Component, OnInit, Input } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { LoansService } from 'app/loans/loans.service';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
/** Custom Services */
import { SettingsService } from 'app/settings/settings.service';
@@ -23,7 +23,7 @@ export class AssignLoanOfficerComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Assign loan Officer form. */
assignOfficerForm: FormGroup;
assignOfficerForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -32,7 +32,7 @@ export class AssignLoanOfficerComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,5 +1,5 @@
import { Component, Input, OnInit } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
import { LoansService } from 'app/loans/loans.service';
@@ -24,7 +24,7 @@ export class ChargeOffComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Repayment Loan Form */
chargeoffLoanForm: FormGroup;
chargeoffLoanForm: UntypedFormGroup;
chargeOffReasonOptions: any = [];
@@ -35,7 +35,7 @@ export class ChargeOffComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,5 +1,5 @@
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { LoansService } from 'app/loans/loans.service';
import { ActivatedRoute, Router } from '@angular/router';
@@ -17,7 +17,7 @@ export class CloseAsRescheduledComponent implements OnInit {
@Input() dataObject: any;
/** Close form. */
closeLoanForm: FormGroup;
closeLoanForm: UntypedFormGroup;
/** Loan Id */
loanId: any;
/** Minimum Date allowed. */
@@ -32,7 +32,7 @@ export class CloseAsRescheduledComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input, AfterViewInit } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -21,7 +21,7 @@ export class CreateGuarantorComponent implements OnInit, AfterViewInit {
@Input() dataObject: any;
/** New Guarantor Form */
newGuarantorForm: FormGroup;
newGuarantorForm: UntypedFormGroup;
/** Loan ID */
loanId: string;
/** Relation Types */
@@ -44,7 +44,7 @@ export class CreateGuarantorComponent implements OnInit, AfterViewInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -87,22 +87,22 @@ export class CreateGuarantorComponent implements OnInit, AfterViewInit {
this.newGuarantorForm.get('existingClient').valueChanges.subscribe(() => {
this.showClientDetailsForm = !this.showClientDetailsForm;
if (this.showClientDetailsForm) {
this.newGuarantorForm.addControl('firstname', new FormControl(''));
this.newGuarantorForm.addControl('lastname', new FormControl(''));
this.newGuarantorForm.addControl('dob', new FormControl(''));
this.newGuarantorForm.addControl('addressLine1', new FormControl(''));
this.newGuarantorForm.addControl('addressLine2', new FormControl(''));
this.newGuarantorForm.addControl('city', new FormControl(''));
this.newGuarantorForm.addControl('zip', new FormControl(''));
this.newGuarantorForm.addControl('mobileNumber', new FormControl(''));
this.newGuarantorForm.addControl('housePhoneNumber', new FormControl(''));
this.newGuarantorForm.addControl('firstname', new UntypedFormControl(''));
this.newGuarantorForm.addControl('lastname', new UntypedFormControl(''));
this.newGuarantorForm.addControl('dob', new UntypedFormControl(''));
this.newGuarantorForm.addControl('addressLine1', new UntypedFormControl(''));
this.newGuarantorForm.addControl('addressLine2', new UntypedFormControl(''));
this.newGuarantorForm.addControl('city', new UntypedFormControl(''));
this.newGuarantorForm.addControl('zip', new UntypedFormControl(''));
this.newGuarantorForm.addControl('mobileNumber', new UntypedFormControl(''));
this.newGuarantorForm.addControl('housePhoneNumber', new UntypedFormControl(''));
this.newGuarantorForm.removeControl('name');
this.newGuarantorForm.removeControl('savingsId');
this.newGuarantorForm.removeControl('amount');
} else {
this.newGuarantorForm.addControl('name', new FormControl(''));
this.newGuarantorForm.addControl('savingsId', new FormControl(''));
this.newGuarantorForm.addControl('amount', new FormControl(''));
this.newGuarantorForm.addControl('name', new UntypedFormControl(''));
this.newGuarantorForm.addControl('savingsId', new UntypedFormControl(''));
this.newGuarantorForm.addControl('amount', new UntypedFormControl(''));
this.newGuarantorForm.removeControl('firstname');
this.newGuarantorForm.removeControl('lastname');
this.newGuarantorForm.removeControl('dob');
@@ -1,5 +1,5 @@
import { Component, Input, OnInit } from '@angular/core';
import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
import { LoansService } from 'app/loans/loans.service';
@@ -19,7 +19,7 @@ export class DisburseToSavingsAccountComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Disbursement Loan form. */
disbursementForm: FormGroup;
disbursementForm: UntypedFormGroup;
/**
* Get data from `Resolver`.
@@ -29,7 +29,7 @@ export class DisburseToSavingsAccountComponent implements OnInit {
* @param {LoansService} loanService Loan Service.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private route: ActivatedRoute,
private router: Router,
private dateUtils: Dates,
@@ -52,7 +52,7 @@ export class DisburseToSavingsAccountComponent implements OnInit {
'note': ['']
});
if (this.dataObject.fixedEmiAmount) {
this.disbursementForm.addControl('fixedEmiAmount', new FormControl(this.dataObject.fixedEmiAmount, [Validators.required]));
this.disbursementForm.addControl('fixedEmiAmount', new UntypedFormControl(this.dataObject.fixedEmiAmount, [Validators.required]));
}
}
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -30,7 +30,7 @@ export class DisburseComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Disbursement Loan Form */
disbursementLoanForm: FormGroup;
disbursementLoanForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -39,7 +39,7 @@ export class DisburseComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -86,11 +86,11 @@ export class DisburseComponent implements OnInit {
addPaymentDetails() {
this.showPaymentDetails = !this.showPaymentDetails;
if (this.showPaymentDetails) {
this.disbursementLoanForm.addControl('accountNumber', new FormControl(''));
this.disbursementLoanForm.addControl('checkNumber', new FormControl(''));
this.disbursementLoanForm.addControl('routingCode', new FormControl(''));
this.disbursementLoanForm.addControl('receiptNumber', new FormControl(''));
this.disbursementLoanForm.addControl('bankNumber', new FormControl(''));
this.disbursementLoanForm.addControl('accountNumber', new UntypedFormControl(''));
this.disbursementLoanForm.addControl('checkNumber', new UntypedFormControl(''));
this.disbursementLoanForm.addControl('routingCode', new UntypedFormControl(''));
this.disbursementLoanForm.addControl('receiptNumber', new UntypedFormControl(''));
this.disbursementLoanForm.addControl('bankNumber', new UntypedFormControl(''));
} else {
this.disbursementLoanForm.removeControl('accountNumber');
this.disbursementLoanForm.removeControl('checkNumber');
@@ -1,5 +1,5 @@
import { Component, Input, OnInit } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { LoansService } from 'app/loans/loans.service';
import { ActivatedRoute, Router } from '@angular/router';
@@ -16,7 +16,7 @@ export class ForeclosureComponent implements OnInit {
@Input() dataObject: any;
loanId: any;
foreclosureForm: FormGroup;
foreclosureForm: UntypedFormGroup;
/** Minimum Date allowed. */
minDate = new Date(2000, 0, 1);
/** Maximum Date allowed. */
@@ -30,7 +30,7 @@ export class ForeclosureComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,5 +1,5 @@
import { Component, Input, OnInit } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
import { LoansService } from 'app/loans/loans.service';
@@ -20,7 +20,7 @@ export class LoanCreditBalanceRefundComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Credit Balance Loan Form */
creditBalanceLoanForm: FormGroup;
creditBalanceLoanForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -29,7 +29,7 @@ export class LoanCreditBalanceRefundComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,6 +1,6 @@
import { Component, OnInit, Input } from '@angular/core';
import { LoansService } from 'app/loans/loans.service';
import { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators, UntypedFormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -16,7 +16,7 @@ export class LoanRescheduleComponent implements OnInit {
@Input() dataObject: any;
loanId: any;
rescheduleLoanForm: FormGroup;
rescheduleLoanForm: UntypedFormGroup;
/** Minimum Date allowed. */
minDate = new Date(2000, 0, 1);
@@ -24,10 +24,10 @@ export class LoanRescheduleComponent implements OnInit {
maxDate = new Date();
codes: any;
changeRepaymentDate = new FormControl(false);
introduceGracePeriods = new FormControl(false);
extendRepaymentPeriod = new FormControl(false);
adjustinterestrates = new FormControl(false);
changeRepaymentDate = new UntypedFormControl(false);
introduceGracePeriods = new UntypedFormControl(false);
extendRepaymentPeriod = new UntypedFormControl(false);
adjustinterestrates = new UntypedFormControl(false);
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -36,7 +36,7 @@ export class LoanRescheduleComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Renderer2, ViewChild, ElementRef, SecurityContext, Input } from '@angular/core';
import { FormGroup, FormBuilder } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -19,7 +19,7 @@ export class LoanScreenReportsComponent implements OnInit {
@Input() dataObject: any;
/** Loan Screen Reportform. */
loanScreenReportForm: FormGroup;
loanScreenReportForm: UntypedFormGroup;
/** Templates Data */
templatesData: any;
/** Loan Id */
@@ -38,7 +38,7 @@ export class LoanScreenReportsComponent implements OnInit {
* @param {DomSanitizer} sanitizer DOM Sanitizer
* @param {Renderer2} renderer Renderer 2
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loansService: LoansService,
private route: ActivatedRoute,
private sanitizer: DomSanitizer,
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input } from '@angular/core';
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
import { LoansService } from 'app/loans/loans.service';
@@ -18,7 +18,7 @@ export class LoansAccountCloseComponent implements OnInit {
@Input() dataObject: any;
/** Close form. */
closeLoanForm: FormGroup;
closeLoanForm: UntypedFormGroup;
/** Loan Id */
loanId: any;
/** Minimum Date allowed. */
@@ -33,7 +33,7 @@ export class LoansAccountCloseComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input, OnDestroy } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -30,7 +30,7 @@ export class MakeRepaymentComponent implements OnInit, OnDestroy {
/** Maximum Date allowed. */
maxDate = new Date();
/** Repayment Loan Form */
repaymentLoanForm: FormGroup;
repaymentLoanForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -39,7 +39,7 @@ export class MakeRepaymentComponent implements OnInit, OnDestroy {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -88,11 +88,11 @@ export class MakeRepaymentComponent implements OnInit, OnDestroy {
addPaymentDetails() {
this.showPaymentDetails = !this.showPaymentDetails;
if (this.showPaymentDetails) {
this.repaymentLoanForm.addControl('accountNumber', new FormControl(''));
this.repaymentLoanForm.addControl('checkNumber', new FormControl(''));
this.repaymentLoanForm.addControl('routingCode', new FormControl(''));
this.repaymentLoanForm.addControl('receiptNumber', new FormControl(''));
this.repaymentLoanForm.addControl('bankNumber', new FormControl(''));
this.repaymentLoanForm.addControl('accountNumber', new UntypedFormControl(''));
this.repaymentLoanForm.addControl('checkNumber', new UntypedFormControl(''));
this.repaymentLoanForm.addControl('routingCode', new UntypedFormControl(''));
this.repaymentLoanForm.addControl('receiptNumber', new UntypedFormControl(''));
this.repaymentLoanForm.addControl('bankNumber', new UntypedFormControl(''));
} else {
this.repaymentLoanForm.removeControl('accountNumber');
this.repaymentLoanForm.removeControl('checkNumber');
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input, OnDestroy } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -35,7 +35,7 @@ export class PrepayLoanComponent implements OnInit, OnDestroy {
/** Maximum Date allowed. */
maxDate = new Date();
/** Prepay Loan form. */
prepayLoanForm: FormGroup;
prepayLoanForm: UntypedFormGroup;
prepayData: any;
@@ -46,7 +46,7 @@ export class PrepayLoanComponent implements OnInit, OnDestroy {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -109,11 +109,11 @@ export class PrepayLoanComponent implements OnInit, OnDestroy {
addPaymentDetails() {
this.showPaymentDetails = !this.showPaymentDetails;
if (this.showPaymentDetails) {
this.prepayLoanForm.addControl('accountNumber', new FormControl(''));
this.prepayLoanForm.addControl('checkNumber', new FormControl(''));
this.prepayLoanForm.addControl('routingCode', new FormControl(''));
this.prepayLoanForm.addControl('receiptNumber', new FormControl(''));
this.prepayLoanForm.addControl('bankNumber', new FormControl(''));
this.prepayLoanForm.addControl('accountNumber', new UntypedFormControl(''));
this.prepayLoanForm.addControl('checkNumber', new UntypedFormControl(''));
this.prepayLoanForm.addControl('routingCode', new UntypedFormControl(''));
this.prepayLoanForm.addControl('receiptNumber', new UntypedFormControl(''));
this.prepayLoanForm.addControl('bankNumber', new UntypedFormControl(''));
} else {
this.prepayLoanForm.removeControl('accountNumber');
this.prepayLoanForm.removeControl('checkNumber');
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -30,7 +30,7 @@ export class RecoveryRepaymentComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Recovery Repayment Loan Form */
recoveryRepaymentLoanForm: FormGroup;
recoveryRepaymentLoanForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -39,7 +39,7 @@ export class RecoveryRepaymentComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -85,11 +85,11 @@ export class RecoveryRepaymentComponent implements OnInit {
addPaymentDetails() {
this.showPaymentDetails = !this.showPaymentDetails;
if (this.showPaymentDetails) {
this.recoveryRepaymentLoanForm.addControl('accountNumber', new FormControl(''));
this.recoveryRepaymentLoanForm.addControl('checkNumber', new FormControl(''));
this.recoveryRepaymentLoanForm.addControl('routingCode', new FormControl(''));
this.recoveryRepaymentLoanForm.addControl('receiptNumber', new FormControl(''));
this.recoveryRepaymentLoanForm.addControl('bankNumber', new FormControl(''));
this.recoveryRepaymentLoanForm.addControl('accountNumber', new UntypedFormControl(''));
this.recoveryRepaymentLoanForm.addControl('checkNumber', new UntypedFormControl(''));
this.recoveryRepaymentLoanForm.addControl('routingCode', new UntypedFormControl(''));
this.recoveryRepaymentLoanForm.addControl('receiptNumber', new UntypedFormControl(''));
this.recoveryRepaymentLoanForm.addControl('bankNumber', new UntypedFormControl(''));
} else {
this.recoveryRepaymentLoanForm.removeControl('accountNumber');
this.recoveryRepaymentLoanForm.removeControl('checkNumber');
@@ -1,6 +1,6 @@
/** Angular Imports. */
import { Component, OnInit } from '@angular/core';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
/** Custom services. */
@@ -21,7 +21,7 @@ export class RejectLoanComponent implements OnInit {
/** Loan Id. */
loanId: any;
/** Reject Loan form. */
rejectLoanForm: FormGroup;
rejectLoanForm: UntypedFormGroup;
/** Minimum Date allowed. */
minDate = new Date(2000, 0, 1);
/** Maximum Date allowed. */
@@ -34,7 +34,7 @@ export class RejectLoanComponent implements OnInit {
* @param route Activated Route.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private router: Router,
private route: ActivatedRoute,
private loanService: LoansService,
@@ -1,6 +1,6 @@
/** Angular Imports. */
import { Component, OnInit } from '@angular/core';
import { FormControl, FormBuilder } from '@angular/forms';
import { UntypedFormControl, UntypedFormBuilder } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services. */
@@ -16,7 +16,7 @@ import { LoansService } from 'app/loans/loans.service';
export class UndoApprovalComponent implements OnInit {
/** Form Controller. */
note: FormControl;
note: UntypedFormControl;
/**
* @param loanService Loan Service.
@@ -24,7 +24,7 @@ export class UndoApprovalComponent implements OnInit {
* @param router Router.
*/
constructor(private loanService: LoansService,
private formBuilder: FormBuilder,
private formBuilder: UntypedFormBuilder,
private route: ActivatedRoute,
private router: Router) { }
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, Input, OnInit } from '@angular/core';
import { FormControl, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormControl, UntypedFormBuilder, Validators } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
/** Custom Services */
@@ -21,7 +21,7 @@ export class UndoDisbursalComponent implements OnInit {
/** Loan ID. */
loanId: any;
/** Undo disbursal form. */
note: FormControl;
note: UntypedFormControl;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -29,7 +29,7 @@ export class UndoDisbursalComponent implements OnInit {
* @param {ActivatedRoute} route Activated Route.
* @param {Router} router Router for navigation.
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loansService: LoansService,
private router: Router,
private route: ActivatedRoute) {
@@ -1,6 +1,6 @@
/** Angular Imports. */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
/** Custom Services. */
@@ -21,7 +21,7 @@ export class WaiveInterestComponent implements OnInit {
@Input() dataObject: any;
/** Loan Interest form. */
loanInterestForm: FormGroup;
loanInterestForm: UntypedFormGroup;
/** Minimum Date allowed. */
minDate = new Date(2000, 0, 1);
/** Maximum Date allowed. */
@@ -34,7 +34,7 @@ export class WaiveInterestComponent implements OnInit {
* @param {LoansService} loanService Loan Service.
* @param {ActivatedRoute} route Activated Route.
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private router: Router,
private settingsService: SettingsService,
private dateUtils: Dates,
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, FormControl } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
@@ -26,7 +26,7 @@ export class WithdrawnByClientComponent implements OnInit {
/** Maximum Date allowed. */
maxDate = new Date();
/** Withdrawn By Applicant Loan Form */
withdrawnByClientLoanForm: FormGroup;
withdrawnByClientLoanForm: UntypedFormGroup;
/**
* @param {FormBuilder} formBuilder Form Builder.
@@ -35,7 +35,7 @@ export class WithdrawnByClientComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private loanService: LoansService,
private route: ActivatedRoute,
private router: Router,
@@ -1,6 +1,6 @@
/** Angular Imports. */
import { Component, OnInit, Input } from '@angular/core';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { ActivatedRoute, Router } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
@@ -26,7 +26,7 @@ export class WriteOffPageComponent implements OnInit {
maxDate = new Date();
/** Write Off form. */
writeOffForm: FormGroup;
writeOffForm: UntypedFormGroup;
/**
* Get data from `Resolver`.
@@ -37,7 +37,7 @@ export class WriteOffPageComponent implements OnInit {
* @param {Router} router Router.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private route: ActivatedRoute,
private loanService: LoansService,
private dateUtils: Dates,
@@ -1,6 +1,6 @@
import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { FormControl } from '@angular/forms';
import { UntypedFormControl } from '@angular/forms';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
@@ -22,7 +22,7 @@ export class TransactionsTabComponent implements OnInit {
/** Temporary Transaction Data */
tempTransaction: any;
/** Form control to handle accural parameter */
hideAccrualsParam: FormControl;
hideAccrualsParam: UntypedFormControl;
/** Stores the status of the loan account */
status: string;
/** Columns to be displayed in original schedule table. */
@@ -50,7 +50,7 @@ export class TransactionsTabComponent implements OnInit {
}
ngOnInit() {
this.hideAccrualsParam = new FormControl(false);
this.hideAccrualsParam = new UntypedFormControl(false);
this.setLoanTransactions(this.transactions);
}
@@ -1,6 +1,6 @@
/** Angular Imports */
import { Component, OnInit } from '@angular/core';
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
import { Dates } from 'app/core/utils/dates';
@@ -23,7 +23,7 @@ export class EditTransactionComponent implements OnInit {
/** Maximum Due Date allowed. */
maxDate = new Date();
/** Loans account transaction form. */
editTransactionForm: FormGroup;
editTransactionForm: UntypedFormGroup;
/** loans account transaction payment options. */
paymentTypeOptions: {
id: number,
@@ -48,7 +48,7 @@ export class EditTransactionComponent implements OnInit {
* @param {Router} router Router for navigation.
* @param {SettingsService} settingsService Settings Service
*/
constructor(private formBuilder: FormBuilder,
constructor(private formBuilder: UntypedFormBuilder,
private route: ActivatedRoute,
private router: Router,
private dateUtils: Dates,
@@ -93,11 +93,11 @@ export class EditTransactionComponent implements OnInit {
addPaymentDetails() {
this.showPaymentDetails = !this.showPaymentDetails;
if (this.showPaymentDetails) {
this.editTransactionForm.addControl('accountNumber', new FormControl(''));
this.editTransactionForm.addControl('checkNumber', new FormControl(''));
this.editTransactionForm.addControl('routingCode', new FormControl(''));
this.editTransactionForm.addControl('receiptNumber', new FormControl(''));
this.editTransactionForm.addControl('bankNumber', new FormControl(''));
this.editTransactionForm.addControl('accountNumber', new UntypedFormControl(''));
this.editTransactionForm.addControl('checkNumber', new UntypedFormControl(''));
this.editTransactionForm.addControl('routingCode', new UntypedFormControl(''));
this.editTransactionForm.addControl('receiptNumber', new UntypedFormControl(''));
this.editTransactionForm.addControl('bankNumber', new UntypedFormControl(''));
} else {
this.editTransactionForm.removeControl('accountNumber');
this.editTransactionForm.removeControl('checkNumber');
@@ -1,7 +1,7 @@
/** Angular Imports */
import { Component, OnInit } from '@angular/core';
import { DomSanitizer } from '@angular/platform-browser';
import { FormBuilder, Validators } from '@angular/forms';
import { UntypedFormBuilder, Validators } from '@angular/forms';
import { ActivatedRoute } from '@angular/router';
/** Custom Services */
@@ -43,7 +43,7 @@ export class ExportTransactionsComponent implements OnInit {
*/
constructor(private sanitizer: DomSanitizer,
private reportsService: ReportsService,
private formBuilder: FormBuilder,
private formBuilder: UntypedFormBuilder,
private dateUtils: Dates,
private route: ActivatedRoute,
private settingsService: SettingsService) {