From c47a27b826f7d76410308a4151611a366f9eaf46 Mon Sep 17 00:00:00 2001 From: Georgios Andreadis Date: Fri, 25 Aug 2017 17:48:12 +0200 Subject: Fetch and display datacenter topology --- src/reducers/topology.js | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 src/reducers/topology.js (limited to 'src/reducers/topology.js') diff --git a/src/reducers/topology.js b/src/reducers/topology.js new file mode 100644 index 00000000..caafb7c1 --- /dev/null +++ b/src/reducers/topology.js @@ -0,0 +1,10 @@ +import {FETCH_LATEST_DATACENTER_SUCCEEDED} from "../actions/topology"; + +export function currentDatacenterId(state = -1, action) { + switch (action.type) { + case FETCH_LATEST_DATACENTER_SUCCEEDED: + return action.datacenterId; + default: + return state; + } +} -- cgit v1.2.3