From d7e24c64a3961040fdc7fec835c2efa5d2f106c0 Mon Sep 17 00:00:00 2001
From: ZZJ <zzjdsg2300@163.com>
Date: 星期日, 26 九月 2021 19:54:54 +0800
Subject: [PATCH] 弹层层级bug修复v2
---
src/pages/settings/views/NetSettings.vue | 32 +++++++++++++++++++++-----------
1 files changed, 21 insertions(+), 11 deletions(-)
diff --git a/src/pages/settings/views/NetSettings.vue b/src/pages/settings/views/NetSettings.vue
index 4abaf73..5cc0c70 100644
--- a/src/pages/settings/views/NetSettings.vue
+++ b/src/pages/settings/views/NetSettings.vue
@@ -7,11 +7,14 @@
:class="activePage == i ? 'menu-item-active' : ''"
v-for="(item, i) in tabList"
:key="i"
- @click="openRight(item, i)"
+ @click="openRight(i)"
ref="leftbar"
>
- <span class="icon iconfont">{{ item.icon }}</span>
+ <div>
+ <span class="icon iconfont">{{ item.icon }}</span>
<span class="text">{{ item.name }}</span>
+ </div>
+ <span v-if="showStatus && i==2" class="status">宸茶繛鎺�</span>
</div>
</div>
<div class="net-right">
@@ -227,10 +230,10 @@
<div class="name">{{ "缃戠粶" + item.index }}</div>
<div class="right">
- <span class="icon iconfont good" v-if="item.lower_up"
+ <span class="icon iconfont good" v-if="item.lower_up&&item.active"
></span
>
- <span class="icon iconfont bad" v-else></span>
+ <span class="icon iconfont bad" v-if="!item.lower_up&&item.active"></span>
<el-switch
v-model="item.active"
active-color="rgba(61, 104, 225, 1)"
@@ -238,6 +241,7 @@
></el-switch>
</div>
</div>
+
</div>
<div class="wire-detail" v-if="activePage == 2 && inWireDetail">
<div class="title">缃戠粶璁剧疆</div>
@@ -436,7 +440,7 @@
}
});
},
- openRight(item, i) {
+ openRight(i) {
this.activePage = i;
if (i == 1) {
this.inWifiDetail = false;
@@ -497,6 +501,11 @@
this.openWireDetail(item);
});
},
+ },
+ computed: {
+ showStatus(){
+ return this.wireArr.some((item) => item.lower_up==true)
+ }
},
};
</script>
@@ -569,23 +578,24 @@
border-radius: 8px;
line-height: 50px;
box-sizing: border-box;
- font-size: 14px;
+ font-size: 14px; cursor: pointer;
padding: 0 20px;
display: flex;
+ justify-content: space-between;
.icon {
- margin-right: 12px;
- font-size: 19px;
+ margin-right: 8px;
+ font-size: 18px;
}
.text {
- font-size: 16px;
+ font-size: 15px;
}
}
.menu-item-active {
- background-color: #3d68e1;
+ background-color: var(--colorCard);
color: white;
}
.menu-item:hover {
- background-color: #3d68e1;
+ background-color: var(--colorCard);
color: white;
}
}
--
Gitblit v1.8.0