form component fixes (#1726)

- fix ‘readonly highlighting when input fields loaded with values
- Start Form raises base ‘FormLoaded’ event (including FormService
emits)
This commit is contained in:
Denys Vuika
2017-03-14 10:14:14 +00:00
committed by Mario Romano
parent 64565c44f4
commit 55137917bd
7 changed files with 9 additions and 3 deletions

View File

@@ -117,7 +117,7 @@ export class ActivitiStartForm extends ActivitiForm implements AfterViewChecked,
this.form = this.parseForm(form);
this.form.readOnly = this.readOnlyForm;
// this.form.processDefinitionId = this.processDefinitionId;
this.formLoaded.emit(this.form);
this.onFormLoaded(this.form);
},
error => this.handleError(error)
);
@@ -131,7 +131,7 @@ export class ActivitiStartForm extends ActivitiForm implements AfterViewChecked,
this.formName = form.processDefinitionName;
this.form = this.parseForm(form);
this.form.readOnly = this.readOnlyForm;
this.formLoaded.emit(this.form);
this.onFormLoaded(this.form);
},
error => this.handleError(error)
);

View File

@@ -5,6 +5,7 @@
type="text"
[attr.id]="field.id"
[attr.required]="isRequired()"
[value]="field.value"
[(ngModel)]="field.value"
(ngModelChange)="checkVisibility(field)"
[disabled]="field.readOnly"

View File

@@ -7,6 +7,7 @@
type="text"
[attr.id]="field.id"
[attr.required]="isRequired()"
[value]="field.value"
[(ngModel)]="field.value"
(ngModelChange)="onDateChanged()"
(onOk)="onDateSelected()"

View File

@@ -6,6 +6,7 @@
rows= "3"
[attr.id]="field.id"
[attr.required]="isRequired()"
[value]="field.value"
[(ngModel)]="field.value"
(ngModelChange)="checkVisibility(field)"
[disabled]="field.readOnly"

View File

@@ -6,6 +6,7 @@
pattern="-?[0-9]*(\.[0-9]+)?"
[attr.id]="field.id"
[attr.required]="isRequired()"
[value]="field.value"
[(ngModel)]="field.value"
(ngModelChange)="checkVisibility(field)"
[disabled]="field.readOnly"

View File

@@ -5,6 +5,7 @@
type="text"
[attr.id]="field.id"
[attr.required]="isRequired()"
[value]="field.value"
[(ngModel)]="field.value"
(ngModelChange)="onFieldChanged(field)"
[disabled]="field.readOnly"