From: Jérôme Benoit Date: Sun, 28 Aug 2022 15:25:49 +0000 (+0200) Subject: Web UI: fix NPE on connectors X-Git-Tag: v1.1.68~6 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=aeb31e77eef45a146782bffe2fd2401041b38b79;p=e-mobility-charging-stations-simulator.git Web UI: fix NPE on connectors Signed-off-by: Jérôme Benoit --- diff --git a/src/ui/web/src/components/charging-stations/CSData.vue b/src/ui/web/src/components/charging-stations/CSData.vue index 3de9a7d6..ea8fd1da 100644 --- a/src/ui/web/src/components/charging-stations/CSData.vue +++ b/src/ui/web/src/components/charging-stations/CSData.vue @@ -46,7 +46,7 @@ function getHashId(): string { return props.chargingStation.hashId; } function getConnectors(): ConnectorStatus[] { - return props.chargingStation.connectors.slice(1); + return props.chargingStation.connectors?.slice(1); } function getInfo(): ChargingStationInfo { return props.chargingStation.stationInfo; diff --git a/src/ui/web/src/components/charging-stations/CSTable.vue b/src/ui/web/src/components/charging-stations/CSTable.vue index c76d9e4d..04f38aa1 100644 --- a/src/ui/web/src/components/charging-stations/CSTable.vue +++ b/src/ui/web/src/components/charging-stations/CSTable.vue @@ -50,8 +50,9 @@ const props = defineProps<{ #cs-table__head, #cs-table__body { + height: fit-content; width: 100%; - min-width: 930px; + min-width: 100%; display: block; } diff --git a/src/ui/web/src/views/ChargingStationsView.vue b/src/ui/web/src/views/ChargingStationsView.vue index 42e698e5..5476ac4b 100644 --- a/src/ui/web/src/views/ChargingStationsView.vue +++ b/src/ui/web/src/views/ChargingStationsView.vue @@ -77,7 +77,7 @@ function stopSimulator(): void { #reload-button { flex: auto; - padding: 6px 14px; + padding: 5px 15px; background-color: rgb(25, 118, 210); border-radius: 5px; color: white;