presets select implemented

main
manueltauber 2023-10-20 01:58:27 +02:00
parent 3673460903
commit 638e228aa4
2 changed files with 14 additions and 0 deletions

View File

@ -28,7 +28,16 @@
</mat-button-toggle>
</mat-button-toggle-group>
</div>
<mat-form-field appearance="fill">
<mat-label>{{selectedPreset}}</mat-label>
<mat-select>
<mat-option *ngFor="let preset of presets" [value]="preset.id">
{{preset.name}}
</mat-option>
</mat-select>
</mat-form-field>
</div>
<div class="filterContainer">
<button mat-raised-button class="filterButton" aria-label="Filtern" (click)="openFilterDialog()">
{{languageService.lMap.get('nttGanttFilterButton')}} <mat-icon style="color: #00a79d;">filter_alt</mat-icon>

View File

@ -117,6 +117,9 @@ export class NttGanttComponent implements OnInit {
public planTimes : any[] = [];
public sortSelectorName: any;
public presets : any[] = [];
public selectedPreset : {} = {};
/**###################################################################### Initial Loading functions ######################################################################*/
/**
@ -148,6 +151,8 @@ export class NttGanttComponent implements OnInit {
}
}
console.log(currentPreset);
this.presets = res.presets;
this.selectedPreset = currentPreset;
this.filters = JSON.parse(currentPreset.definition);
this.filterEnabled = true;