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, TemplateRef, ElementRef, ViewChild, AfterViewInit } from '@angular/core';
|
||||
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
|
||||
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
|
||||
/** Custom Services */
|
||||
@@ -17,7 +17,7 @@ import { ConfigurationWizardService } from '../../../configuration-wizard/config
|
||||
export class CreateCodeComponent implements OnInit, AfterViewInit {
|
||||
|
||||
/** Code form. */
|
||||
codeForm: FormGroup;
|
||||
codeForm: UntypedFormGroup;
|
||||
|
||||
/* Reference of create code form */
|
||||
@ViewChild('codeFormRef') codeFormRef: ElementRef<any>;
|
||||
@@ -32,7 +32,7 @@ export class CreateCodeComponent implements OnInit, AfterViewInit {
|
||||
* @param {ConfigurationWizardService} configurationWizardService ConfigurationWizard Service.
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private systemService: SystemService,
|
||||
private route: ActivatedRoute,
|
||||
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';
|
||||
|
||||
/** Custom Services */
|
||||
@@ -17,7 +17,7 @@ import { SystemService } from '../../system.service';
|
||||
export class EditCodeComponent implements OnInit {
|
||||
|
||||
/** Code Form */
|
||||
codeForm: FormGroup;
|
||||
codeForm: UntypedFormGroup;
|
||||
/** Code Data */
|
||||
codeData: any;
|
||||
|
||||
@@ -28,7 +28,7 @@ export class EditCodeComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
constructor(private formBuilder: UntypedFormBuilder,
|
||||
private systemService: SystemService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { FormGroup, FormBuilder, Validators, FormArray } from '@angular/forms';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormArray } from '@angular/forms';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
|
||||
/** Custom Services */
|
||||
@@ -25,7 +25,7 @@ export class ViewCodeComponent implements OnInit {
|
||||
/** Code Values Data */
|
||||
codeValuesData: any[];
|
||||
/** Code Values Form */
|
||||
codeValuesForm: FormGroup;
|
||||
codeValuesForm: UntypedFormGroup;
|
||||
/** Code Value Row Status */
|
||||
codeValueRowStatus: string[] = [];
|
||||
|
||||
@@ -40,7 +40,7 @@ export class ViewCodeComponent implements OnInit {
|
||||
constructor(private route: ActivatedRoute,
|
||||
private systemService: SystemService,
|
||||
private router: Router,
|
||||
private formBuilder: FormBuilder,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private dialog: MatDialog) {
|
||||
this.route.data.subscribe((data: { code: any, codeValues: any }) => {
|
||||
this.codeData = data.code;
|
||||
@@ -70,8 +70,8 @@ export class ViewCodeComponent implements OnInit {
|
||||
* Gets the code values form array.
|
||||
* @returns {FormArray} Code values form array.
|
||||
*/
|
||||
get codeValues(): FormArray {
|
||||
return this.codeValuesForm.get('codeValues') as FormArray;
|
||||
get codeValues(): UntypedFormArray {
|
||||
return this.codeValuesForm.get('codeValues') as UntypedFormArray;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -96,7 +96,7 @@ export class ViewCodeComponent implements OnInit {
|
||||
* Creates a code value row in code values form.
|
||||
* @param {any} codeValue Code value.
|
||||
*/
|
||||
createCodeValuesRow(codeValue?: any): FormGroup {
|
||||
createCodeValuesRow(codeValue?: any): UntypedFormGroup {
|
||||
return this.formBuilder.group({
|
||||
'name': [{ value: codeValue ? codeValue.name : '', disabled: true }, Validators.required],
|
||||
'description': [{ value: codeValue ? codeValue.description : '', disabled: true }],
|
||||
|
||||
Reference in New Issue
Block a user