summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVitalii Lysak <v.lysak@dunice.net>2022-09-01 13:55:17 +0300
committerVitalii Lysak <v.lysak@dunice.net>2022-09-01 13:55:17 +0300
commit05bdca11621aadc480ccf4c131bf57ab1a0919f1 (patch)
tree2abe31762956141a328943fd6548a95a771fc07b
parentf87473c306093d7006f9c9aca4545917adcefcbc (diff)
downloadwebui-vue-05bdca11621aadc480ccf4c131bf57ab1a0919f1.tar.xz
upd bmc time only if server status is on
-rw-r--r--src/store/modules/GlobalStore.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/store/modules/GlobalStore.js b/src/store/modules/GlobalStore.js
index 72f1c473..262d1163 100644
--- a/src/store/modules/GlobalStore.js
+++ b/src/store/modules/GlobalStore.js
@@ -83,7 +83,10 @@ const GlobalStore = {
actions: {
changeServerStatus({ commit, dispatch }, status) {
commit('setServerStatus', status);
- dispatch('getBmcTime');
+
+ if (serverStateMapper(status) === 'on') {
+ dispatch('getBmcTime');
+ }
},
initLiveClock({ commit, state }) {
if (state.clockInterval) {