[ADF-2999] added a way to test the validation icon on demo shell (#3431)

This commit is contained in:
Vito
2018-06-05 09:57:27 +01:00
committed by Eugenio Romano
parent a41ad9ce00
commit 4a0960e11e
3 changed files with 12 additions and 1 deletions

View File

@@ -1,8 +1,13 @@
<adf-form-list [forms]="formList" (row-dblclick)="onRowDblClick($event)">
</adf-form-list>
<div class="form-container" *ngIf="!isEmptyForm()">
<adf-form #adfForm [form]="form" [data]="restoredData">
<adf-form #adfForm [form]="form" [data]="restoredData" [showValidationIcon]="showValidationIcon">
</adf-form>
</div>
<button mat-button (click)="store()" color="primary">{{'FORM-LIST.STORE' | translate }}</button>
<button mat-button (click)="restore()" color="primary">{{'FORM-LIST.RESTORE' | translate }}</button>
<section class="form-list-margin">
<mat-slide-toggle color="primary" [(ngModel)]="showValidationIcon">
Show Validation Icon
</mat-slide-toggle>
</section>

View File

@@ -6,3 +6,7 @@
width: 80%;
height: 80%;
}
.form-list-margin {
margin-left: 26px;
}

View File

@@ -36,6 +36,8 @@ export class FormListComponent {
storedData: any = {};
restoredData: any = {};
showValidationIcon = false;
constructor(private formService: FormService, private logService: LogService) {
// Prevent default outcome actions
formService.executeOutcome.subscribe(e => {