final improvements

This commit is contained in:
ThingsBoard 2024-07-11 17:50:50 +03:00
parent 53bce55964
commit a2ec97bf19
3 changed files with 8 additions and 10 deletions

View File

@ -17,7 +17,7 @@
--> -->
<div class="statistics-container" fxLayout="row" fxLayout.lt-md="column"> <div class="statistics-container" fxLayout="row" fxLayout.lt-md="column">
<mat-card [formGroup]="statisticForm" *ngIf="!general"> <mat-card [formGroup]="statisticForm" *ngIf="!general">
<mat-form-field class="mat-block"> <mat-form-field class="mat-block" subscriptSizing="dynamic">
<mat-label>{{ 'gateway.statistics.statistic' | translate }}</mat-label> <mat-label>{{ 'gateway.statistics.statistic' | translate }}</mat-label>
<mat-select formControlName="statisticKey"> <mat-select formControlName="statisticKey">
<mat-option *ngFor="let key of statisticsKeys" [value]="key"> <mat-option *ngFor="let key of statisticsKeys" [value]="key">
@ -32,9 +32,11 @@
*ngIf="!statisticsKeys.length && !commands.length"> *ngIf="!statisticsKeys.length && !commands.length">
{{ 'gateway.statistics.statistic-commands-empty' | translate }} {{ 'gateway.statistics.statistic-commands-empty' | translate }}
</mat-error> </mat-error>
<button mat-flat-button class="mat-mdc-button" color="primary" (click)="navigateToStatistics()"> <div>
<button mat-flat-button color="primary" (click)="navigateToStatistics()">
{{ 'gateway.statistics.statistics-button' | translate }} {{ 'gateway.statistics.statistics-button' | translate }}
</button> </button>
</div>
<mat-form-field class="mat-block" *ngIf="commandObj"> <mat-form-field class="mat-block" *ngIf="commandObj">
<mat-label>{{ 'gateway.statistics.command' | translate }}</mat-label> <mat-label>{{ 'gateway.statistics.command' | translate }}</mat-label>
<input matInput [value]="commandObj.command" disabled> <input matInput [value]="commandObj.command" disabled>

View File

@ -28,6 +28,7 @@
height: 100%; height: 100%;
margin-right: 35px; margin-right: 35px;
padding: 15px; padding: 15px;
gap: 22px;
} }
@media only screen and (max-width: 750px) { @media only screen and (max-width: 750px) {
@ -36,11 +37,6 @@
} }
} }
.mat-mdc-button {
width: 185px;
margin-top: 22px;
}
.chart-box, .chart-container { .chart-box, .chart-container {
height: 100%; height: 100%;
flex-grow: 1; flex-grow: 1;

View File

@ -32,7 +32,7 @@ import { Direction, SortOrder } from '@shared/models/page/sort-order';
import { MatTableDataSource } from '@angular/material/table'; import { MatTableDataSource } from '@angular/material/table';
import { MatSort } from '@angular/material/sort'; import { MatSort } from '@angular/material/sort';
import { NULL_UUID } from '@shared/models/id/has-uuid'; import { NULL_UUID } from '@shared/models/id/has-uuid';
import {deepClone} from "@core/utils"; import { deepClone } from '@core/utils';
@Component({ @Component({
selector: 'tb-gateway-statistics', selector: 'tb-gateway-statistics',