[ADF-5432] component template and code fixes after testing Angular strict mode (#7118)

* process list fixes

* template error fixes

* template and code fixes

* bug fixes in templates and types

* bugs, bugs are everywhere

* fix test

* test fixes

* enable strict templates for extensions lib

* enable strict mode for insights lib

* enable strict mode for core lib

* enable strict mode for content lib

* strict mode for process lib

* strict mode for process cloud

* fix demo shell template issues

* fix process cloud types
This commit is contained in:
Denys Vuika
2021-06-22 16:36:06 +01:00
committed by GitHub
parent e2b8557f4b
commit 829805e201
129 changed files with 534 additions and 435 deletions

View File

@@ -19,7 +19,7 @@ import { DateAdapter, MAT_DATE_FORMATS } from '@angular/material/core';
import moment from 'moment-es6';
import { Moment } from 'moment';
import { Observable, Subject } from 'rxjs';
import { FormBuilder, AbstractControl, Validators, FormGroup, FormControl } from '@angular/forms';
import { FormBuilder, Validators, FormGroup, FormControl } from '@angular/forms';
import {
MOMENT_DATE_FORMATS, MomentDateAdapter,
LogService,
@@ -102,8 +102,8 @@ export class StartTaskCloudComponent implements OnInit, OnDestroy {
priorities: TaskPriorityOption[];
private assigneeForm: AbstractControl = new FormControl('');
private groupForm: AbstractControl = new FormControl('');
private assigneeForm = new FormControl('');
private groupForm = new FormControl('');
private onDestroy$ = new Subject<boolean>();
constructor(private taskService: TaskCloudService,
@@ -228,19 +228,19 @@ export class StartTaskCloudComponent implements OnInit, OnDestroy {
return isValid ? null : { 'whitespace': true };
}
get nameController(): AbstractControl {
return this.taskForm.get('name');
get nameController(): FormControl {
return this.taskForm.get('name') as FormControl;
}
get priorityController(): AbstractControl {
return this.taskForm.get('priority');
get priorityController(): FormControl {
return this.taskForm.get('priority') as FormControl;
}
get assigneeFormControl(): AbstractControl {
get assigneeFormControl(): FormControl {
return this.assigneeForm;
}
get candidateUserFormControl(): AbstractControl {
get candidateUserFormControl(): FormControl {
return this.groupForm;
}