diff options
author | Vitalii Lysak <v.lysak@dunice.net> | 2022-07-25 15:23:54 +0300 |
---|---|---|
committer | Vitalii Lysak <v.lysak@dunice.net> | 2022-07-25 15:23:54 +0300 |
commit | ea146a43e4d58ac0541c9c3c6a2193e9809ca501 (patch) | |
tree | 2cf8e8d3e1492b7653a2e088821f1b0f7140bc41 /src/store/modules | |
parent | 7f9753363138b3005a8f7e41f8ca569b79da4f5d (diff) | |
download | webui-vue-ea146a43e4d58ac0541c9c3c6a2193e9809ca501.tar.xz |
upd fans dynamic
Diffstat (limited to 'src/store/modules')
-rw-r--r-- | src/store/modules/_sila/HardwareStatus/FanStore.js | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/store/modules/_sila/HardwareStatus/FanStore.js b/src/store/modules/_sila/HardwareStatus/FanStore.js index a7647f3d..c7b30099 100644 --- a/src/store/modules/_sila/HardwareStatus/FanStore.js +++ b/src/store/modules/_sila/HardwareStatus/FanStore.js @@ -47,7 +47,17 @@ const FanStore = { actions: { async getFansDynamic({ commit }) { return await api - .get('/redfish/v1/TelemetryService/MetricReports/hour_data&fans') + .get('/redfish/v1/TelemetryService/MetricReports/hour_data&id=fans') + .then(({ data: { MetricValues = [] } }) => + commit('setFansDynamic', MetricValues) + ) + .catch((error) => console.log(error)); + }, + async getFansDynamicHour({ commit }) { + return await api + .get( + '/redfish/v1/TelemetryService/MetricReports/hour_data&id=fans&period=last_hour' + ) .then(({ data: { MetricValues = [] } }) => commit('setFansDynamic', MetricValues) ) |