diff --git a/src/layouts/BasicLayout.vue b/src/layouts/BasicLayout.vue
index 0353d81b..1b410274 100644
--- a/src/layouts/BasicLayout.vue
+++ b/src/layouts/BasicLayout.vue
@@ -217,6 +217,7 @@ onMounted(() => {
let serverTimeInterval: any = null;
let serverTime = 0;
let serverTimeZone = getTimezoneOffset();
+let activeAlarmRefresh = 0;
// 获取服务器时间
function fnGetServerTime() {
@@ -230,6 +231,7 @@ function fnGetServerTime() {
const serverTimeDom = document.getElementById('serverTimeDom');
serverTimeInterval = setInterval(() => {
serverTime += 1000;
+ activeAlarmRefresh += 1;
if (serverTimeDom) {
serverTimeDom.innerText = parseDateUTCToStr(
serverTime,
@@ -239,6 +241,10 @@ function fnGetServerTime() {
clearInterval(serverTimeInterval);
serverTimeInterval = null;
}
+ if (activeAlarmRefresh === 5) {
+ useAlarmStore().fnGetActiveAlarmInfo();
+ activeAlarmRefresh = 0;
+ }
}, 1000);
}
});
diff --git a/src/views/faultManage/active-alarm/index.vue b/src/views/faultManage/active-alarm/index.vue
index eecc281b..b5aae601 100644
--- a/src/views/faultManage/active-alarm/index.vue
+++ b/src/views/faultManage/active-alarm/index.vue
@@ -1,5 +1,5 @@
@@ -957,7 +982,11 @@ onMounted(() => {
{{ t('views.faultManage.activeAlarm.updateConfirm') }}
-
+
@@ -982,7 +1011,11 @@ onMounted(() => {
{{ t('views.faultManage.activeAlarm.clear') }}
-
+
{{ t('common.export') }}