|
|
|
@ -6,6 +6,31 @@
|
|
|
|
|
direction="rtl"
|
|
|
|
|
>
|
|
|
|
|
<div class="ytDraw">
|
|
|
|
|
<div class="channelBox">
|
|
|
|
|
<span>云台通道:</span>
|
|
|
|
|
<el-select
|
|
|
|
|
v-model="ytChannel"
|
|
|
|
|
placeholder="请选择通道"
|
|
|
|
|
ref="multiSelect"
|
|
|
|
|
>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="item in channelListOption"
|
|
|
|
|
:key="item.channelid"
|
|
|
|
|
:label="
|
|
|
|
|
item.alias !== null && item.alias !== ''
|
|
|
|
|
? item.alias
|
|
|
|
|
: item.channelname
|
|
|
|
|
"
|
|
|
|
|
:value="item.channelid"
|
|
|
|
|
>
|
|
|
|
|
{{
|
|
|
|
|
item.alias !== null && item.alias !== ""
|
|
|
|
|
? item.alias
|
|
|
|
|
: item.channelname
|
|
|
|
|
}}
|
|
|
|
|
</el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="openClass">
|
|
|
|
|
<el-button type="primary" @click="openPowerFun()">开启</el-button>
|
|
|
|
|
<el-button type="warning" @click="closePowerFun()">关闭</el-button>
|
|
|
|
@ -300,6 +325,7 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
deviceTimer: null, //装置循环获取
|
|
|
|
|
deviceNum: 1, //循环次数
|
|
|
|
|
ytChannel: "",
|
|
|
|
|
};
|
|
|
|
|
},
|
|
|
|
|
computed: {
|
|
|
|
@ -313,6 +339,7 @@ export default {
|
|
|
|
|
this.termId = this.areaData.id;
|
|
|
|
|
this.ptzdrawer = true;
|
|
|
|
|
this.getPresetList();
|
|
|
|
|
this.getChannelList();
|
|
|
|
|
},
|
|
|
|
|
getPresetList() {
|
|
|
|
|
getPresetApi({
|
|
|
|
@ -629,7 +656,7 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: "channel",
|
|
|
|
|
value: 1,
|
|
|
|
|
value: this.ytChannel,
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: "preset",
|
|
|
|
@ -688,7 +715,12 @@ export default {
|
|
|
|
|
getChannelByTermidJoggle({ termid: this.areaData.id })
|
|
|
|
|
.then((res) => {
|
|
|
|
|
console.log(res);
|
|
|
|
|
this.channelListOption = res.data.list;
|
|
|
|
|
const filteredChannelList = res.data.list.filter(
|
|
|
|
|
(channel) => channel.type === 1
|
|
|
|
|
);
|
|
|
|
|
this.channelListOption = filteredChannelList;
|
|
|
|
|
this.ytChannel = filteredChannelList[0].channelid;
|
|
|
|
|
//this.channelListOption = res.data.list;
|
|
|
|
|
})
|
|
|
|
|
.catch((err) => {
|
|
|
|
|
console.log(err); //代码错误、请求失败捕获
|
|
|
|
@ -822,6 +854,12 @@ export default {
|
|
|
|
|
//display: flex;
|
|
|
|
|
padding: 12px;
|
|
|
|
|
height: 100%;
|
|
|
|
|
.channelBox {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
color: #333;
|
|
|
|
|
margin-bottom: 12px;
|
|
|
|
|
}
|
|
|
|
|
.openClass {
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-around;
|
|
|
|
|