Skip to content
Snippets Groups Projects
Commit 673e44fc authored by David Hoese's avatar David Hoese
Browse files

Merge branch 'bugfix-update-startTime' into 'develop'

Fix realtime updates requesting 3 hours of data every update

See merge request !21
parents 3b2edaa2 4598895b
No related branches found
No related tags found
1 merge request!21Fix realtime updates requesting 3 hours of data every update
Pipeline #10435 passed
This diff is collapsed.
This diff is collapsed.
......@@ -128,6 +128,10 @@ function requestPlotUpdate(dataCache, div, plotsInfo, startTime, endTime, interv
interval = '1m';
// hours, minutes, seconds
time_parts = _.map(startTime.split(':'), Number);
if (update) {
// if we're updating then we don't need to get a ton of data every time
startTime = "-00:05:00";
}
dt_in_ms = -1000 * 60 * 60 * time_parts[0] + 1000 * 60 * time_parts[1] + 1000 * time_parts[2];
for (var i in intervalLookUp) {
if (dt_in_ms >= intervalLookUp[i][0]) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment