summaryrefslogtreecommitdiff
path: root/frontend/src/actions/topology
diff options
context:
space:
mode:
authorGeorgios Andreadis <info@gandreadis.com>2020-07-02 18:39:28 +0200
committerFabian Mastenbroek <mail.fabianm@gmail.com>2020-08-24 19:47:21 +0200
commitf119fc78dda4d1e828dde04f378a63a93e3a0a7e (patch)
treebea1eace5d47f21a7ccb835c6a6079bc92e48710 /frontend/src/actions/topology
parent7f27a6370a0af25e1bf6ff8f46360c6c26c21e0b (diff)
Add current progress on frontend port
Diffstat (limited to 'frontend/src/actions/topology')
-rw-r--r--frontend/src/actions/topology/building.js14
-rw-r--r--frontend/src/actions/topology/room.js2
2 files changed, 8 insertions, 8 deletions
diff --git a/frontend/src/actions/topology/building.js b/frontend/src/actions/topology/building.js
index 2d4d399c..da2dc311 100644
--- a/frontend/src/actions/topology/building.js
+++ b/frontend/src/actions/topology/building.js
@@ -1,5 +1,5 @@
-export const SET_CURRENT_DATACENTER = 'SET_CURRENT_DATACENTER'
-export const RESET_CURRENT_DATACENTER = 'RESET_CURRENT_DATACENTER'
+export const SET_CURRENT_TOPOLOGY = 'SET_CURRENT_TOPOLOGY'
+export const RESET_CURRENT_TOPOLOGY = 'RESET_CURRENT_TOPOLOGY'
export const START_NEW_ROOM_CONSTRUCTION = 'START_NEW_ROOM_CONSTRUCTION'
export const START_NEW_ROOM_CONSTRUCTION_SUCCEEDED =
'START_NEW_ROOM_CONSTRUCTION_SUCCEEDED'
@@ -12,16 +12,16 @@ export const FINISH_ROOM_EDIT = 'FINISH_ROOM_EDIT'
export const ADD_TILE = 'ADD_TILE'
export const DELETE_TILE = 'DELETE_TILE'
-export function setCurrentDatacenter(datacenterId) {
+export function setCurrentTopology(topologyId) {
return {
- type: SET_CURRENT_DATACENTER,
- datacenterId,
+ type: SET_CURRENT_TOPOLOGY,
+ topologyId,
}
}
-export function resetCurrentDatacenter() {
+export function resetCurrentTopology() {
return {
- type: RESET_CURRENT_DATACENTER,
+ type: RESET_CURRENT_TOPOLOGY,
}
}
diff --git a/frontend/src/actions/topology/room.js b/frontend/src/actions/topology/room.js
index 3476f0b6..939b475a 100644
--- a/frontend/src/actions/topology/room.js
+++ b/frontend/src/actions/topology/room.js
@@ -35,7 +35,7 @@ export function addRackToTile(positionX, positionY) {
if (tile !== null) {
dispatch({
type: ADD_RACK_TO_TILE,
- tileId: tile.id,
+ tileId: tile._id,
})
}
}