You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@streampipes.apache.org by te...@apache.org on 2020/03/06 10:07:16 UTC
[incubator-streampipes] branch STREAMPIPES-79 updated:
[STREAMPIPES-79] select 'custom' button if user set a custom daterange
This is an automated email from the ASF dual-hosted git repository.
tex pushed a commit to branch STREAMPIPES-79
in repository https://gitbox.apache.org/repos/asf/incubator-streampipes.git
The following commit(s) were added to refs/heads/STREAMPIPES-79 by this push:
new f7f5f40 [STREAMPIPES-79] select 'custom' button if user set a custom daterange
new cbf2fc8 Merge remote-tracking branch 'origin/STREAMPIPES-79' into STREAMPIPES-79
f7f5f40 is described below
commit f7f5f40f8bc59a2c266fe3aa56c70d554f117fab
Author: tex <te...@fzi.de>
AuthorDate: Fri Mar 6 11:06:53 2020 +0100
[STREAMPIPES-79] select 'custom' button if user set a custom daterange
---
.../components/time-selector/timeRangeSelector.component.html | 4 ++--
.../components/time-selector/timeRangeSelector.component.ts | 5 +++++
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.html b/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.html
index e528332..5fcf091 100644
--- a/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.html
+++ b/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.html
@@ -24,7 +24,7 @@
[owlDateTime]="dt1"
[owlDateTimeTrigger]="dt1"
[(ngModel)]="dateRange.startDate"
- (dateTimeChange)="reloadData()">
+ (dateTimeChange)="changeCustomDateRange()">
<mat-icon matSuffix [owlDateTimeTrigger]="dt1" style="color: grey">event</mat-icon>
<owl-date-time #dt1></owl-date-time>
</mat-form-field>
@@ -34,7 +34,7 @@
[owlDateTime]="dt2"
[owlDateTimeTrigger]="dt2"
[(ngModel)]="dateRange.endDate"
- (dateTimeChange)="reloadData()">
+ (dateTimeChange)="changeCustomDateRange()">
<mat-icon matSuffix [owlDateTimeTrigger]="dt2" style="color: grey">event</mat-icon>
<owl-date-time #dt2></owl-date-time>
</mat-form-field>
diff --git a/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.ts b/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.ts
index 77718e3..2c41be2 100644
--- a/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.ts
+++ b/ui/src/app/data-explorer-v2/components/time-selector/timeRangeSelector.component.ts
@@ -55,6 +55,11 @@ export class TimeRangeSelectorComponent implements OnInit {
this.dateRangeEmitter.emit(this.dateRange);
}
+ changeCustomDateRange() {
+ this.selectedTimeButton = this.possibleTimeButtons[this.possibleTimeButtons.length - 1];
+ this.reloadData();
+ }
+
/**
* Sets the current date range from now to the value of offset in the past
* @param offset in minutes