From da13e574c27d25c63c458093904bc3d59eb38599 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=9C=E7=AC=99=E6=AD=8C?= <2277317060@qq.com> Date: Tue, 19 Sep 2023 18:04:11 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=B7=AF=E7=94=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/components/BoardTopNav/index.vue | 29 ++++++++++++++----- 1 file changed, 21 insertions(+), 8 deletions(-) diff --git a/ruoyi-ui/src/components/BoardTopNav/index.vue b/ruoyi-ui/src/components/BoardTopNav/index.vue index f66ff2c..fe5d892 100644 --- a/ruoyi-ui/src/components/BoardTopNav/index.vue +++ b/ruoyi-ui/src/components/BoardTopNav/index.vue @@ -2,27 +2,27 @@
智慧物联监控平台
-
+
监控主页
- + - 智慧场景 + {{ name }} - - {{ i.sceneName }} + + {{ i.sceneName }}
-
+
设备监测
-
+
传感器汇总 @@ -48,7 +48,8 @@ import { export default { data() { return { - selectSecnesList: [] + selectSecnesList: [], + name:'智慧场景' } }, props: { @@ -60,11 +61,23 @@ export default { mounted() { this.setSelectSecnes() + if(this.$route.name === 'SmartScene'){ + if(this.$route.query?.name){ + this.name = this.$route.query?.name + } + } }, methods: { async setSelectSecnes() { const {data} = await selectSecnes() this.selectSecnesList = data + }, + toLink(e){ + this.$router.push({ path: "/board/"+e }); + }, + dropdownLink(e){ + this.name = e.name + this.$router.push({ path: "/board/"+(e.router||'smartScene'),query: {name: e.name} }); } } };