Compare commits

...

3 Commits

Author SHA1 Message Date
xiaomeng 72c593b4de Merge pull request 'pc-master' (#16) from pc-master into portal
Reviewed-on: #16
2023-10-17 09:22:10 +00:00
孙萌 e92d96ef0f 设定值页面默认设置为状态设置 2023-10-17 17:21:10 +08:00
孙萌 28be7eec0e 1 2023-10-17 17:08:49 +08:00
3 changed files with 5 additions and 5 deletions

Binary file not shown.

View File

@ -13,9 +13,9 @@
<template slot="title" class="collapse-title"> <template slot="title" class="collapse-title">
{{ item.name }} {{ item.name }}
</template> </template>
<!-- :class="routerNow == item1.router ? 'active' : ''" --> <!-- -->
<ul class="table-ul"> <ul class="table-ul">
<li @click="toRouter(item1)" class="table-li" v-for="item1, index1 in item.list" :key="index1">{{ <li @click="toRouter(item1)" :class="routerNow == item1.router&&routerIndex==index1+1 ? 'active' : ''" class="table-li" v-for="item1, index1 in item.list" :key="index1">{{
item1.name }} <div class="status" :class="item1.status == 0 ? 'outline' : 'online'" item1.name }} <div class="status" :class="item1.status == 0 ? 'outline' : 'online'"
v-if="item1.status >= 0">{{ item1.status v-if="item1.status >= 0">{{ item1.status
== 0 == 0
@ -96,7 +96,7 @@ export default {
}, },
gerRouter() { gerRouter() {
this.routerNow = this.$route.name; this.routerNow = this.$route.name;
this.routerIndex = this.$route.query.index ? this.$route.query.index : 1 this.routerIndex = this.$route.query.id ? this.$route.query.id : 1
}, },
toRouter(item) { toRouter(item) {
if (item.router) { if (item.router) {

View File

@ -61,7 +61,7 @@ export default {
headerActive: 0, headerActive: 0,
headerList: [ headerList: [
{ name: '实时数据', router: 'realTime', routerList: ['realTime'], img: require('../assets/image/header-img1.png') }, { name: '实时数据', router: 'realTime', routerList: ['realTime'], img: require('../assets/image/header-img1.png') },
{ name: '设定值参数', router: 'formula', index: 1, routerList: ['formula', 'irrigateSet', 'PIDSet', 'systemSet', 'upload', 'sensorSet'], img: require('../assets/image/header-img0.png') }, { name: '设定值参数', router: 'irrigateSet', index: 1, routerList: ['formula', 'irrigateSet', 'PIDSet', 'systemSet', 'upload', 'sensorSet'], img: require('../assets/image/header-img0.png') },
{ name: '设备菜单', router: '', routerList: [], img: require('../assets/image/header-img1.png') }, { name: '设备菜单', router: '', routerList: [], img: require('../assets/image/header-img1.png') },
{ name: '视频监控', router: '', routerList: [], img: require('../assets/image/header-img2.png') }, { name: '视频监控', router: '', routerList: [], img: require('../assets/image/header-img2.png') },
// history history // history history
@ -190,7 +190,7 @@ export default {
window.location.href = item.http; window.location.href = item.http;
} else if (item.router == 'formula' && this.$route.query.index != item.index) { } else if (item.router == 'formula' && this.$route.query.index != item.index) {
this.$store.state.equipmentIndex = item.index this.$store.state.equipmentIndex = item.index
this.$router.push({ path: `/${item.router}?index=${item.index ? item.index : 1}` }) this.$router.push({ path: `/${item.router}?id=${item.index ? item.index : 1}` })
}else if (item.router == 'history' && this.$route.query.index != item.index) { }else if (item.router == 'history' && this.$route.query.index != item.index) {
this.$router.push({ path: `/history?index=${item.index ? item.index : 1}` }) this.$router.push({ path: `/history?index=${item.index ? item.index : 1}` })