From dbf04478e618ce0f94445cb67739ccd70e30991e Mon Sep 17 00:00:00 2001 From: "florian.azizian" <florian.azizian@maarch.org> Date: Thu, 24 Oct 2019 13:41:14 +0100 Subject: [PATCH] FEAT #12070 TIME 0:30 object object in list custom field --- package.json | 2 +- ...indexing-model-administration.component.ts | 35 ------------------- .../field-list/field-list.component.html | 16 ++++----- 3 files changed, 9 insertions(+), 44 deletions(-) diff --git a/package.json b/package.json index 3312b18bf4d..6dd8bb0f078 100755 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ "author": "Maarch", "license": "GPL-3.0", "dependencies": { - "@fortawesome/fontawesome-free": "^5.10.2", + "@fortawesome/fontawesome-free": "^5.11.2", "bootstrap": "^3.4.1", "chart.js": "1.1.1", "chosen-js": "^1.8.7", diff --git a/src/frontend/app/administration/indexingModel/indexing-model-administration.component.ts b/src/frontend/app/administration/indexingModel/indexing-model-administration.component.ts index 40fe769a241..353751b330f 100644 --- a/src/frontend/app/administration/indexingModel/indexing-model-administration.component.ts +++ b/src/frontend/app/administration/indexingModel/indexing-model-administration.component.ts @@ -49,41 +49,6 @@ export class IndexingModelAdministrationComponent implements OnInit { creationMode: boolean = true; - availableFields: any[] = [ - { - identifier: 'priority', - label: this.lang.priority, - type: 'select', - values: [] - }, - { - identifier: 'confidential', - label: this.lang.confidential, - type: 'radio', - values: [{'id': 'true', 'label': 'Oui'}, {'id': 'false', 'label': 'Non'}] - }, - { - identifier: 'initiator', - label: this.lang.initiator, - type: 'select', - values: [] - }, - { - identifier: 'processLimitDate', - label: this.lang.processLimitDate, - type: 'date', - values: [] - }, - { - identifier: 'arrivalDate', - label: this.lang.arrivalDate, - type: 'date', - values: [] - } - ]; - - availableCustomFields: any[] = []; - categoriesList: any []; constructor( diff --git a/src/frontend/app/indexation/field-list/field-list.component.html b/src/frontend/app/indexation/field-list/field-list.component.html index 5c1e4de133b..465a0ba649f 100644 --- a/src/frontend/app/indexation/field-list/field-list.component.html +++ b/src/frontend/app/indexation/field-list/field-list.component.html @@ -48,7 +48,7 @@ </ng-container> <ng-container *ngIf="field.type === 'checkbox'"> <div class="input-form checkbox-form"> - <mat-selection-list #checkboxElement class="div-list" disabled> + <mat-selection-list #checkboxCustomElement class="div-list" disabled> <mat-list-option *ngFor="let value of field.values" [value]="value.id" checkboxPosition="before"> {{value.label}} @@ -56,7 +56,7 @@ </mat-selection-list> </div> <mat-chip-list class="checkbox-selected-list"> - <mat-chip *ngFor="let chip of checkboxElement.selectedOptions.selected" selected> + <mat-chip *ngFor="let chip of checkboxCustomElement.selectedOptions.selected" selected> {{lang.selectedValue}} </mat-chip> </mat-chip-list> @@ -111,22 +111,22 @@ </ng-container> <ng-container *ngIf="field.type === 'radio'"> <mat-radio-group class="radio-form" color="primary" disabled> - <mat-radio-button *ngFor="let value of field.values" [value]="value"> - {{value}} + <mat-radio-button *ngFor="let value of field.values" [value]="value.id"> + {{value.label}} </mat-radio-button> </mat-radio-group> </ng-container> <ng-container *ngIf="field.type === 'checkbox'"> <div class="input-form checkbox-form"> - <mat-selection-list #shoes class="div-list" disabled> - <mat-list-option *ngFor="let value of field.values" [value]="value" + <mat-selection-list #checkboxElement class="div-list" disabled> + <mat-list-option *ngFor="let value of field.values" [value]="value.id" checkboxPosition="before"> - {{value}} + {{value.label}} </mat-list-option> </mat-selection-list> </div> <mat-chip-list class="checkbox-selected-list"> - <mat-chip *ngFor="let chip of shoes.selectedOptions.selected" selected> + <mat-chip *ngFor="let chip of checkboxElement.selectedOptions.selected" selected> {{lang.selectedValue}} </mat-chip> </mat-chip-list> -- GitLab