Commit e73b306e by Torkel Ödegaard

fix(templating): fixed duplicate dashboard refresh when changing template variable, #7654

parent 46ac8c09
......@@ -96,11 +96,15 @@ class TimeSrv {
this.initTimeFromUrl();
this.setTime(this.time, true);
}
} else {
} else if (this.timeHasChangedSinceLoad()) {
this.setTime(this.timeAtLoad, true);
}
}
private timeHasChangedSinceLoad() {
return this.timeAtLoad.from !== this.time.from || this.timeAtLoad.to !== this.time.to;
}
setAutoRefresh(interval) {
this.dashboard.refresh = interval;
if (interval) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment