Skip to content
Snippets Groups Projects
Commit f7039430 authored by Baptiste Toulemonde's avatar Baptiste Toulemonde
Browse files

ajout input si enum vide

parent 3375a5d7
No related branches found
No related tags found
3 merge requests!70US 182 182 33 30 avec develop à jour,!68Merge branches: parcoure des contrôles pua,!66us 181 182 33 30
......@@ -244,19 +244,23 @@
</div>
<div class="ml-5 row">
<mat-form-field class="mr-3 vitamui-mat-select col-6">
<mat-select panelClass="vitamui-mat-select">
<mat-option *ngFor="let element of enumerationsSedaControl" [value]="">
{{element}}
</mat-option>
</mat-select>
<div class="select-arrow">
<i class="material-icons">keyboard_arrow_up</i>
<i class="material-icons">keyboard_arrow_down</i>
</div>
</mat-form-field>
<div class="col-8">
<mat-form-field class="mr-3 vitamui-mat-select " *ngIf="!isEmptyEnumeration(enumerationsSedaControl); else blockInput">
<mat-select panelClass="vitamui-mat-select">
<mat-option *ngFor="let element of enumerationsSedaControl" [value]="">
{{element}}
</mat-option>
</mat-select>
<div class="select-arrow">
<i class="material-icons">keyboard_arrow_up</i>
<i class="material-icons">keyboard_arrow_down</i>
</div>
</mat-form-field>
<ng-template #blockInput>
<vitamui-common-editable-textarea >
</vitamui-common-editable-textarea>
</ng-template>
</div>
</div>
</div>
......
......@@ -764,6 +764,8 @@ export class FileTreeMetadataComponent {
return this.sedaService.isDuplicated(nomDuChamp, this.selectedSedaNode);
}
isEmptyEnumeration(enumerations: string[]): boolean{
return enumerations.length === 0;
}
}
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment