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:
co-authored by
Jose Alberto Hernandez
parent
2dab3b70ca
commit
80936a3ea9
@@ -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 */
|
||||
@@ -17,7 +17,7 @@ import { OrganizationService } from '../../organization.service';
|
||||
export class CreateAdhocQueryComponent implements OnInit {
|
||||
|
||||
/** Adhoc Query form. */
|
||||
adhocQueryForm: FormGroup;
|
||||
adhocQueryForm: UntypedFormGroup;
|
||||
/** Adhoc Query template data. */
|
||||
adhocQueryTemplateData: any;
|
||||
/** Report run frequencies data. */
|
||||
@@ -30,7 +30,7 @@ export class CreateAdhocQueryComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router) {
|
||||
@@ -69,7 +69,7 @@ export class CreateAdhocQueryComponent implements OnInit {
|
||||
setConditionalControls() {
|
||||
this.adhocQueryForm.get('reportRunFrequency').valueChanges.subscribe(reportRunFrequencyId => {
|
||||
if (reportRunFrequencyId === 5) {
|
||||
this.adhocQueryForm.addControl('reportRunEvery', new FormControl('', [Validators.required, Validators.min(1)]));
|
||||
this.adhocQueryForm.addControl('reportRunEvery', new UntypedFormControl('', [Validators.required, Validators.min(1)]));
|
||||
} else {
|
||||
this.adhocQueryForm.removeControl('reportRunEvery');
|
||||
}
|
||||
|
||||
@@ -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 */
|
||||
@@ -17,7 +17,7 @@ import { OrganizationService } from '../../organization.service';
|
||||
export class EditAdhocQueryComponent implements OnInit {
|
||||
|
||||
/** Edit Adhoc Query form. */
|
||||
editAdhocQueryForm: FormGroup;
|
||||
editAdhocQueryForm: UntypedFormGroup;
|
||||
/** Adhoc Query template data. */
|
||||
adhocQueryTemplateData: any;
|
||||
/** Report run frequencies data. */
|
||||
@@ -30,7 +30,7 @@ export class EditAdhocQueryComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router) {
|
||||
@@ -69,7 +69,7 @@ export class EditAdhocQueryComponent implements OnInit {
|
||||
setConditionalControls() {
|
||||
this.editAdhocQueryForm.get('reportRunFrequency').valueChanges.subscribe(reportRunFrequencyId => {
|
||||
if (reportRunFrequencyId === 5) {
|
||||
this.editAdhocQueryForm.addControl('reportRunEvery', new FormControl('', [Validators.required, Validators.min(1)]));
|
||||
this.editAdhocQueryForm.addControl('reportRunEvery', new UntypedFormControl('', [Validators.required, Validators.min(1)]));
|
||||
this.editAdhocQueryForm.get('reportRunEvery').patchValue(this.adhocQueryTemplateData.reportRunEvery);
|
||||
} else {
|
||||
this.editAdhocQueryForm.removeControl('reportRunEvery');
|
||||
|
||||
@@ -4,7 +4,7 @@ import { ActivatedRoute } from '@angular/router';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort } from '@angular/material/sort';
|
||||
import { MatTableDataSource, MatTable } from '@angular/material/table';
|
||||
import { FormGroup, FormBuilder} from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder} from '@angular/forms';
|
||||
|
||||
/** Custom Imports */
|
||||
import { OrganizationService } from '../../organization.service';
|
||||
@@ -29,7 +29,7 @@ export class ViewBulkImportComponent implements OnInit {
|
||||
/** imports Data */
|
||||
importsData: any;
|
||||
/** bulk-import form. */
|
||||
bulkImportForm: FormGroup;
|
||||
bulkImportForm: UntypedFormGroup;
|
||||
/** array of deined bulk-imports */
|
||||
bulkImportsArray = BulkImports;
|
||||
/** bulk-import which user navigated to */
|
||||
@@ -63,7 +63,7 @@ export class ViewBulkImportComponent implements OnInit {
|
||||
* @param {OrganizationService} organizationService OrganizationService
|
||||
*/
|
||||
constructor(private route: ActivatedRoute,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
) {
|
||||
this.bulkImport.name = this.route.snapshot.params['import-name'];
|
||||
|
||||
@@ -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 { ActivatedRoute, Router } from '@angular/router';
|
||||
|
||||
/** Custom Services. */
|
||||
@@ -19,7 +19,7 @@ import { Dates } from 'app/core/utils/dates';
|
||||
export class BulkLoanReassignmnetComponent implements OnInit {
|
||||
|
||||
/** Bulk Loan form. */
|
||||
bulkLoanForm: FormGroup;
|
||||
bulkLoanForm: UntypedFormGroup;
|
||||
/** Office data. */
|
||||
offices: any;
|
||||
/** To Loan Officers. */
|
||||
@@ -45,7 +45,7 @@ export class BulkLoanReassignmnetComponent implements OnInit {
|
||||
* @param {SettingsService} settingsService Settings Service.
|
||||
* @param {Router} router Router.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private organizationSevice: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
@@ -79,7 +79,7 @@ export class BulkLoanReassignmnetComponent implements OnInit {
|
||||
this.organizationSevice.getOfficeTemplate(officeId).subscribe((response: any) => {
|
||||
this.officeTemplate = response;
|
||||
this.fromLoanOfficers = this.officeTemplate.loanOfficerOptions;
|
||||
this.bulkLoanForm.addControl('fromLoanOfficerId', new FormControl('', Validators.required));
|
||||
this.bulkLoanForm.addControl('fromLoanOfficerId', new UntypedFormControl('', Validators.required));
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { FormBuilder, Validators } from '@angular/forms';
|
||||
import { UntypedFormBuilder, Validators } from '@angular/forms';
|
||||
|
||||
/** Custom Dialogs */
|
||||
import { DeleteDialogComponent } from '../../../shared/delete-dialog/delete-dialog.component';
|
||||
@@ -45,7 +45,7 @@ export class ManageCurrenciesComponent implements OnInit, AfterViewInit {
|
||||
* @param {MatDialog} dialog Mat Dialog
|
||||
*/
|
||||
constructor(private route: ActivatedRoute,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private organizationservice: OrganizationService,
|
||||
public dialog: MatDialog,
|
||||
private router: Router,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit , TemplateRef, ElementRef, ViewChild, AfterViewInit } 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 */
|
||||
@@ -29,7 +29,7 @@ export class CreateEmployeeComponent implements OnInit, AfterViewInit {
|
||||
/** Maximum joining date allowed. */
|
||||
maxDate = new Date();
|
||||
/** Employee form. */
|
||||
employeeForm: FormGroup;
|
||||
employeeForm: UntypedFormGroup;
|
||||
/** Office data. */
|
||||
officeData: any;
|
||||
|
||||
@@ -50,7 +50,7 @@ export class CreateEmployeeComponent implements OnInit, AfterViewInit {
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
* @param {MatDialog} dialog MatDialog.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private route: ActivatedRoute,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
|
||||
|
||||
/** Custom Services */
|
||||
import { OrganizationService } from '../../organization.service';
|
||||
@@ -25,7 +25,7 @@ export class EditEmployeeComponent implements OnInit {
|
||||
/** Maximum joining date allowed. */
|
||||
maxDate = new Date();
|
||||
/** Employee form. */
|
||||
editEmployeeForm: FormGroup;
|
||||
editEmployeeForm: UntypedFormGroup;
|
||||
/** Office data. */
|
||||
officeData: any;
|
||||
|
||||
@@ -38,7 +38,7 @@ export class EditEmployeeComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
* @param {Dates} dateUtils Date Utils to format date.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private route: ActivatedRoute,
|
||||
|
||||
+5
-5
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports. */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';
|
||||
import { UntypedFormBuilder, UntypedFormGroup, Validators, UntypedFormControl } from '@angular/forms';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
|
||||
/** Custom Services. */
|
||||
@@ -17,7 +17,7 @@ import { OrganizationService } from 'app/organization/organization.service';
|
||||
export class CreateEnityDataTableChecksComponent implements OnInit {
|
||||
|
||||
/** Create Entity Datatable Checks form. */
|
||||
createEntityForm: FormGroup;
|
||||
createEntityForm: UntypedFormGroup;
|
||||
/** Entity Datatable Checks data. */
|
||||
createEntityData: any;
|
||||
/** Selected entity type. */
|
||||
@@ -36,7 +36,7 @@ export class CreateEnityDataTableChecksComponent implements OnInit {
|
||||
* @param {OrganizationService} organizationService Organization Service.
|
||||
* @param {Router} router Router.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private organizationService: OrganizationService,
|
||||
private router: Router) {
|
||||
@@ -85,7 +85,7 @@ export class CreateEnityDataTableChecksComponent implements OnInit {
|
||||
this.entityType = 'm_loan';
|
||||
this.dataTableList = this.createEntityData.datatables.filter((data: any) => data.entity === 'm_loan');
|
||||
this.statusList = this.createEntityData.statusLoans;
|
||||
this.createEntityForm.addControl('productId', new FormControl('', Validators.required));
|
||||
this.createEntityForm.addControl('productId', new UntypedFormControl('', Validators.required));
|
||||
break;
|
||||
}
|
||||
case 'm_group': {
|
||||
@@ -99,7 +99,7 @@ export class CreateEnityDataTableChecksComponent implements OnInit {
|
||||
this.entityType = 'm_savings_account';
|
||||
this.dataTableList = this.createEntityData.datatables.filter((data: any) => data.entity === 'm_savings_account');
|
||||
this.statusList = this.createEntityData.statusSavings;
|
||||
this.createEntityForm.addControl('productId', new FormControl('', Validators.required));
|
||||
this.createEntityForm.addControl('productId', new UntypedFormControl('', Validators.required));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { FormGroup, FormBuilder, FormControl, Validators } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, UntypedFormControl, Validators } from '@angular/forms';
|
||||
import { ActivatedRoute } from '@angular/router';
|
||||
|
||||
/** Custom Services */
|
||||
@@ -26,7 +26,7 @@ export class FundMappingComponent implements OnInit {
|
||||
/** Maximum Date allowed. */
|
||||
maxDate = new Date();
|
||||
/** Fund mapping form. */
|
||||
fundMappingForm: FormGroup;
|
||||
fundMappingForm: UntypedFormGroup;
|
||||
/** Advance Search Template */
|
||||
advanceSearchTemplate: any;
|
||||
/** Toggles b/w form and table */
|
||||
@@ -50,7 +50,7 @@ export class FundMappingComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
* @param {Dates} dateUtils Date Utils to format date.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private route: ActivatedRoute,
|
||||
@@ -88,14 +88,14 @@ export class FundMappingComponent implements OnInit {
|
||||
buildDependencies() {
|
||||
this.fundMappingForm.get('includeOutStandingAmountPercentage').valueChanges.subscribe((value: boolean) => {
|
||||
if (value) {
|
||||
this.fundMappingForm.addControl('outStandingAmountPercentageCondition', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('outStandingAmountPercentageCondition', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.get('outStandingAmountPercentageCondition').valueChanges.subscribe((_value: string) => {
|
||||
if (_value === 'between') {
|
||||
this.fundMappingForm.addControl('minOutStandingAmountPercentage', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('maxOutStandingAmountPercentage', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('minOutStandingAmountPercentage', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('maxOutStandingAmountPercentage', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.removeControl('outStandingAmountPercentage');
|
||||
} else {
|
||||
this.fundMappingForm.addControl('outStandingAmountPercentage', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('outStandingAmountPercentage', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.removeControl('minOutStandingAmountPercentage');
|
||||
this.fundMappingForm.removeControl('maxOutStandingAmountPercentage');
|
||||
}
|
||||
@@ -111,14 +111,14 @@ export class FundMappingComponent implements OnInit {
|
||||
this.fundMappingForm.get('includeOutStandingAmountPercentage').patchValue(true);
|
||||
this.fundMappingForm.get('includeOutstandingAmount').valueChanges.subscribe((value: boolean) => {
|
||||
if (value) {
|
||||
this.fundMappingForm.addControl('outstandingAmountCondition', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('outstandingAmountCondition', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.get('outstandingAmountCondition').valueChanges.subscribe((_value: string) => {
|
||||
if (_value === 'between') {
|
||||
this.fundMappingForm.addControl('minOutstandingAmount', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('maxOutstandingAmount', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('minOutstandingAmount', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('maxOutstandingAmount', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.removeControl('outstandingAmount');
|
||||
} else {
|
||||
this.fundMappingForm.addControl('outstandingAmount', new FormControl('', Validators.required));
|
||||
this.fundMappingForm.addControl('outstandingAmount', new UntypedFormControl('', Validators.required));
|
||||
this.fundMappingForm.removeControl('minOutstandingAmount');
|
||||
this.fundMappingForm.removeControl('maxOutstandingAmount');
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/** Angular Imports. */
|
||||
import { SelectionModel } from '@angular/cdk/collections';
|
||||
import { Component, OnInit, ViewChild, Injectable } from '@angular/core';
|
||||
import { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';
|
||||
import { UntypedFormBuilder, UntypedFormGroup, Validators, UntypedFormControl } from '@angular/forms';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { MatTreeFlatDataSource, MatTreeFlattener } from '@angular/material/tree';
|
||||
@@ -26,7 +26,7 @@ import { CreateHoliday } from './create-holiday.service';
|
||||
export class CreateHolidayComponent implements OnInit {
|
||||
|
||||
/** Create Holiday form. */
|
||||
holidayForm: FormGroup;
|
||||
holidayForm: UntypedFormGroup;
|
||||
/** Repayment Scheduling data. */
|
||||
repaymentSchedulingTypes: any;
|
||||
/** Offices Data */
|
||||
@@ -73,7 +73,7 @@ export class CreateHolidayComponent implements OnInit {
|
||||
* @param {OrganizationService} organizationService Organization Service.
|
||||
* @param {Router} router Router.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private dateUtils: Dates,
|
||||
private organizationService: OrganizationService,
|
||||
@@ -271,7 +271,7 @@ export class CreateHolidayComponent implements OnInit {
|
||||
buildDependencies() {
|
||||
this.holidayForm.get('reschedulingType').valueChanges.subscribe((option: any) => {
|
||||
if (option === 2) {
|
||||
this.holidayForm.addControl('repaymentsRescheduledTo', new FormControl('', Validators.required));
|
||||
this.holidayForm.addControl('repaymentsRescheduledTo', new UntypedFormControl('', Validators.required));
|
||||
} else {
|
||||
this.holidayForm.removeControl('repaymentsRescheduledTo');
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports. */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { FormBuilder, FormGroup, Validators, FormControl } from '@angular/forms';
|
||||
import { UntypedFormBuilder, UntypedFormGroup, Validators, UntypedFormControl } 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 EditHolidayComponent implements OnInit {
|
||||
|
||||
/** Edit Holiday form. */
|
||||
holidayForm: FormGroup;
|
||||
holidayForm: UntypedFormGroup;
|
||||
/** Holiday data. */
|
||||
holidayData: any;
|
||||
/** Rescheduling Type. */
|
||||
@@ -39,7 +39,7 @@ export class EditHolidayComponent implements OnInit {
|
||||
* @param {OrganizationService} organizatioService Organization Service.
|
||||
* @param {Router} router Router.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private dateUtils: Dates,
|
||||
private organizatioService: OrganizationService,
|
||||
@@ -74,11 +74,11 @@ export class EditHolidayComponent implements OnInit {
|
||||
'description': [this.holidayData.description]
|
||||
});
|
||||
if (!this.isActiveHoliday) {
|
||||
this.holidayForm.addControl('fromDate', new FormControl(this.holidayData.fromDate && new Date(this.holidayData.fromDate), Validators.required));
|
||||
this.holidayForm.addControl('toDate', new FormControl(this.holidayData.toDate && new Date(this.holidayData.toDate), Validators.required));
|
||||
this.holidayForm.addControl('reschedulingType', new FormControl(this.holidayData.reschedulingType, Validators.required));
|
||||
this.holidayForm.addControl('fromDate', new UntypedFormControl(this.holidayData.fromDate && new Date(this.holidayData.fromDate), Validators.required));
|
||||
this.holidayForm.addControl('toDate', new UntypedFormControl(this.holidayData.toDate && new Date(this.holidayData.toDate), Validators.required));
|
||||
this.holidayForm.addControl('reschedulingType', new UntypedFormControl(this.holidayData.reschedulingType, Validators.required));
|
||||
if (this.reSchedulingType === 2) {
|
||||
this.holidayForm.addControl('repaymentsRescheduledTo', new FormControl(this.holidayData.repaymentsRescheduledTo && new Date(this.holidayData.repaymentsRescheduledTo), Validators.required));
|
||||
this.holidayForm.addControl('repaymentsRescheduledTo', new UntypedFormControl(this.holidayData.repaymentsRescheduledTo && new Date(this.holidayData.repaymentsRescheduledTo), Validators.required));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -90,7 +90,7 @@ export class EditHolidayComponent implements OnInit {
|
||||
this.holidayForm.get('reschedulingType').valueChanges.subscribe( (option: any) => {
|
||||
this.reSchedulingType = option;
|
||||
if (option === 2) {
|
||||
this.holidayForm.addControl('repaymentsRescheduledTo', new FormControl(new Date(), Validators.required));
|
||||
this.holidayForm.addControl('repaymentsRescheduledTo', new UntypedFormControl(new Date(), Validators.required));
|
||||
} else {
|
||||
this.holidayForm.removeControl('repaymentsRescheduledTo');
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { FormControl } from '@angular/forms';
|
||||
import { UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/** rxjs Imports */
|
||||
import { of } from 'rxjs';
|
||||
@@ -25,7 +25,7 @@ import { ConfigurationWizardService } from '../../configuration-wizard/configura
|
||||
export class HolidaysComponent implements OnInit, AfterViewInit {
|
||||
|
||||
/** Office selector. */
|
||||
officeSelector = new FormControl();
|
||||
officeSelector = new UntypedFormControl();
|
||||
/** Holidays data. */
|
||||
holidaysData: any;
|
||||
/** Offices data. */
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { animate, state, style, transition, trigger } from '@angular/animations';
|
||||
import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { FormControl } from '@angular/forms';
|
||||
import { UntypedFormControl } from '@angular/forms';
|
||||
import { MatPaginator, PageEvent } from '@angular/material/paginator';
|
||||
import { MatSort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
@@ -29,11 +29,11 @@ export class InvestorsComponent implements OnInit {
|
||||
maxDate = new Date();
|
||||
|
||||
searchResults: any[] = [];
|
||||
searchText = new FormControl('');
|
||||
effectiveFromDate = new FormControl('');
|
||||
effectiveToDate = new FormControl('');
|
||||
settlementFromDate = new FormControl('');
|
||||
settlementToDate = new FormControl('');
|
||||
searchText = new UntypedFormControl('');
|
||||
effectiveFromDate = new UntypedFormControl('');
|
||||
effectiveToDate = new UntypedFormControl('');
|
||||
settlementFromDate = new UntypedFormControl('');
|
||||
settlementToDate = new UntypedFormControl('');
|
||||
|
||||
dataSource: MatTableDataSource<any> = new MatTableDataSource();
|
||||
existsDataToFilter = false;
|
||||
@@ -53,7 +53,7 @@ export class InvestorsComponent implements OnInit {
|
||||
@ViewChild(MatSort) sort: MatSort;
|
||||
|
||||
/** Entry type filter form control. */
|
||||
entryTypeFilter = new FormControl('');
|
||||
entryTypeFilter = new UntypedFormControl('');
|
||||
/** Entry type filter data. */
|
||||
entryTypeFilterData = [
|
||||
{
|
||||
|
||||
+3
-3
@@ -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 { MatDialog } from '@angular/material/dialog';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
@@ -28,7 +28,7 @@ import { SettingsService } from 'app/settings/settings.service';
|
||||
export class CreateLoanProvisioningCriteriaComponent implements OnInit {
|
||||
|
||||
/** Loan Provisioning Criteria form. */
|
||||
provisioningCriteriaForm: FormGroup;
|
||||
provisioningCriteriaForm: UntypedFormGroup;
|
||||
/** Loan Provisioning Criteria Template */
|
||||
loanProvisioningCriteriaTemplate: any;
|
||||
/** Liability Accounts */
|
||||
@@ -59,7 +59,7 @@ export class CreateLoanProvisioningCriteriaComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private router: Router,
|
||||
|
||||
+3
-3
@@ -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 { MatDialog } from '@angular/material/dialog';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
@@ -28,7 +28,7 @@ import { SettingsService } from 'app/settings/settings.service';
|
||||
export class EditLoanProvisioningCriteriaComponent implements OnInit {
|
||||
|
||||
/** Loan Provisioning Criteria form. */
|
||||
provisioningCriteriaForm: FormGroup;
|
||||
provisioningCriteriaForm: UntypedFormGroup;
|
||||
/** Loan Provisioning Criteria Template */
|
||||
loanProvisioningCriteriaAndTemplate: any;
|
||||
/** Liability Accounts */
|
||||
@@ -59,7 +59,7 @@ export class EditLoanProvisioningCriteriaComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private router: Router,
|
||||
private settingsService: SettingsService,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Component, 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 { OrganizationService } from 'app/organization/organization.service';
|
||||
|
||||
@@ -11,7 +11,7 @@ import { OrganizationService } from 'app/organization/organization.service';
|
||||
export class CreateFundComponent implements OnInit {
|
||||
|
||||
/** Charge form. */
|
||||
fundForm: FormGroup;
|
||||
fundForm: UntypedFormGroup;
|
||||
|
||||
/**
|
||||
* Retrieves the charge data from `resolve`.
|
||||
@@ -21,7 +21,7 @@ export class CreateFundComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private organizationService: OrganizationService,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private router: Router,
|
||||
private route: ActivatedRoute) {
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Component, 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 { OrganizationService } from 'app/organization/organization.service';
|
||||
|
||||
@@ -13,7 +13,7 @@ export class EditFundComponent implements OnInit {
|
||||
/** Selected Data. */
|
||||
fundData: any;
|
||||
/** Charge form. */
|
||||
fundForm: FormGroup;
|
||||
fundForm: UntypedFormGroup;
|
||||
|
||||
/**
|
||||
* Retrieves the charge data from `resolve`.
|
||||
@@ -23,7 +23,7 @@ export class EditFundComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private organizationService: OrganizationService,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private router: Router,
|
||||
private route: ActivatedRoute) {
|
||||
this.route.data.subscribe((data: { fundData: any }) => {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { FormBuilder, Validators } from '@angular/forms';
|
||||
import { UntypedFormBuilder, Validators } from '@angular/forms';
|
||||
|
||||
/** Custom Dialogs */
|
||||
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
|
||||
@@ -64,7 +64,7 @@ export class ManageFundsComponent implements OnInit, AfterViewInit {
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
*/
|
||||
constructor(private route: ActivatedRoute,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private organizationservice: OrganizationService,
|
||||
public dialog: MatDialog,
|
||||
private router: Router,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, TemplateRef, ElementRef , ViewChild,
|
||||
AfterViewInit } 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 */
|
||||
@@ -26,7 +26,7 @@ import { ContinueSetupDialogComponent } from '../../../configuration-wizard/cont
|
||||
export class CreateOfficeComponent implements OnInit, AfterViewInit {
|
||||
|
||||
/** Office form. */
|
||||
officeForm: FormGroup;
|
||||
officeForm: UntypedFormGroup;
|
||||
/** Office Data */
|
||||
officeData: any;
|
||||
/** Minimum Date allowed. */
|
||||
@@ -51,7 +51,7 @@ export class CreateOfficeComponent implements OnInit, AfterViewInit {
|
||||
* @param {ConfigurationWizardService} configurationWizardService ConfigurationWizard Service.
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private router: Router,
|
||||
|
||||
@@ -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 { ActivatedRoute, Router } from '@angular/router';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
|
||||
@@ -21,7 +21,7 @@ export class EditOfficeComponent implements OnInit {
|
||||
/** Selected Data. */
|
||||
officeData: any;
|
||||
/** Office form. */
|
||||
officeForm: FormGroup;
|
||||
officeForm: UntypedFormGroup;
|
||||
/** Minimum Date allowed. */
|
||||
minDate = new Date(2000, 0, 1);
|
||||
/** Maximum Date allowed. */
|
||||
@@ -39,7 +39,7 @@ export class EditOfficeComponent implements OnInit {
|
||||
*/
|
||||
constructor(private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private dateUtils: Dates) {
|
||||
|
||||
@@ -11,7 +11,7 @@ import { of } from 'rxjs';
|
||||
/** Custom Services */
|
||||
import { PopoverService } from '../../configuration-wizard/popover/popover.service';
|
||||
import { ConfigurationWizardService } from '../../configuration-wizard/configuration-wizard.service';
|
||||
import { FormControl } from '@angular/forms';
|
||||
import { UntypedFormControl } from '@angular/forms';
|
||||
import { OfficeNode } from './office-node.model';
|
||||
import { NestedTreeControl } from '@angular/cdk/tree';
|
||||
import { MatTreeNestedDataSource } from '@angular/material/tree';
|
||||
@@ -27,7 +27,7 @@ import { OfficeTreeService } from './office-tree-service.service';
|
||||
})
|
||||
export class OfficesComponent implements OnInit, AfterViewInit {
|
||||
/** Button toggle group form control for type of view. (list/tree) */
|
||||
viewGroup = new FormControl('listView');
|
||||
viewGroup = new UntypedFormControl('listView');
|
||||
|
||||
/** Offices data. */
|
||||
officesData: any;
|
||||
|
||||
@@ -78,8 +78,6 @@ import { CreateFundComponent } from './manage-funds/create-fund/create-fund.comp
|
||||
import { EditFundComponent } from './manage-funds/edit-fund/edit-fund.component';
|
||||
import { ViewFundComponent } from './manage-funds/view-fund/view-fund.component';
|
||||
import { InvestorsComponent } from './investors/investors.component';
|
||||
import { ExternalAssetTransferComponent } from 'app/loans/loans-view/external-asset-owner-tab/external-asset-transfer/external-asset-transfer.component';
|
||||
import { LoansModule } from 'app/loans/loans.module';
|
||||
|
||||
|
||||
/**
|
||||
@@ -92,8 +90,7 @@ import { LoansModule } from 'app/loans/loans.module';
|
||||
SharedModule,
|
||||
PipesModule,
|
||||
DirectivesModule,
|
||||
OrganizationRoutingModule,
|
||||
LoansModule
|
||||
OrganizationRoutingModule
|
||||
],
|
||||
declarations: [
|
||||
OrganizationComponent,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { FormGroup, FormBuilder } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder } from '@angular/forms';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
|
||||
/** Custom Services */
|
||||
@@ -17,7 +17,7 @@ import { OrganizationService } from '../organization.service';
|
||||
export class PasswordPreferencesComponent implements OnInit {
|
||||
|
||||
/** Password preferences form. */
|
||||
passwordPreferencesForm: FormGroup;
|
||||
passwordPreferencesForm: UntypedFormGroup;
|
||||
/** Password preferences data. */
|
||||
passwordPreferencesData: any;
|
||||
|
||||
@@ -28,7 +28,7 @@ export class PasswordPreferencesComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router) {
|
||||
|
||||
+3
-3
@@ -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 */
|
||||
@@ -17,7 +17,7 @@ import { OrganizationService } from '../../organization.service';
|
||||
export class CreatePaymentTypeComponent implements OnInit {
|
||||
|
||||
/** Payment Type form. */
|
||||
paymentTypeForm: FormGroup;
|
||||
paymentTypeForm: UntypedFormGroup;
|
||||
|
||||
/**
|
||||
* @param {FormBuilder} formBuilder Form Builder.
|
||||
@@ -25,7 +25,7 @@ export class CreatePaymentTypeComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private router: Router,
|
||||
private route: ActivatedRoute) {}
|
||||
|
||||
@@ -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 */
|
||||
@@ -17,7 +17,7 @@ import { OrganizationService } from 'app/organization/organization.service';
|
||||
export class EditPaymentTypeComponent implements OnInit {
|
||||
|
||||
/** Payment Type form. */
|
||||
paymentTypeForm: FormGroup;
|
||||
paymentTypeForm: UntypedFormGroup;
|
||||
/** Payment Type Data. */
|
||||
paymentTypeData: any;
|
||||
|
||||
@@ -28,7 +28,7 @@ export class EditPaymentTypeComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private router: Router,
|
||||
private route: ActivatedRoute) {
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, Input, OnChanges } from '@angular/core';
|
||||
import { FormControl } from '@angular/forms';
|
||||
import { UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/**
|
||||
* Campaign Message Step
|
||||
@@ -20,7 +20,7 @@ export class CampaignMessageStepComponent implements OnChanges {
|
||||
@Input() editCampaignMessage: any;
|
||||
|
||||
/** Camapaign Message */
|
||||
message = new FormControl('');
|
||||
message = new UntypedFormControl('');
|
||||
/** Column header names */
|
||||
parameterLabels: any[];
|
||||
|
||||
|
||||
+6
-6
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnChanges, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
||||
import { Validators, FormGroup, FormControl } from '@angular/forms';
|
||||
import { Validators, UntypedFormGroup, UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/** Rxjs Imports */
|
||||
import { distinctUntilChanged } from 'rxjs/operators';
|
||||
@@ -32,7 +32,7 @@ export class EditBusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
@Output() templateParameters = new EventEmitter();
|
||||
|
||||
/** Initializes new form group ReportForm */
|
||||
ReportForm = new FormGroup({});
|
||||
ReportForm = new UntypedFormGroup({});
|
||||
/** Array of all parent parameters */
|
||||
parentParameters: any[] = [];
|
||||
/** Displayed user choices */
|
||||
@@ -56,7 +56,7 @@ export class EditBusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
|
||||
ngOnChanges() {
|
||||
if (this.paramData) {
|
||||
this.ReportForm = new FormGroup({});
|
||||
this.ReportForm = new UntypedFormGroup({});
|
||||
this.paramValue = JSON.parse(this.smsCampaign.paramValue);
|
||||
this.createRunReportForm();
|
||||
this.disableFormWhenValid();
|
||||
@@ -72,7 +72,7 @@ export class EditBusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
this.paramData.forEach(
|
||||
(param: any) => {
|
||||
if (!param.parentParameterName) { // Non Child Parameter
|
||||
this.ReportForm.addControl(param.name, new FormControl('', Validators.required));
|
||||
this.ReportForm.addControl(param.name, new UntypedFormControl('', Validators.required));
|
||||
const controlValue = this.paramValue[param.variable].toString();
|
||||
switch (param.displayType) {
|
||||
case 'text':
|
||||
@@ -119,9 +119,9 @@ export class EditBusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
this.ReportForm.get(param.name).valueChanges.subscribe((option: any) => {
|
||||
param.childParameters.forEach((child: ReportParameter) => {
|
||||
if (child.displayType === 'none') {
|
||||
this.ReportForm.addControl(child.name, new FormControl(child.defaultVal));
|
||||
this.ReportForm.addControl(child.name, new UntypedFormControl(child.defaultVal));
|
||||
} else {
|
||||
this.ReportForm.addControl(child.name, new FormControl('', Validators.required));
|
||||
this.ReportForm.addControl(child.name, new UntypedFormControl('', Validators.required));
|
||||
}
|
||||
if (child.displayType === 'select') {
|
||||
const inputstring = `${child.name}?${param.inputName}=${option.id}`;
|
||||
|
||||
+4
-4
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, Output, Input, EventEmitter } from '@angular/core';
|
||||
import { FormGroup, Validators, FormBuilder, FormControl } from '@angular/forms';
|
||||
import { UntypedFormGroup, Validators, UntypedFormBuilder, UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/** Custom Services */
|
||||
import { ReportsService } from 'app/reports/reports.service';
|
||||
@@ -25,7 +25,7 @@ export class EditSmsCampaignStepComponent implements OnInit {
|
||||
@Input() smsCampaign: any;
|
||||
|
||||
/** SMS Campaign Form */
|
||||
smsCampaignDetailsForm: FormGroup;
|
||||
smsCampaignDetailsForm: UntypedFormGroup;
|
||||
/** Data to be passed to sub component */
|
||||
paramData: any;
|
||||
/** Trigger types options */
|
||||
@@ -49,7 +49,7 @@ export class EditSmsCampaignStepComponent implements OnInit {
|
||||
* @param {ReportsService} reportService Reports Service
|
||||
* @param {SettingsService} settingsService Settings Service.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private reportService: ReportsService,
|
||||
private settingsService: SettingsService) {
|
||||
this.createSMSCampaignDetailsForm();
|
||||
@@ -107,7 +107,7 @@ export class EditSmsCampaignStepComponent implements OnInit {
|
||||
'isNotification': this.smsCampaign.isNotification
|
||||
});
|
||||
if (this.smsCampaign.triggerType.value === 'Schedule') {
|
||||
this.smsCampaignDetailsForm.addControl('recurrenceStartDate', new FormControl(new Date(this.smsCampaign.recurrenceStartDate)));
|
||||
this.smsCampaignDetailsForm.addControl('recurrenceStartDate', new UntypedFormControl(new Date(this.smsCampaign.recurrenceStartDate)));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+6
-6
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnChanges, Input, Output, EventEmitter, OnInit } from '@angular/core';
|
||||
import { Validators, FormGroup, FormControl } from '@angular/forms';
|
||||
import { Validators, UntypedFormGroup, UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/** Custom Services */
|
||||
import { ReportsService } from 'app/reports/reports.service';
|
||||
@@ -27,7 +27,7 @@ export class BusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
/** Report Name */
|
||||
reportName: string;
|
||||
/** Initializes new form group ReportForm */
|
||||
ReportForm = new FormGroup({});
|
||||
ReportForm = new UntypedFormGroup({});
|
||||
/** Array of all parent parameters */
|
||||
parentParameters: any[] = [];
|
||||
/** Minimum Date allowed. */
|
||||
@@ -53,7 +53,7 @@ export class BusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
|
||||
ngOnChanges() {
|
||||
if (this.paramData) {
|
||||
this.ReportForm = new FormGroup({});
|
||||
this.ReportForm = new UntypedFormGroup({});
|
||||
this.reportName = this.paramData.reportName;
|
||||
this.paramData = this.paramData.response;
|
||||
this.createRunReportForm();
|
||||
@@ -77,7 +77,7 @@ export class BusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
this.paramData.forEach(
|
||||
(param: any) => {
|
||||
if (!param.parentParameterName) { // Non-Child Parameter
|
||||
this.ReportForm.addControl(param.name, new FormControl('', Validators.required));
|
||||
this.ReportForm.addControl(param.name, new UntypedFormControl('', Validators.required));
|
||||
if (param.displayType === 'select') {
|
||||
this.fetchSelectOptions(param, param.name);
|
||||
}
|
||||
@@ -113,9 +113,9 @@ export class BusinessRuleParametersComponent implements OnInit, OnChanges {
|
||||
this.ReportForm.get(param.name).valueChanges.subscribe((option: any) => {
|
||||
param.childParameters.forEach((child: ReportParameter) => {
|
||||
if (child.displayType === 'none') {
|
||||
this.ReportForm.addControl(child.name, new FormControl(child.defaultVal));
|
||||
this.ReportForm.addControl(child.name, new UntypedFormControl(child.defaultVal));
|
||||
} else {
|
||||
this.ReportForm.addControl(child.name, new FormControl('', Validators.required));
|
||||
this.ReportForm.addControl(child.name, new UntypedFormControl('', Validators.required));
|
||||
}
|
||||
if (child.displayType === 'select') {
|
||||
const inputstring = `${child.name}?${param.inputName}=${option.id}`;
|
||||
|
||||
+11
-11
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, Input, ViewChild, EventEmitter, Output} from '@angular/core';
|
||||
import { FormGroup, FormBuilder, Validators, FormControl } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/** Custom Services */
|
||||
import { ReportsService } from 'app/reports/reports.service';
|
||||
@@ -32,7 +32,7 @@ export class SmsCampaignStepComponent implements OnInit {
|
||||
maxDate = new Date(new Date().setFullYear(new Date().getFullYear() + 10));
|
||||
|
||||
/** SMS Campaign Form */
|
||||
smsCampaignDetailsForm: FormGroup;
|
||||
smsCampaignDetailsForm: UntypedFormGroup;
|
||||
/** Data to be passed to sub component */
|
||||
paramData: any;
|
||||
/** Trigger types options */
|
||||
@@ -51,7 +51,7 @@ export class SmsCampaignStepComponent implements OnInit {
|
||||
* @param {FormBuilder} formBuilder Form Builder
|
||||
* @param {ReportsService} reportService Reports Service
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private reportService: ReportsService) {
|
||||
this.createSMSCampaignDetailsForm();
|
||||
this.buildDependencies();
|
||||
@@ -70,14 +70,14 @@ export class SmsCampaignStepComponent implements OnInit {
|
||||
* Else returns a cumulative form group.
|
||||
*/
|
||||
get smsCampaignFormGroup() {
|
||||
let smsCampaignFormGroup: FormGroup;
|
||||
let smsCampaignFormGroup: UntypedFormGroup;
|
||||
if (this.businessRuleParametersComponent) {
|
||||
smsCampaignFormGroup = new FormGroup({
|
||||
smsCampaignFormGroup = new UntypedFormGroup({
|
||||
smsCampaign: this.smsCampaignDetailsForm,
|
||||
businessRule: this.businessRuleParametersComponent.ReportForm
|
||||
});
|
||||
} else {
|
||||
smsCampaignFormGroup = new FormGroup({
|
||||
smsCampaignFormGroup = new UntypedFormGroup({
|
||||
smsCampaign: this.smsCampaignDetailsForm
|
||||
});
|
||||
}
|
||||
@@ -127,7 +127,7 @@ export class SmsCampaignStepComponent implements OnInit {
|
||||
buildDependencies() {
|
||||
this.smsCampaignDetailsForm.get('isNotification').valueChanges.subscribe((value: boolean) => {
|
||||
if (!value) {
|
||||
this.smsCampaignDetailsForm.addControl('providerId', new FormControl(null));
|
||||
this.smsCampaignDetailsForm.addControl('providerId', new UntypedFormControl(null));
|
||||
} else {
|
||||
this.smsCampaignDetailsForm.removeControl('providerId');
|
||||
}
|
||||
@@ -152,9 +152,9 @@ export class SmsCampaignStepComponent implements OnInit {
|
||||
this.businessRules = this.businessRules.filter((rule: any) => rule.reportSubType !== 'Triggered');
|
||||
}
|
||||
if (value === 2) {
|
||||
this.smsCampaignDetailsForm.addControl('recurrenceStartDate', new FormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.addControl('frequency', new FormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.addControl('interval', new FormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.addControl('recurrenceStartDate', new UntypedFormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.addControl('frequency', new UntypedFormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.addControl('interval', new UntypedFormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.get('frequency').valueChanges.subscribe((frequency: number) => {
|
||||
this.smsCampaignDetailsForm.removeControl('repeatsOnDay');
|
||||
switch (frequency) {
|
||||
@@ -163,7 +163,7 @@ export class SmsCampaignStepComponent implements OnInit {
|
||||
break;
|
||||
case 2: // Weekly
|
||||
this.repetitionIntervals = ['1', '2', '3'];
|
||||
this.smsCampaignDetailsForm.addControl('repeatsOnDay', new FormControl('', Validators.required));
|
||||
this.smsCampaignDetailsForm.addControl('repeatsOnDay', new UntypedFormControl('', Validators.required));
|
||||
break;
|
||||
case 3: // Monthly
|
||||
this.repetitionIntervals = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11'];
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { FormGroup, FormBuilder } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder } from '@angular/forms';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { MatTableDataSource, MatTable } from '@angular/material/table';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
@@ -33,7 +33,7 @@ export class ViewCampaignComponent implements OnInit {
|
||||
/** Maximum date allowed. */
|
||||
maxDate = new Date();
|
||||
/** SMS form. */
|
||||
smsForm: FormGroup;
|
||||
smsForm: UntypedFormGroup;
|
||||
/** SMS Campaign data. */
|
||||
smsCampaignData: any;
|
||||
/** Message Status */
|
||||
@@ -83,7 +83,7 @@ export class ViewCampaignComponent implements OnInit {
|
||||
constructor(private router: Router,
|
||||
private route: ActivatedRoute,
|
||||
public dialog: MatDialog,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private dateUtils: Dates,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService) {
|
||||
|
||||
+4
-4
@@ -3,7 +3,7 @@ import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort } from '@angular/material/sort';
|
||||
import { MatTableDataSource, MatTable } from '@angular/material/table';
|
||||
import { FormGroup, FormBuilder, FormControl } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, UntypedFormControl } from '@angular/forms';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
|
||||
/** Custom Services */
|
||||
@@ -26,7 +26,7 @@ export class StandingInstructionsHistoryComponent implements OnInit {
|
||||
/** Maximum Date allowed. */
|
||||
maxDate = new Date();
|
||||
/** Instruction form. */
|
||||
instructionForm: FormGroup;
|
||||
instructionForm: UntypedFormGroup;
|
||||
/** Standing Instructions Template */
|
||||
standingInstructionsTemplate: any;
|
||||
/** Toggles b/w form and table */
|
||||
@@ -51,7 +51,7 @@ export class StandingInstructionsHistoryComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
* @param {Dates} dateUtils Date Utils to format date.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private router: Router,
|
||||
@@ -87,7 +87,7 @@ export class StandingInstructionsHistoryComponent implements OnInit {
|
||||
*/
|
||||
buildDependencies() {
|
||||
this.instructionForm.get('fromAccountType').valueChanges.subscribe(() => {
|
||||
this.instructionForm.addControl('fromAccountId', new FormControl(''));
|
||||
this.instructionForm.addControl('fromAccountId', new UntypedFormControl(''));
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports. */
|
||||
import { Component, 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';
|
||||
|
||||
@@ -25,7 +25,7 @@ export class AllocateCashComponent implements OnInit {
|
||||
/** Cashier data. */
|
||||
cashierData: any;
|
||||
/** Cashier Form. */
|
||||
allocateCashForm: FormGroup;
|
||||
allocateCashForm: UntypedFormGroup;
|
||||
|
||||
/**
|
||||
* Get cashier data from `Resolver`.
|
||||
@@ -36,7 +36,7 @@ export class AllocateCashComponent implements OnInit {
|
||||
* @param {SettingsService} settingsService Settings Service.
|
||||
* @param {Router} router Router.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private dateUtils: Dates,
|
||||
private organizationService: OrganizationService,
|
||||
|
||||
@@ -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 { ActivatedRoute, Router } from '@angular/router';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
|
||||
@@ -25,7 +25,7 @@ export class CreateCashierComponent implements OnInit {
|
||||
/** Cashier Template. */
|
||||
cashierTemplate: any;
|
||||
/** Create cashier form. */
|
||||
createCashierForm: FormGroup;
|
||||
createCashierForm: UntypedFormGroup;
|
||||
|
||||
/**
|
||||
* Fetches cashier template from `resolve`
|
||||
@@ -36,7 +36,7 @@ export class CreateCashierComponent implements OnInit {
|
||||
* @param {OrganizationService} organizationService Organization Service.
|
||||
* @param {SettingsService} settingsService Settings Service.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private dateUtils: Dates,
|
||||
|
||||
@@ -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 { ActivatedRoute, Router } from '@angular/router';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
|
||||
@@ -21,7 +21,7 @@ export class EditCashierComponent implements OnInit {
|
||||
/** Cashier Data. */
|
||||
cashierData: any = new Object();
|
||||
/** Edit cashier form. */
|
||||
editCashierForm: FormGroup;
|
||||
editCashierForm: UntypedFormGroup;
|
||||
/** Is Staff ID present. */
|
||||
isStaffId = true;
|
||||
/** Minimum Date allowed. */
|
||||
@@ -38,7 +38,7 @@ export class EditCashierComponent implements OnInit {
|
||||
* @param {OrganizationService} organizationService Organization Service.
|
||||
* @param {SettingsService} settingsService Settings Service.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private dateUtils: Dates,
|
||||
|
||||
@@ -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 { ActivatedRoute, Router } from '@angular/router';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
|
||||
@@ -22,7 +22,7 @@ export class SettleCashComponent implements OnInit {
|
||||
/** Cashier data. */
|
||||
cashierData: any;
|
||||
/** Cashier Form. */
|
||||
settleCashForm: FormGroup;
|
||||
settleCashForm: UntypedFormGroup;
|
||||
|
||||
/**
|
||||
* Get cashier data from `Resolver`.
|
||||
@@ -33,7 +33,7 @@ export class SettleCashComponent implements OnInit {
|
||||
* @param {SettingsService} settingsService Settings Service.
|
||||
* @param {Router} router Router.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private dateUtils: Dates,
|
||||
private organizationService: OrganizationService,
|
||||
|
||||
@@ -4,7 +4,7 @@ import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { ActivatedRoute } from '@angular/router';
|
||||
import { FormControl } from '@angular/forms';
|
||||
import { UntypedFormControl } from '@angular/forms';
|
||||
|
||||
/** Custom Services */
|
||||
import { OrganizationService } from 'app/organization/organization.service';
|
||||
@@ -20,7 +20,7 @@ import { OrganizationService } from 'app/organization/organization.service';
|
||||
export class TransactionsComponent implements OnInit {
|
||||
|
||||
/** Currency selector. */
|
||||
currencySelector = new FormControl();
|
||||
currencySelector = new UntypedFormControl();
|
||||
/** Cashier Id */
|
||||
cashierId: any;
|
||||
/** Teller Id */
|
||||
|
||||
@@ -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 */
|
||||
@@ -23,7 +23,7 @@ export class CreateTellerComponent implements OnInit {
|
||||
/** Maximum date allowed. */
|
||||
maxDate = new Date();
|
||||
/** Teller form. */
|
||||
tellerForm: FormGroup;
|
||||
tellerForm: UntypedFormGroup;
|
||||
/** Office data. */
|
||||
officeData: any;
|
||||
/** TellerStatuses data. */
|
||||
@@ -38,7 +38,7 @@ export class CreateTellerComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
* @param {Dates} dateUtils Date Utils to format date.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private route: ActivatedRoute,
|
||||
|
||||
@@ -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 */
|
||||
@@ -24,7 +24,7 @@ export class EditTellerComponent implements OnInit {
|
||||
/** Maximum date allowed. */
|
||||
maxDate = new Date();
|
||||
/** Teller form. */
|
||||
tellerForm: FormGroup;
|
||||
tellerForm: UntypedFormGroup;
|
||||
/** Office data. */
|
||||
officeData: any;
|
||||
/** TellerStatuses data. */
|
||||
@@ -41,7 +41,7 @@ export class EditTellerComponent implements OnInit {
|
||||
* @param {Router} router Router for navigation.
|
||||
* @param {Dates} dateUtils Date Utils to format date.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
private route: ActivatedRoute,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit } from '@angular/core';
|
||||
import { FormGroup, FormBuilder, FormArray, FormControl } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, UntypedFormArray, UntypedFormControl } from '@angular/forms';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
|
||||
@@ -27,7 +27,7 @@ const recurrenceDefaultValue = 'FREQ=WEEKLY;INTERVAL=1;BYDAY=';
|
||||
export class WorkingDaysComponent implements OnInit, AfterViewInit {
|
||||
|
||||
/** Working days form. */
|
||||
workingDaysForm: FormGroup;
|
||||
workingDaysForm: UntypedFormGroup;
|
||||
/** Working days data. */
|
||||
workingDaysData: any;
|
||||
/** Week days */
|
||||
@@ -59,7 +59,7 @@ export class WorkingDaysComponent implements OnInit, AfterViewInit {
|
||||
* @param {ConfigurationWizardService} configurationWizardService ConfigurationWizard Service.
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private route: ActivatedRoute,
|
||||
private organizationService: OrganizationService,
|
||||
private settingsService: SettingsService,
|
||||
@@ -95,8 +95,8 @@ export class WorkingDaysComponent implements OnInit, AfterViewInit {
|
||||
/**
|
||||
* @returns {FormArray} recurrence form array.
|
||||
*/
|
||||
get recurrence(): FormArray {
|
||||
return this.workingDaysForm.get('recurrence') as FormArray;
|
||||
get recurrence(): UntypedFormArray {
|
||||
return this.workingDaysForm.get('recurrence') as UntypedFormArray;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -113,7 +113,7 @@ export class WorkingDaysComponent implements OnInit, AfterViewInit {
|
||||
* Creates the recurrence form array.
|
||||
*/
|
||||
createRecurrenceFormArray() {
|
||||
return this.weekDays.map(weekDay => new FormControl(weekDay.checked));
|
||||
return this.weekDays.map(weekDay => new UntypedFormControl(weekDay.checked));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user