From 30f4204ca6fb295d0f3d9cae41fbb4e62321beb4 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Tue, 05 Dec 2023 10:03:37 +0800
Subject: [PATCH] 处理按钮显示
---
src/components/leftNav/index.vue | 34 +++++++++++++++++++++-------------
1 files changed, 21 insertions(+), 13 deletions(-)
diff --git a/src/components/leftNav/index.vue b/src/components/leftNav/index.vue
index b614d06..62346dc 100644
--- a/src/components/leftNav/index.vue
+++ b/src/components/leftNav/index.vue
@@ -152,7 +152,6 @@
})
},
- inject: ["layoutElement"],
watch: {
calenderShow: {
handler (newData, oldData) {
@@ -206,12 +205,6 @@
}
},
immediate: true
- },
-
- 'layoutElement.campusValue': {
- handler (newData) {
- console.log(newData, 99911)
- }
}
},
methods: {
@@ -273,10 +266,25 @@
}
},
- initialize () {
+ initialize (campus) {
var that = this
- getTagList().then((res) => {
+ this.leftNavData[0].flag = true
+ this.leftNavData[0].img = this.leftNavData[0].checked
+ this.leftNavData[5].flag = true
+ this.leftNavData[5].img = this.leftNavData[5].checked
+
+ this.leftNavBQ.setVisible(true)
+ this.leftNavCR.setVisible(true)
+
+ that.leftNavBQ.getSource().clear()
+ that.leftNavDL.getSource().clear()
+ that.leftNavSJ.getSource().clear()
+ that.leftNavHD.getSource().clear()
+ that.leftNavTC.getSource().clear()
+ that.leftNavCR.getSource().clear()
+
+ getTagList({ campus }).then((res) => {
res.data.data.forEach((item, index) => {
let obj = {}
if (item.x && item.x != '') {
@@ -325,7 +333,7 @@
})
})
- getWayList().then((res) => {
+ getWayList({ campus }).then((res) => {
res.data.data.forEach((item) => {
let obj = {}
if (item.x && item.x != '') {
@@ -403,7 +411,7 @@
// })
// })
- getSceneList().then((res) => {
+ getSceneList({ campus }).then((res) => {
res.data.data.records.forEach((item) => {
let obj = {}
if (item.x && item.x != '') {
@@ -466,7 +474,7 @@
})
})
- getLifeList({ lifetype: 11 }).then((res) => {
+ getLifeList({ lifetype: 11, campus }).then((res) => {
res.data.data.forEach((item) => {
let obj = {}
if (item.x && item.x != '') {
@@ -507,7 +515,7 @@
})
})
- getLifeList({ lifetype: 12 }).then((res) => {
+ getLifeList({ lifetype: 12, campus }).then((res) => {
res.data.data.forEach((item) => {
let obj = {}
if (item.x && item.x != '') {
--
Gitblit v1.9.3