From f119fc78dda4d1e828dde04f378a63a93e3a0a7e Mon Sep 17 00:00:00 2001 From: Georgios Andreadis Date: Thu, 2 Jul 2020 18:39:28 +0200 Subject: Add current progress on frontend port --- frontend/src/containers/app/map/layers/ObjectHoverLayer.js | 2 +- frontend/src/containers/app/map/layers/RoomHoverLayer.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'frontend/src/containers/app/map/layers') diff --git a/frontend/src/containers/app/map/layers/ObjectHoverLayer.js b/frontend/src/containers/app/map/layers/ObjectHoverLayer.js index dc489e82..4619c0b8 100644 --- a/frontend/src/containers/app/map/layers/ObjectHoverLayer.js +++ b/frontend/src/containers/app/map/layers/ObjectHoverLayer.js @@ -19,7 +19,7 @@ const mapStateToProps = state => { ) const tile = findTileWithPosition(tiles, x, y) - return !(tile === null || tile.objectType) + return !(tile === null || tile.rackId) }, } } diff --git a/frontend/src/containers/app/map/layers/RoomHoverLayer.js b/frontend/src/containers/app/map/layers/RoomHoverLayer.js index b5a891ce..c05627ea 100644 --- a/frontend/src/containers/app/map/layers/RoomHoverLayer.js +++ b/frontend/src/containers/app/map/layers/RoomHoverLayer.js @@ -21,9 +21,9 @@ const mapStateToProps = state => { .map(id => Object.assign({}, state.objects.room[id])) .filter( room => - state.objects.datacenter[state.currentDatacenterId].roomIds.indexOf( - room.id, - ) !== -1 && room.id !== state.construction.currentRoomInConstruction, + state.objects.topology[state.currentTopologyId].roomIds.indexOf( + room._id, + ) !== -1 && room._id !== state.construction.currentRoomInConstruction, ); [...oldRooms, newRoom].forEach(room => { -- cgit v1.2.3