Merge pull request #2127 from nasa/plot-requests-2126

[Plot] Prevent duplicate query on bounds change
This commit is contained in:
Deep Tailor 2018-07-31 12:32:57 -07:00 committed by GitHub
commit 081edfbd70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -181,7 +181,9 @@ define([
};
this.config.xAxis.set('range', newRange);
if (!isTick) {
this.skipReloadOnInteraction = true;
this.$scope.$broadcast('plot:clearHistory');
this.skipReloadOnInteraction = false;
this.loadMoreData(newRange, true);
} else {
// Drop any data that is more than 1x (max-min) before min.
@ -234,7 +236,9 @@ define([
var xDisplayRange = this.config.xAxis.get('displayRange');
var xRange = this.config.xAxis.get('range');
this.loadMoreData(xDisplayRange);
if (!this.skipReloadOnInteraction) {
this.loadMoreData(xDisplayRange);
}
this.synchronized(xRange.min === xDisplayRange.min &&
xRange.max === xDisplayRange.max);