add interval splitting for bar charts
This commit is contained in:
@@ -200,6 +200,8 @@ export class PlotRequest {
|
||||
aggregates : Array<string>;
|
||||
keyOutside : boolean = false;
|
||||
generateThumbnail : boolean;
|
||||
intervalUnit: string;
|
||||
intervalValue: number;
|
||||
|
||||
copy(): PlotRequest {
|
||||
return JSON.parse(JSON.stringify(this));
|
||||
|
||||
@@ -32,6 +32,19 @@
|
||||
|
||||
<pdb-limit-by #limitbycomponent></pdb-limit-by>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Intervals:</mat-label>
|
||||
<mat-select [(value)]="intervalUnit">
|
||||
<mat-option value="NO_INTERVAL">-</mat-option>
|
||||
<mat-option value="MINUTE">minute</mat-option>
|
||||
<mat-option value="HOUR">hour</mat-option>
|
||||
<mat-option value="DAY">day</mat-option>
|
||||
<mat-option value="WEEK">week</mat-option>
|
||||
<mat-option value="MONTH">month</mat-option>
|
||||
<mat-option value="YEAR">year</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
<pdb-y-axis-definition #y1AxisDefinitionComponent yIndex="1"></pdb-y-axis-definition>
|
||||
<pdb-y-axis-definition #y2AxisDefinitionComponent yIndex="2" *ngIf="y2AxisAvailable"></pdb-y-axis-definition>
|
||||
|
||||
|
||||
@@ -50,6 +50,9 @@ export class VisualizationPageComponent implements OnInit {
|
||||
enableGallery = false;
|
||||
splitBy = null;
|
||||
y2AxisAvailable = false;
|
||||
|
||||
intervalUnit = 'NO_INTERVAL';
|
||||
intervalValue = 1;
|
||||
|
||||
constructor(private plotService: PlotService, private snackBar: MatSnackBar) {
|
||||
}
|
||||
@@ -163,6 +166,8 @@ export class VisualizationPageComponent implements OnInit {
|
||||
request.aggregates = aggregates;
|
||||
request.keyOutside = false;
|
||||
request.generateThumbnail = this.enableGallery;
|
||||
request.intervalUnit = this.intervalUnit;
|
||||
request.intervalValue = this.intervalValue;
|
||||
return request;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user