Skip to content
Snippets Groups Projects
Commit e89febd7 authored by Bucknell, Mary S.'s avatar Bucknell, Mary S.
Browse files

Revert "Start of changes for IOW-176"

This reverts commit 706b2fb9.
parent 706b2fb9
No related branches found
No related tags found
No related merge requests found
......@@ -502,15 +502,6 @@ export const attachToNode = function (store, node, {siteno, parameter, compare,
return;
}
if (compare) {
store.dispatch(Actions.toggleTimeSeries('compare', true));
}
// If specified, initialize the cursorOffset
if (cursorOffset !== undefined) {
store.dispatch(Actions.setCursorOffset(cursorOffset));
}
store.dispatch(Actions.resizeUI(window.innerWidth, node.offsetWidth));
select(node)
.call(provide(store))
......@@ -523,6 +514,16 @@ export const attachToNode = function (store, node, {siteno, parameter, compare,
sizeClass: () => 'fa-3x'
})));
// If specified, turn the visibility of the comparison time series on.
if (compare) {
store.dispatch(Actions.toggleTimeSeries('compare', true));
}
// If specified, initialize the cursorOffset
if (cursorOffset !== undefined) {
store.dispatch(Actions.setCursorOffset(cursorOffset));
}
select(node).select('.graph-container')
.call(link(controlDisplay, hasTimeSeriesWithPoints('current', 'P7D')))
.call(timeSeriesGraph, siteno)
......
......@@ -69,7 +69,7 @@ const removeLoadingTimeSeries = function(timeSeriesState, action) {
};
};
const setRequestedTimeRange = function(timeSeriesState, action) {
const requestedTimeRange = function(timeSeriesState, action) {
return {
...timeSeriesState,
requestedTimeRange: {startDT: action.startTime, endDT: action.endTime}
......@@ -90,7 +90,7 @@ export const timeSeriesStateReducer = function(timeSeriesState={}, action) {
case 'TIME_SERIES_PLAY_STOP': return timeSeriesPlayStop(timeSeriesState, action);
case 'TIME_SERIES_LOADING_ADD': return addLoadingTimeSeries(timeSeriesState, action);
case 'TIME_SERIES_LOADING_REMOVE': return removeLoadingTimeSeries(timeSeriesState, action);
case 'SET_CUSTOM_DATE_RANGE': return setRequestedTimeRange(timeSeriesState, action);
case 'SET_CUSTOM_DATE_RANGE': return requestedTimeRange(timeSeriesState, action);
default: return timeSeriesState;
}
};
......@@ -6,7 +6,7 @@
"scripts": {
"test": "nyc jasmine",
"start": "DEBUG=express:* node src/index.js",
"watch": "STATIC_ROOT=http://localhost:9000 DEBUG=express:* nodemon src"
"watch": "STATIC_ROOT=http://localhost:9000 nodemon src"
},
"engines": {
"node": "12.13.1"
......
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