Przeglądaj źródła

feat(views): 初步添加“能耗分析”和“报警管理”模块

wangcong 2 miesięcy temu
rodzic
commit
00623216f7

+ 4 - 0
src/i18n/locales/zh.json

@@ -1,4 +1,5 @@
 {
+  "alarmManage": {},
   "common": {
     "add": "添加",
     "addNew": "新增",
@@ -173,6 +174,7 @@
     },
     "viewData": "查看数据"
   },
+  "energyAnalysis": {},
   "envMonitor": {
     "addArea": "添加区域",
     "addInspectionPoints": "添加检测点",
@@ -251,9 +253,11 @@
   "hvacHome": {},
   "keywordLibrary": {},
   "navigation": {
+    "alarmManage": "报警管理",
     "deviceList": "设备列表",
     "deviceManage": "设备管理",
     "deviceWorkStatus": "设备工况",
+    "energyAnalysis": "能耗分析",
     "envMonitor": "环境监控",
     "gatewayList": "网关列表",
     "gatewayManage": "网关管理",

+ 42 - 0
src/router/index.ts

@@ -83,6 +83,48 @@ const routes: Readonly<RouteRecordRaw[]> = [
       },
     ],
   },
+  {
+    path: '/energy-analysis',
+    redirect: '/energy-analysis/index',
+    component: HvacLayout,
+    meta: {
+      title: 'energyAnalysis',
+      icon: 'setting',
+      hideSubMenu: true,
+      requiresAuth: true,
+    },
+    children: [
+      {
+        path: 'index',
+        name: 'energyAnalysis',
+        component: () => import('@/views/energy-analysis/EnergyAnalysis.vue'),
+        meta: {
+          requiresAuth: true,
+        },
+      },
+    ],
+  },
+  {
+    path: '/alarm-manage',
+    redirect: '/alarm-manage/index',
+    component: HvacLayout,
+    meta: {
+      title: 'alarmManage',
+      icon: 'setting',
+      hideSubMenu: true,
+      requiresAuth: true,
+    },
+    children: [
+      {
+        path: 'index',
+        name: 'alarmManage',
+        component: () => import('@/views/alarm-manage/AlarmManage.vue'),
+        meta: {
+          requiresAuth: true,
+        },
+      },
+    ],
+  },
   {
     path: '/protocol-manage',
     name: 'protocolManage',

+ 3 - 0
src/views/alarm-manage/AlarmManage.vue

@@ -0,0 +1,3 @@
+<template>
+  <div>报警管理</div>
+</template>

+ 3 - 0
src/views/energy-analysis/EnergyAnalysis.vue

@@ -0,0 +1,3 @@
+<template>
+  <div>能耗分析</div>
+</template>