Timewindow: fix applying default grouping interval
This commit is contained in:
parent
72ae3078f8
commit
b1179dc4d4
@ -68,7 +68,7 @@
|
|||||||
timewindowForm.get('realtime.realtimeType').value === realtimeTypes.LAST_INTERVAL">
|
timewindowForm.get('realtime.realtimeType').value === realtimeTypes.LAST_INTERVAL">
|
||||||
<button *ngIf="!(timewindowForm.get('realtime.hideLastInterval').value ||
|
<button *ngIf="!(timewindowForm.get('realtime.hideLastInterval').value ||
|
||||||
timewindowForm.get('realtime.hideInterval').value)"
|
timewindowForm.get('realtime.hideInterval').value)"
|
||||||
matSuffix mat-icon-button type="button" class="tb-mat-24"
|
matSuffix mat-icon-button type="button"
|
||||||
(click)="configureRealtimeLastIntervalOptions($event)">
|
(click)="configureRealtimeLastIntervalOptions($event)">
|
||||||
<mat-icon>edit</mat-icon>
|
<mat-icon>edit</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
@ -95,7 +95,7 @@
|
|||||||
timewindowForm.get('realtime.realtimeType').value === realtimeTypes.INTERVAL">
|
timewindowForm.get('realtime.realtimeType').value === realtimeTypes.INTERVAL">
|
||||||
<button *ngIf="!(timewindowForm.get('realtime.hideQuickInterval').value ||
|
<button *ngIf="!(timewindowForm.get('realtime.hideQuickInterval').value ||
|
||||||
timewindowForm.get('realtime.hideInterval').value)"
|
timewindowForm.get('realtime.hideInterval').value)"
|
||||||
matSuffix mat-icon-button type="button" class="tb-mat-24"
|
matSuffix mat-icon-button type="button"
|
||||||
(click)="configureRealtimeQuickIntervalOptions($event)">
|
(click)="configureRealtimeQuickIntervalOptions($event)">
|
||||||
<mat-icon>edit</mat-icon>
|
<mat-icon>edit</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
@ -137,7 +137,7 @@
|
|||||||
timewindowForm.get('history.historyType').value === historyTypes.LAST_INTERVAL">
|
timewindowForm.get('history.historyType').value === historyTypes.LAST_INTERVAL">
|
||||||
<button *ngIf="!(timewindowForm.get('history.hideLastInterval').value ||
|
<button *ngIf="!(timewindowForm.get('history.hideLastInterval').value ||
|
||||||
timewindowForm.get('history.hideInterval').value)"
|
timewindowForm.get('history.hideInterval').value)"
|
||||||
matSuffix mat-icon-button type="button" class="tb-mat-24"
|
matSuffix mat-icon-button type="button"
|
||||||
(click)="configureHistoryLastIntervalOptions($event)">
|
(click)="configureHistoryLastIntervalOptions($event)">
|
||||||
<mat-icon>edit</mat-icon>
|
<mat-icon>edit</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
@ -177,7 +177,7 @@
|
|||||||
timewindowForm.get('history.historyType').value === historyTypes.INTERVAL">
|
timewindowForm.get('history.historyType').value === historyTypes.INTERVAL">
|
||||||
<button *ngIf="!(timewindowForm.get('history.hideQuickInterval').value ||
|
<button *ngIf="!(timewindowForm.get('history.hideQuickInterval').value ||
|
||||||
timewindowForm.get('history.hideInterval').value)"
|
timewindowForm.get('history.hideInterval').value)"
|
||||||
matSuffix mat-icon-button type="button" class="tb-mat-24"
|
matSuffix mat-icon-button type="button"
|
||||||
(click)="configureHistoryQuickIntervalOptions($event)">
|
(click)="configureHistoryQuickIntervalOptions($event)">
|
||||||
<mat-icon>edit</mat-icon>
|
<mat-icon>edit</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
@ -199,7 +199,7 @@
|
|||||||
formControlName="type"
|
formControlName="type"
|
||||||
[allowedAggregationTypes]="timewindowForm.get('allowedAggTypes').value">
|
[allowedAggregationTypes]="timewindowForm.get('allowedAggTypes').value">
|
||||||
<button *ngIf="!timewindowForm.get('hideAggregation').value"
|
<button *ngIf="!timewindowForm.get('hideAggregation').value"
|
||||||
matSuffix mat-icon-button type="button" class="tb-mat-24"
|
matSuffix mat-icon-button type="button"
|
||||||
(click)="openAggregationOptionsConfig($event)">
|
(click)="openAggregationOptionsConfig($event)">
|
||||||
<mat-icon>edit</mat-icon>
|
<mat-icon>edit</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@ -245,9 +245,9 @@ export class TimewindowConfigDialogComponent extends PageComponent implements On
|
|||||||
this.timewindowForm.get('realtime.advancedParams.lastAggIntervalsConfig').value;
|
this.timewindowForm.get('realtime.advancedParams.lastAggIntervalsConfig').value;
|
||||||
if (lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
if (lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
||||||
lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
||||||
this.timewindowForm.get('realtime.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('realtime.interval').patchValue(
|
||||||
lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.timewindowForm.get('realtime.quickInterval').valueChanges.pipe(
|
this.timewindowForm.get('realtime.quickInterval').valueChanges.pipe(
|
||||||
@ -257,9 +257,9 @@ export class TimewindowConfigDialogComponent extends PageComponent implements On
|
|||||||
this.timewindowForm.get('realtime.advancedParams.quickAggIntervalsConfig').value;
|
this.timewindowForm.get('realtime.advancedParams.quickAggIntervalsConfig').value;
|
||||||
if (quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
if (quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
||||||
quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
||||||
this.timewindowForm.get('realtime.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('realtime.interval').patchValue(
|
||||||
quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.timewindowForm.get('history.timewindowMs').valueChanges.pipe(
|
this.timewindowForm.get('history.timewindowMs').valueChanges.pipe(
|
||||||
@ -269,9 +269,9 @@ export class TimewindowConfigDialogComponent extends PageComponent implements On
|
|||||||
this.timewindowForm.get('history.advancedParams.lastAggIntervalsConfig').value;
|
this.timewindowForm.get('history.advancedParams.lastAggIntervalsConfig').value;
|
||||||
if (lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
if (lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
||||||
lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
||||||
this.timewindowForm.get('history.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('history.interval').patchValue(
|
||||||
lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.timewindowForm.get('history.quickInterval').valueChanges.pipe(
|
this.timewindowForm.get('history.quickInterval').valueChanges.pipe(
|
||||||
@ -281,9 +281,9 @@ export class TimewindowConfigDialogComponent extends PageComponent implements On
|
|||||||
this.timewindowForm.get('history.advancedParams.quickAggIntervalsConfig').value;
|
this.timewindowForm.get('history.advancedParams.quickAggIntervalsConfig').value;
|
||||||
if (quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
if (quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
||||||
quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
||||||
this.timewindowForm.get('history.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('history.interval').patchValue(
|
||||||
quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@ -308,9 +308,9 @@ export class TimewindowPanelComponent extends PageComponent implements OnInit, O
|
|||||||
).subscribe((timewindowMs: number) => {
|
).subscribe((timewindowMs: number) => {
|
||||||
if (this.realtimeAdvancedParams?.lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
if (this.realtimeAdvancedParams?.lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
||||||
this.realtimeAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
this.realtimeAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
||||||
this.timewindowForm.get('realtime.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('realtime.interval').patchValue(
|
||||||
this.realtimeAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
this.realtimeAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.timewindowForm.get('realtime.quickInterval').valueChanges.pipe(
|
this.timewindowForm.get('realtime.quickInterval').valueChanges.pipe(
|
||||||
@ -318,9 +318,9 @@ export class TimewindowPanelComponent extends PageComponent implements OnInit, O
|
|||||||
).subscribe((quickInterval: number) => {
|
).subscribe((quickInterval: number) => {
|
||||||
if (this.realtimeAdvancedParams?.quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
if (this.realtimeAdvancedParams?.quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
||||||
this.realtimeAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
this.realtimeAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
||||||
this.timewindowForm.get('realtime.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('realtime.interval').patchValue(
|
||||||
this.realtimeAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
this.realtimeAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.timewindowForm.get('history.timewindowMs').valueChanges.pipe(
|
this.timewindowForm.get('history.timewindowMs').valueChanges.pipe(
|
||||||
@ -328,9 +328,9 @@ export class TimewindowPanelComponent extends PageComponent implements OnInit, O
|
|||||||
).subscribe((timewindowMs: number) => {
|
).subscribe((timewindowMs: number) => {
|
||||||
if (this.historyAdvancedParams?.lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
if (this.historyAdvancedParams?.lastAggIntervalsConfig?.hasOwnProperty(timewindowMs) &&
|
||||||
this.historyAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
this.historyAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval) {
|
||||||
this.timewindowForm.get('history.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('history.interval').patchValue(
|
||||||
this.historyAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
this.historyAdvancedParams.lastAggIntervalsConfig[timewindowMs].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.timewindowForm.get('history.quickInterval').valueChanges.pipe(
|
this.timewindowForm.get('history.quickInterval').valueChanges.pipe(
|
||||||
@ -338,9 +338,9 @@ export class TimewindowPanelComponent extends PageComponent implements OnInit, O
|
|||||||
).subscribe((quickInterval: number) => {
|
).subscribe((quickInterval: number) => {
|
||||||
if (this.historyAdvancedParams?.quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
if (this.historyAdvancedParams?.quickAggIntervalsConfig?.hasOwnProperty(quickInterval) &&
|
||||||
this.historyAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
this.historyAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval) {
|
||||||
this.timewindowForm.get('history.interval').patchValue(
|
setTimeout(() => this.timewindowForm.get('history.interval').patchValue(
|
||||||
this.historyAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
this.historyAdvancedParams.quickAggIntervalsConfig[quickInterval].defaultAggInterval, {emitEvent: false}
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user