|
|
@ -57,7 +57,7 @@
|
|
|
|
</el-radio-group>
|
|
|
|
</el-radio-group>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="flexnr">
|
|
|
|
<div class="flexnr" v-loading="loading" v-if="newzzList.length !== 0">
|
|
|
|
<div class="dybox" v-for="(dyitem, index) in newzzList" :key="index">
|
|
|
|
<div class="dybox" v-for="(dyitem, index) in newzzList" :key="index">
|
|
|
|
<h4>电压等级:{{ dyitem.name }}</h4>
|
|
|
|
<h4>电压等级:{{ dyitem.name }}</h4>
|
|
|
|
<div
|
|
|
|
<div
|
|
|
@ -67,25 +67,21 @@
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<h4>线路:{{ xlitem.name }}</h4>
|
|
|
|
<h4>线路:{{ xlitem.name }}</h4>
|
|
|
|
<div class="zzbox">
|
|
|
|
<div class="zzbox">
|
|
|
|
<el-checkbox-group v-model="zzListCheck">
|
|
|
|
<el-checkbox-group v-model="zzListCheck" @change="handleCheckBox">
|
|
|
|
<el-checkbox
|
|
|
|
<el-checkbox
|
|
|
|
:label="zzitem.displayName"
|
|
|
|
:label="zzitem.id"
|
|
|
|
v-for="(zzitem, index) in xlitem.list"
|
|
|
|
v-for="(zzitem, index) in xlitem.list"
|
|
|
|
:key="index"
|
|
|
|
:key="index"
|
|
|
|
></el-checkbox>
|
|
|
|
:checked="checked"
|
|
|
|
|
|
|
|
>{{ zzitem.displayName }}</el-checkbox
|
|
|
|
|
|
|
|
>
|
|
|
|
</el-checkbox-group>
|
|
|
|
</el-checkbox-group>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- <div class="w50">通道:</div>
|
|
|
|
</div>
|
|
|
|
<el-tree
|
|
|
|
<div class="flexnr" v-else>
|
|
|
|
:data="listnr"
|
|
|
|
<p class="nochannel">暂无通道</p>
|
|
|
|
show-checkbox
|
|
|
|
|
|
|
|
:props="defaultProps"
|
|
|
|
|
|
|
|
ref="tree"
|
|
|
|
|
|
|
|
node-key="id"
|
|
|
|
|
|
|
|
:default-expand-all="true"
|
|
|
|
|
|
|
|
></el-tree> -->
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
@ -167,6 +163,8 @@ export default {
|
|
|
|
//新是数据结构参数
|
|
|
|
//新是数据结构参数
|
|
|
|
newzzList: [],
|
|
|
|
newzzList: [],
|
|
|
|
zzListCheck: [],
|
|
|
|
zzListCheck: [],
|
|
|
|
|
|
|
|
loading: false,
|
|
|
|
|
|
|
|
checked: false,
|
|
|
|
};
|
|
|
|
};
|
|
|
|
},
|
|
|
|
},
|
|
|
|
mounted() {},
|
|
|
|
mounted() {},
|
|
|
@ -190,16 +188,22 @@ export default {
|
|
|
|
//选择通道
|
|
|
|
//选择通道
|
|
|
|
handleChange() {
|
|
|
|
handleChange() {
|
|
|
|
console.log(this.checkedAisle);
|
|
|
|
console.log(this.checkedAisle);
|
|
|
|
|
|
|
|
this.loading = true;
|
|
|
|
getTermListByChannelJoggle({
|
|
|
|
getTermListByChannelJoggle({
|
|
|
|
id: this.checkedAisle,
|
|
|
|
id: this.checkedAisle,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
.then((res) => {
|
|
|
|
.then((res) => {
|
|
|
|
console.log(res);
|
|
|
|
console.log(res);
|
|
|
|
this.newzzList = res.data.list;
|
|
|
|
this.newzzList = res.data.list;
|
|
|
|
|
|
|
|
this.checked = true;
|
|
|
|
|
|
|
|
console.log(this.zzListCheck);
|
|
|
|
|
|
|
|
this.loading = false;
|
|
|
|
})
|
|
|
|
})
|
|
|
|
.catch((err) => {});
|
|
|
|
.catch((err) => {});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
handleCheckBox() {
|
|
|
|
|
|
|
|
console.log(this.zzListCheck);
|
|
|
|
|
|
|
|
},
|
|
|
|
//遍历数据
|
|
|
|
//遍历数据
|
|
|
|
eachTreeData(data, callback, childKey) {
|
|
|
|
eachTreeData(data, callback, childKey) {
|
|
|
|
if (!childKey) childKey = "children";
|
|
|
|
if (!childKey) childKey = "children";
|
|
|
@ -259,18 +263,44 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
// 保存确定操作
|
|
|
|
// 保存确定操作
|
|
|
|
submitForm() {
|
|
|
|
submitForm() {
|
|
|
|
this.getCheckedNodes();
|
|
|
|
console.log(this.zzListCheck);
|
|
|
|
if (this.parmsList.length == 0)
|
|
|
|
console.log(this.checkedAisle);
|
|
|
|
return this.$message.error("通道不能为空");
|
|
|
|
let checkzzList = [];
|
|
|
|
setScheduleRulel({ list: this.parmsList, ruleid: this.selid })
|
|
|
|
for (let i = 0; i < this.zzListCheck.length; i++) {
|
|
|
|
.then((res) => {
|
|
|
|
console.log(this.zzListCheck[i]);
|
|
|
|
this.isShow = false;
|
|
|
|
checkzzList.push({
|
|
|
|
this.$message.success("添加成功");
|
|
|
|
termid: this.zzListCheck[i],
|
|
|
|
this.$parent.deviceList();
|
|
|
|
channelidlist: [this.checkedAisle],
|
|
|
|
})
|
|
|
|
|
|
|
|
.catch((err) => {
|
|
|
|
|
|
|
|
this.$message.error("添加失败");
|
|
|
|
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
console.log(checkzzList);
|
|
|
|
|
|
|
|
if (this.zzListCheck.length == 0) {
|
|
|
|
|
|
|
|
this.$message.error("请选择通道");
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
setScheduleRulel({
|
|
|
|
|
|
|
|
scheduleid: this.selid,
|
|
|
|
|
|
|
|
list: checkzzList,
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
.then((res) => {
|
|
|
|
|
|
|
|
this.isShow = false;
|
|
|
|
|
|
|
|
this.$message.success("添加成功");
|
|
|
|
|
|
|
|
this.$parent.deviceList();
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
.catch((err) => {
|
|
|
|
|
|
|
|
this.$message.error("添加失败");
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
// if (this.parmsList.length == 0)
|
|
|
|
|
|
|
|
// return this.$message.error("通道不能为空");
|
|
|
|
|
|
|
|
// setScheduleRulel({ list: this.parmsList, ruleid: this.selid })
|
|
|
|
|
|
|
|
// .then((res) => {
|
|
|
|
|
|
|
|
// this.isShow = false;
|
|
|
|
|
|
|
|
// this.$message.success("添加成功");
|
|
|
|
|
|
|
|
// this.$parent.deviceList();
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// .catch((err) => {
|
|
|
|
|
|
|
|
// this.$message.error("添加失败");
|
|
|
|
|
|
|
|
// });
|
|
|
|
},
|
|
|
|
},
|
|
|
|
display() {
|
|
|
|
display() {
|
|
|
|
this.isShow = true;
|
|
|
|
this.isShow = true;
|
|
|
@ -296,8 +326,38 @@ export default {
|
|
|
|
border: 1px solid #eee;
|
|
|
|
border: 1px solid #eee;
|
|
|
|
padding: 16px;
|
|
|
|
padding: 16px;
|
|
|
|
border-radius: 4px;
|
|
|
|
border-radius: 4px;
|
|
|
|
.el-tree {
|
|
|
|
.dybox {
|
|
|
|
flex: 1;
|
|
|
|
h4 {
|
|
|
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
|
|
|
color: #333;
|
|
|
|
|
|
|
|
line-height: 24px;
|
|
|
|
|
|
|
|
font-weight: normal;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
.xlbox {
|
|
|
|
|
|
|
|
h4 {
|
|
|
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
|
|
|
color: #333;
|
|
|
|
|
|
|
|
line-height: 24px;
|
|
|
|
|
|
|
|
font-weight: normal;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
margin-left: 16px;
|
|
|
|
|
|
|
|
.zzbox {
|
|
|
|
|
|
|
|
margin-left: 16px;
|
|
|
|
|
|
|
|
.el-checkbox-group {
|
|
|
|
|
|
|
|
.el-checkbox {
|
|
|
|
|
|
|
|
line-height: 24px;
|
|
|
|
|
|
|
|
width: 196px;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
.nochannel {
|
|
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
|
|
height: 100%;
|
|
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
|
|
justify-content: center;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
.w50 {
|
|
|
|
.w50 {
|
|
|
|