support custom display of devices by UUID/ID/Label & Scrutiny Name. (Does not persist).
Related #225
This commit is contained in:
+4
-4
@@ -1,11 +1,11 @@
|
||||
<h2 mat-dialog-title>Scrutiny Settings</h2>
|
||||
<mat-dialog-content class="mat-typography">
|
||||
|
||||
<form class="flex flex-col p-8 pb-0 overflow-hidden">
|
||||
<div class="flex flex-col p-8 pb-0 overflow-hidden">
|
||||
<div class="flex flex-col mt-5 gt-md:flex-row">
|
||||
<mat-form-field class="flex-auto gt-xs:pr-3 gt-md:pr-3">
|
||||
<mat-label>Display</mat-label>
|
||||
<mat-select [value]="dashboardDisplay">
|
||||
<mat-select [(ngModel)]="dashboardDisplay">
|
||||
<mat-option value="name">Name</mat-option>
|
||||
<mat-option value="serial_id">Serial ID</mat-option>
|
||||
<mat-option value="uuid">UUID</mat-option>
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
<mat-form-field class="flex-auto gt-xs:pr-3 gt-md:pl-3">
|
||||
<mat-label>Sort By</mat-label>
|
||||
<mat-select [value]="dashboardSort">
|
||||
<mat-select [(ngModel)]="dashboardSort">
|
||||
<mat-option value="status">Status</mat-option>
|
||||
<mat-option value="name" disabled>Name</mat-option>
|
||||
<mat-option value="serial_id" disabled>Serial ID</mat-option>
|
||||
@@ -80,7 +80,7 @@
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
</mat-dialog-content>
|
||||
<mat-dialog-actions align="end">
|
||||
|
||||
+3
-1
@@ -38,10 +38,12 @@ export class DashboardSettingsComponent implements OnInit {
|
||||
}
|
||||
|
||||
saveSettings(): void {
|
||||
this._configService.config = {
|
||||
var newSettings = {
|
||||
dashboardDisplay: this.dashboardDisplay,
|
||||
dashboardSort: this.dashboardSort
|
||||
}
|
||||
this._configService.config = newSettings
|
||||
console.log(`Saved Settings: ${JSON.stringify(newSettings)}`)
|
||||
}
|
||||
|
||||
formatLabel(value: number) {
|
||||
|
||||
Reference in New Issue
Block a user