diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue index 864d37a..12e63e3 100644 --- a/src/layout/components/Navbar.vue +++ b/src/layout/components/Navbar.vue @@ -39,14 +39,14 @@
@@ -113,12 +113,15 @@ import { NavTypeEnum } from '@/enums/NavTypeEnum'; import Logo from '@/layout/components/Sidebar/Logo.vue'; import TopBar from './TopBar'; import { getDemo } from '@/api/systemList/index'; +import { useWarningListStore } from '@/store/modules/warnningList'; const appStore = useAppStore(); +const warningListStore = useWarningListStore(); const userStore = useUserStore(); const settingsStore = useSettingsStore(); const noticeStore = storeToRefs(useNoticeStore()); const newNotice = ref(0); +const { warningList, warningListTotal } = storeToRefs(warningListStore); const { proxy } = getCurrentInstance() as ComponentInternalInstance; @@ -235,6 +238,9 @@ onMounted(() => { logoUrl.value = res.data.url; }); }); +onMounted(() => { + warningListStore.getWarningList(); +});