diff --git a/projects/ngx-formentry/src/abstract-controls-extension/afe-form-control.ts b/projects/ngx-formentry/src/abstract-controls-extension/afe-form-control.ts index 8a30deaa..15a0e218 100644 --- a/projects/ngx-formentry/src/abstract-controls-extension/afe-form-control.ts +++ b/projects/ngx-formentry/src/abstract-controls-extension/afe-form-control.ts @@ -147,6 +147,7 @@ class AfeFormControl ) { this._valueChangeListener(value); } + this.alerts.length > 0 && this.updateAlert(); } setValue(value: any) { diff --git a/projects/ngx-formentry/src/abstract-controls-extension/afe-form-group.ts b/projects/ngx-formentry/src/abstract-controls-extension/afe-form-group.ts index 910fc01f..0700b0a6 100644 --- a/projects/ngx-formentry/src/abstract-controls-extension/afe-form-group.ts +++ b/projects/ngx-formentry/src/abstract-controls-extension/afe-form-group.ts @@ -112,5 +112,8 @@ export class AfeFormGroup } setValue(value: any) { super.setValue(value); + if (this.alerts.length > 0) { + this.updateAlert(); + } } } diff --git a/projects/ngx-formentry/src/form-entry/form-renderer/form-renderer.component.html b/projects/ngx-formentry/src/form-entry/form-renderer/form-renderer.component.html index 4dafc20b..f667c7b4 100644 --- a/projects/ngx-formentry/src/form-entry/form-renderer/form-renderer.component.html +++ b/projects/ngx-formentry/src/form-entry/form-renderer/form-renderer.component.html @@ -122,14 +122,6 @@ - -
- × {{ node.control.alert }} -
-
+ + + +
= 40", + "message": "The patient temperature is too high" + }, "type": "obs", "validators": [], "id": "__yuHJFKyxE"