|
@@ -21,9 +21,9 @@
|
|
|
@dragstop="resize">
|
|
|
<a-tooltip>
|
|
|
<template slot="title">
|
|
|
- {{ item.positionNum }}
|
|
|
+ {{ item.result }}
|
|
|
</template>
|
|
|
- <div class="info" @click="handleInfo(item)"> {{ item.positionNum }}</div>
|
|
|
+ <div class="info" @click="handleInfo(item)"> {{ item.result }}</div>
|
|
|
</a-tooltip>
|
|
|
</VueDragResize>
|
|
|
</div>
|
|
@@ -44,12 +44,12 @@
|
|
|
:showSearch="true"
|
|
|
v-model="positionId"
|
|
|
placeholder="请选择"
|
|
|
+ @change="getOpcInfo"
|
|
|
>
|
|
|
</a-tree-select>
|
|
|
- <a-button type="primary" @click="getOpcInfo">搜索</a-button>
|
|
|
</div>
|
|
|
<br>
|
|
|
- <a-table
|
|
|
+ <!-- <a-table
|
|
|
:columns="columns"
|
|
|
:data-source="dotList"
|
|
|
:pagination="{ pageSize: 100 }"
|
|
@@ -60,7 +60,7 @@
|
|
|
<a-button style="color:#ccc" v-show="record.positionFlag" type="link" icon="eye-invisible" @click="handleShow(index,0)" />
|
|
|
<a-button v-show="!record.positionFlag" type="link" icon="eye" @click="handleShow(index,1)" />
|
|
|
</span>
|
|
|
- </a-table>
|
|
|
+ </a-table> -->
|
|
|
</a-drawer>
|
|
|
<BaseChartInfo ref="baseChartInfo" @ok="handleOk"/>
|
|
|
</div>
|
|
@@ -86,6 +86,7 @@ export default {
|
|
|
optDot: null,
|
|
|
imgUrl: '',
|
|
|
dotList: [],
|
|
|
+ timer: null,
|
|
|
columns: [
|
|
|
{
|
|
|
title: '位号',
|
|
@@ -103,7 +104,13 @@ export default {
|
|
|
created () {
|
|
|
this.positionId = this.$route.query.line
|
|
|
this.setTree()
|
|
|
- this.getOpcInfo()
|
|
|
+ this.timer = setInterval(() => {
|
|
|
+ console.log(this.positionId)
|
|
|
+ this.getOpcInfo()
|
|
|
+ }, 5000)
|
|
|
+ },
|
|
|
+ destroyed () {
|
|
|
+ clearInterval(this.timer)
|
|
|
},
|
|
|
methods: {
|
|
|
resize (newRect) {
|
|
@@ -135,11 +142,9 @@ export default {
|
|
|
getOpcInfo () {
|
|
|
fetchSbPosition({ id: this.positionId }).then(res => {
|
|
|
this.imgUrl = res.data.opcImg
|
|
|
- console.log(this.imgUrl)
|
|
|
})
|
|
|
queryRemoteOpc({ line: this.positionId })
|
|
|
.then((res) => {
|
|
|
- console.log(res.data)
|
|
|
this.dotList = res.data
|
|
|
this.dotList.forEach(item => {
|
|
|
item.isActive = false
|