Upgrading to Angular 20:
Replaced checked in package-lock.json by regenerated one. Ran ng update @angular/core@20 @angular/cli@20 Ran npm install @angular-builders/jest@^20.0.0 @fortawesome/angular-fontawesome@^3.0.0 @swimlane/ngx-graph@^11 Ran npm install ngx-mat-select-search@^8.0.2. Ran ng update @angular/material@20. Updated all eslint and typescript to the latest versions. Removed @angular-devkit/schematics. Updated fontawesome. Updated rxjs and tslib. Moved required node version from 16 to 20. Updated jest-preset-angular. Set preserveWhitespaces to false. Corrected two type declarations in two typescript files to make ng serve run without errors. Removed unused angular-devkit/schematics from view-user.component.ts . Updated list of supported browsers. Upgraded prettier. Ran prettier . --write the first time. Ran prettier . --write the second time. Ran ng generate @angular/core:inject with defaults, excepted a handful of files. Fixed remaining eslint problems. Added dist directory to ignores in eslint.config.js. Let prettier fix formatting, almost everything is just line breaks. Made htmlhint ignore @if and @for Angular constructs. Updated node version in Github workflow to 22.12.0 (build.yml). Updated .env.ts. Updated Angular datetime format strings from YYYY-MM-DD to yyyy-MM-dd. Merged changes from dev into angular20 branch.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Injectable, inject } from '@angular/core';
|
||||
import { ActivatedRouteSnapshot } from '@angular/router';
|
||||
|
||||
/** rxjs Imports */
|
||||
@@ -13,10 +13,7 @@ import { SystemService } from '../system.service';
|
||||
*/
|
||||
@Injectable()
|
||||
export class CodeResolver {
|
||||
/**
|
||||
* @param {SystemService} systemService System service.
|
||||
*/
|
||||
constructor(private systemService: SystemService) {}
|
||||
private systemService = inject(SystemService);
|
||||
|
||||
/**
|
||||
* Returns the Code data.
|
||||
|
||||
@@ -25,22 +25,24 @@
|
||||
<ng-container matColumnDef="systemDefined">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header>{{ 'labels.inputs.System Defined' | translate }}</th>
|
||||
<td mat-cell *matCellDef="let code">
|
||||
<fa-icon
|
||||
*ngIf="code.systemDefined"
|
||||
icon="check-circle"
|
||||
size="lg"
|
||||
class="system-defined"
|
||||
matTooltip="{{ 'tooltips.Yes' | translate }}"
|
||||
matTooltipPosition="right"
|
||||
></fa-icon>
|
||||
<fa-icon
|
||||
*ngIf="!code.systemDefined"
|
||||
icon="times-circle"
|
||||
size="lg"
|
||||
class="not-system-defined"
|
||||
matTooltip="{{ 'tooltips.No' | translate }}"
|
||||
matTooltipPosition="right"
|
||||
></fa-icon>
|
||||
@if (code.systemDefined) {
|
||||
<fa-icon
|
||||
icon="check-circle"
|
||||
size="lg"
|
||||
class="system-defined"
|
||||
matTooltip="{{ 'tooltips.Yes' | translate }}"
|
||||
matTooltipPosition="right"
|
||||
></fa-icon>
|
||||
}
|
||||
@if (!code.systemDefined) {
|
||||
<fa-icon
|
||||
icon="times-circle"
|
||||
size="lg"
|
||||
class="not-system-defined"
|
||||
matTooltip="{{ 'tooltips.No' | translate }}"
|
||||
matTooltipPosition="right"
|
||||
></fa-icon>
|
||||
}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit } from '@angular/core';
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit, inject } from '@angular/core';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort, MatSortHeader } from '@angular/material/sort';
|
||||
import {
|
||||
@@ -48,6 +48,11 @@ import { STANDALONE_SHARED_IMPORTS } from 'app/standalone-shared.module';
|
||||
]
|
||||
})
|
||||
export class CodesComponent implements OnInit, AfterViewInit {
|
||||
private route = inject(ActivatedRoute);
|
||||
private router = inject(Router);
|
||||
private configurationWizardService = inject(ConfigurationWizardService);
|
||||
private popoverService = inject(PopoverService);
|
||||
|
||||
/** Codes data. */
|
||||
codesData: any;
|
||||
/** Columns to be displayed in codes table. */
|
||||
@@ -79,12 +84,7 @@ export class CodesComponent implements OnInit, AfterViewInit {
|
||||
* @param {ConfigurationWizardService} configurationWizardService ConfigurationWizard Service.
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
*/
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private configurationWizardService: ConfigurationWizardService,
|
||||
private popoverService: PopoverService
|
||||
) {
|
||||
constructor() {
|
||||
this.route.data.subscribe((data: { codes: any }) => {
|
||||
this.codesData = data.codes;
|
||||
});
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Injectable, inject } from '@angular/core';
|
||||
|
||||
/** rxjs Imports */
|
||||
import { Observable } from 'rxjs';
|
||||
@@ -12,10 +12,7 @@ import { SystemService } from '../system.service';
|
||||
*/
|
||||
@Injectable()
|
||||
export class CodesResolver {
|
||||
/**
|
||||
* @param {SystemService} systemService System service.
|
||||
*/
|
||||
constructor(private systemService: SystemService) {}
|
||||
private systemService = inject(SystemService);
|
||||
|
||||
/**
|
||||
* Returns the Codes data.
|
||||
|
||||
@@ -6,10 +6,12 @@
|
||||
<mat-form-field>
|
||||
<mat-label>{{ 'labels.inputs.Code Name' | translate }}</mat-label>
|
||||
<input matInput required formControlName="name" />
|
||||
<mat-error *ngIf="codeForm.controls.name.hasError('required')">
|
||||
{{ 'labels.inputs.Code Name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
@if (codeForm.controls.name.hasError('required')) {
|
||||
<mat-error>
|
||||
{{ 'labels.inputs.Code Name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
}
|
||||
</mat-form-field>
|
||||
</div>
|
||||
</mat-card-content>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit } from '@angular/core';
|
||||
import { Component, OnInit, TemplateRef, ElementRef, ViewChild, AfterViewInit, inject } from '@angular/core';
|
||||
import { UntypedFormBuilder, UntypedFormGroup, Validators, ReactiveFormsModule } from '@angular/forms';
|
||||
import { Router, ActivatedRoute, RouterLink } from '@angular/router';
|
||||
|
||||
@@ -19,6 +19,13 @@ import { STANDALONE_SHARED_IMPORTS } from 'app/standalone-shared.module';
|
||||
]
|
||||
})
|
||||
export class CreateCodeComponent implements OnInit, AfterViewInit {
|
||||
private formBuilder = inject(UntypedFormBuilder);
|
||||
private systemService = inject(SystemService);
|
||||
private route = inject(ActivatedRoute);
|
||||
private router = inject(Router);
|
||||
private configurationWizardService = inject(ConfigurationWizardService);
|
||||
private popoverService = inject(PopoverService);
|
||||
|
||||
/** Code form. */
|
||||
codeForm: UntypedFormGroup;
|
||||
|
||||
@@ -27,23 +34,6 @@ export class CreateCodeComponent implements OnInit, AfterViewInit {
|
||||
/* Template for popover on create code form */
|
||||
@ViewChild('templateCodeFormRef') templateCodeFormRef: TemplateRef<any>;
|
||||
|
||||
/**
|
||||
* @param {FormBuilder} formBuilder Form Builder.
|
||||
* @param {SystemService} systemService Accounting Service.
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
* @param {ConfigurationWizardService} configurationWizardService ConfigurationWizard Service.
|
||||
* @param {PopoverService} popoverService PopoverService.
|
||||
*/
|
||||
constructor(
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private systemService: SystemService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private configurationWizardService: ConfigurationWizardService,
|
||||
private popoverService: PopoverService
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Creates the code form.
|
||||
*/
|
||||
|
||||
@@ -6,10 +6,12 @@
|
||||
<mat-form-field>
|
||||
<mat-label>{{ 'labels.inputs.Code Name' | translate }}</mat-label>
|
||||
<input matInput required formControlName="name" />
|
||||
<mat-error *ngIf="codeForm.controls.name.hasError('required')">
|
||||
{{ 'labels.inputs.Code Name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
@if (codeForm.controls.name.hasError('required')) {
|
||||
<mat-error>
|
||||
{{ 'labels.inputs.Code Name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
}
|
||||
</mat-form-field>
|
||||
</div>
|
||||
</mat-card-content>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { Component, OnInit, inject } from '@angular/core';
|
||||
import { UntypedFormGroup, UntypedFormBuilder, Validators, ReactiveFormsModule } from '@angular/forms';
|
||||
import { ActivatedRoute, Router, RouterLink } from '@angular/router';
|
||||
|
||||
@@ -19,6 +19,11 @@ import { STANDALONE_SHARED_IMPORTS } from 'app/standalone-shared.module';
|
||||
]
|
||||
})
|
||||
export class EditCodeComponent implements OnInit {
|
||||
private formBuilder = inject(UntypedFormBuilder);
|
||||
private systemService = inject(SystemService);
|
||||
private route = inject(ActivatedRoute);
|
||||
private router = inject(Router);
|
||||
|
||||
/** Code Form */
|
||||
codeForm: UntypedFormGroup;
|
||||
/** Code Data */
|
||||
@@ -31,12 +36,7 @@ export class EditCodeComponent implements OnInit {
|
||||
* @param {ActivatedRoute} route Activated Route.
|
||||
* @param {Router} router Router for navigation.
|
||||
*/
|
||||
constructor(
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private systemService: SystemService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router
|
||||
) {
|
||||
constructor() {
|
||||
this.route.data.subscribe((data: { code: any }) => {
|
||||
this.codeData = data.code;
|
||||
});
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Injectable, inject } from '@angular/core';
|
||||
import { ActivatedRouteSnapshot } from '@angular/router';
|
||||
|
||||
/** rxjs Imports */
|
||||
@@ -13,10 +13,7 @@ import { SystemService } from '../../system.service';
|
||||
*/
|
||||
@Injectable()
|
||||
export class CodeValuesResolver {
|
||||
/**
|
||||
* @param {SystemService} systemService System service.
|
||||
*/
|
||||
constructor(private systemService: SystemService) {}
|
||||
private systemService = inject(SystemService);
|
||||
|
||||
/**
|
||||
* Returns the Code Values data.
|
||||
|
||||
@@ -4,19 +4,23 @@
|
||||
{{ 'labels.buttons.Add Code Value' | translate }}
|
||||
</button>
|
||||
|
||||
<span *ngIf="!codeData.systemDefined">
|
||||
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_CODE'">
|
||||
<fa-icon icon="edit" class="m-r-10"></fa-icon>
|
||||
{{ 'labels.buttons.Edit Code' | translate }}
|
||||
</button>
|
||||
</span>
|
||||
@if (!codeData.systemDefined) {
|
||||
<span>
|
||||
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_CODE'">
|
||||
<fa-icon icon="edit" class="m-r-10"></fa-icon>
|
||||
{{ 'labels.buttons.Edit Code' | translate }}
|
||||
</button>
|
||||
</span>
|
||||
}
|
||||
|
||||
<span *ngIf="!codeData.systemDefined">
|
||||
<button mat-raised-button color="warn" (click)="delete()" *mifosxHasPermission="'DELETE_CODEVALUE'">
|
||||
<fa-icon icon="trash" class="m-r-10"></fa-icon>
|
||||
{{ 'labels.buttons.Delete Code' | translate }}
|
||||
</button>
|
||||
</span>
|
||||
@if (!codeData.systemDefined) {
|
||||
<span>
|
||||
<button mat-raised-button color="warn" (click)="delete()" *mifosxHasPermission="'DELETE_CODEVALUE'">
|
||||
<fa-icon icon="trash" class="m-r-10"></fa-icon>
|
||||
{{ 'labels.buttons.Delete Code' | translate }}
|
||||
</button>
|
||||
</span>
|
||||
}
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
@@ -27,103 +31,111 @@
|
||||
|
||||
<form [formGroup]="codeValuesForm">
|
||||
<mat-card-content>
|
||||
<div formArrayName="codeValues" *ngFor="let codeValue of codeValues.controls; let i = index">
|
||||
<div class="flex-fill layout-row-wrap gap-2percent responsive-column" [formGroupName]="i">
|
||||
<mat-form-field class="flex-fill flex-20">
|
||||
<mat-label>{{ 'labels.inputs.name' | translate }}</mat-label>
|
||||
<input required matInput formControlName="name" placeholder="{{ 'labels.inputs.name' | translate }}" />
|
||||
<mat-error *ngIf="codeValues.at(i).controls.name.hasError('required')">
|
||||
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field class="flex-fill flex-22">
|
||||
<mat-label>{{ 'labels.inputs.Description' | translate }}</mat-label>
|
||||
<input
|
||||
matInput
|
||||
formControlName="description"
|
||||
placeholder="{{ 'labels.inputs.Description' | translate }}"
|
||||
/>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field class="flex-fill flex-18">
|
||||
<mat-label>{{ 'labels.inputs.Position' | translate }}</mat-label>
|
||||
<input
|
||||
required
|
||||
matInput
|
||||
formControlName="position"
|
||||
type="number"
|
||||
placeholder="{{ 'labels.inputs.Position' | translate }}"
|
||||
/>
|
||||
<mat-error *ngIf="codeValues.at(i).controls.position.hasError('required')">
|
||||
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<div class="active-wrapper flex-8">
|
||||
<mat-checkbox formControlName="isActive" class="active">{{
|
||||
'labels.inputs.Active' | translate
|
||||
}}</mat-checkbox>
|
||||
</div>
|
||||
|
||||
<div class="options-wrapper gap-2percent flex-22">
|
||||
<span *ngIf="codeValueRowStatus[i] === 'edit'">
|
||||
@for (codeValue of codeValues.controls; track codeValue; let i = $index) {
|
||||
<div formArrayName="codeValues">
|
||||
<div class="flex-fill layout-row-wrap gap-2percent responsive-column" [formGroupName]="i">
|
||||
<mat-form-field class="flex-fill flex-20">
|
||||
<mat-label>{{ 'labels.inputs.name' | translate }}</mat-label>
|
||||
<input required matInput formControlName="name" placeholder="{{ 'labels.inputs.name' | translate }}" />
|
||||
@if (codeValues.at(i).controls.name.hasError('required')) {
|
||||
<mat-error>
|
||||
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
}
|
||||
</mat-form-field>
|
||||
<mat-form-field class="flex-fill flex-22">
|
||||
<mat-label>{{ 'labels.inputs.Description' | translate }}</mat-label>
|
||||
<input
|
||||
matInput
|
||||
formControlName="description"
|
||||
placeholder="{{ 'labels.inputs.Description' | translate }}"
|
||||
/>
|
||||
</mat-form-field>
|
||||
<mat-form-field class="flex-fill flex-18">
|
||||
<mat-label>{{ 'labels.inputs.Position' | translate }}</mat-label>
|
||||
<input
|
||||
required
|
||||
matInput
|
||||
formControlName="position"
|
||||
type="number"
|
||||
placeholder="{{ 'labels.inputs.Position' | translate }}"
|
||||
/>
|
||||
@if (codeValues.at(i).controls.position.hasError('required')) {
|
||||
<mat-error>
|
||||
{{ 'labels.inputs.name' | translate }} {{ 'labels.commons.is' | translate }}
|
||||
<strong>{{ 'labels.commons.required' | translate }}</strong>
|
||||
</mat-error>
|
||||
}
|
||||
</mat-form-field>
|
||||
<div class="active-wrapper flex-8">
|
||||
<mat-checkbox formControlName="isActive" class="active">{{
|
||||
'labels.inputs.Active' | translate
|
||||
}}</mat-checkbox>
|
||||
</div>
|
||||
<div class="options-wrapper gap-2percent flex-22">
|
||||
@if (codeValueRowStatus[i] === 'edit') {
|
||||
<span>
|
||||
<button
|
||||
mat-stroked-button
|
||||
color="primary"
|
||||
type="button"
|
||||
[disabled]="!codeValues.at(i).valid || codeValues.at(i).pristine"
|
||||
(click)="updateCodeValue(i)"
|
||||
*mifosxHasPermission="'UPDATE_CODEVALUE'"
|
||||
>
|
||||
{{ 'labels.buttons.Submit' | translate }}
|
||||
</button>
|
||||
</span>
|
||||
}
|
||||
@if (codeValueRowStatus[i] === 'edit') {
|
||||
<button mat-button type="button" (click)="disableRow(i)">
|
||||
{{ 'labels.buttons.Cancel' | translate }}
|
||||
</button>
|
||||
}
|
||||
@if (codeValueRowStatus[i] === 'new') {
|
||||
<button
|
||||
mat-icon-button
|
||||
color="primary"
|
||||
type="button"
|
||||
title="{{ 'tooltips.Add' | translate }}"
|
||||
[disabled]="!codeValuesForm.get('codeValues').at(i).valid"
|
||||
matTooltip="{{ 'tooltips.Add' | translate }}"
|
||||
matTooltipPosition="above"
|
||||
(click)="addCodeValue(i)"
|
||||
>
|
||||
<fa-icon icon="plus" size="lg"></fa-icon>
|
||||
</button>
|
||||
}
|
||||
@if (codeValueRowStatus[i] === 'disabled') {
|
||||
<button
|
||||
type="button"
|
||||
color="primary"
|
||||
title="{{ 'tooltips.Edit' | translate }}"
|
||||
mat-icon-button
|
||||
matTooltip="{{ 'tooltips.Edit' | translate }}"
|
||||
matTooltipPosition="above"
|
||||
(click)="enableRow(i)"
|
||||
>
|
||||
<fa-icon icon="edit" size="lg"></fa-icon>
|
||||
</button>
|
||||
}
|
||||
<button
|
||||
mat-stroked-button
|
||||
color="primary"
|
||||
type="button"
|
||||
[disabled]="!codeValues.at(i).valid || codeValues.at(i).pristine"
|
||||
(click)="updateCodeValue(i)"
|
||||
*mifosxHasPermission="'UPDATE_CODEVALUE'"
|
||||
color="warn"
|
||||
title="{{ 'tooltips.Delete' | translate }}"
|
||||
mat-icon-button
|
||||
matTooltip="{{ 'tooltips.Delete' | translate }}"
|
||||
*mifosxHasPermission="'DELETE_CODEVALUE'"
|
||||
matTooltipPosition="above"
|
||||
(click)="codeValueRowStatus[i] === 'new' ? removeNewCodeValue(i) : deleteCodeValue(i)"
|
||||
>
|
||||
{{ 'labels.buttons.Submit' | translate }}
|
||||
<fa-icon icon="trash" size="lg"></fa-icon>
|
||||
</button>
|
||||
</span>
|
||||
<button mat-button type="button" *ngIf="codeValueRowStatus[i] === 'edit'" (click)="disableRow(i)">
|
||||
{{ 'labels.buttons.Cancel' | translate }}
|
||||
</button>
|
||||
<button
|
||||
mat-icon-button
|
||||
color="primary"
|
||||
type="button"
|
||||
title="{{ 'tooltips.Add' | translate }}"
|
||||
[disabled]="!codeValuesForm.get('codeValues').at(i).valid"
|
||||
*ngIf="codeValueRowStatus[i] === 'new'"
|
||||
matTooltip="{{ 'tooltips.Add' | translate }}"
|
||||
matTooltipPosition="above"
|
||||
(click)="addCodeValue(i)"
|
||||
>
|
||||
<fa-icon icon="plus" size="lg"></fa-icon>
|
||||
</button>
|
||||
<button
|
||||
type="button"
|
||||
color="primary"
|
||||
title="{{ 'tooltips.Edit' | translate }}"
|
||||
*ngIf="codeValueRowStatus[i] === 'disabled'"
|
||||
mat-icon-button
|
||||
matTooltip="{{ 'tooltips.Edit' | translate }}"
|
||||
matTooltipPosition="above"
|
||||
(click)="enableRow(i)"
|
||||
>
|
||||
<fa-icon icon="edit" size="lg"></fa-icon>
|
||||
</button>
|
||||
<button
|
||||
type="button"
|
||||
color="warn"
|
||||
title="{{ 'tooltips.Delete' | translate }}"
|
||||
mat-icon-button
|
||||
matTooltip="{{ 'tooltips.Delete' | translate }}"
|
||||
*mifosxHasPermission="'DELETE_CODEVALUE'"
|
||||
matTooltipPosition="above"
|
||||
(click)="codeValueRowStatus[i] === 'new' ? removeNewCodeValue(i) : deleteCodeValue(i)"
|
||||
>
|
||||
<fa-icon icon="trash" size="lg"></fa-icon>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</mat-card-content>
|
||||
</form>
|
||||
</mat-card>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { Component, OnInit, inject } from '@angular/core';
|
||||
import {
|
||||
UntypedFormArray,
|
||||
UntypedFormBuilder,
|
||||
@@ -40,6 +40,13 @@ import { STANDALONE_SHARED_IMPORTS } from 'app/standalone-shared.module';
|
||||
]
|
||||
})
|
||||
export class ViewCodeComponent implements OnInit {
|
||||
private route = inject(ActivatedRoute);
|
||||
private systemService = inject(SystemService);
|
||||
private router = inject(Router);
|
||||
private formBuilder = inject(UntypedFormBuilder);
|
||||
private dialog = inject(MatDialog);
|
||||
private translateService = inject(TranslateService);
|
||||
|
||||
/** Code Data */
|
||||
codeData: any;
|
||||
/** Code Values Data */
|
||||
@@ -58,14 +65,7 @@ export class ViewCodeComponent implements OnInit {
|
||||
* @param {MatDialog} dialog Dialog reference.
|
||||
* @param {TranslateService} translateService Translate Service.
|
||||
*/
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private systemService: SystemService,
|
||||
private router: Router,
|
||||
private formBuilder: UntypedFormBuilder,
|
||||
private dialog: MatDialog,
|
||||
private translateService: TranslateService
|
||||
) {
|
||||
constructor() {
|
||||
this.route.data.subscribe((data: { code: any; codeValues: any }) => {
|
||||
this.codeData = data.code;
|
||||
this.codeValuesData = data.codeValues;
|
||||
|
||||
Reference in New Issue
Block a user