【类 型】:fix
【主 题】:刷新飞机操作页面时 取一次飞机的状态码 飞机有更新时去一次状态码 【描 述】: [原因]:刷新页面之后 实时更新飞机的状态 [过程]: [影响]: 【结 束】 # 类型 包含: # feat:新功能(feature) # fix:修补bug # docs:文档(documentation) # style: 格式(不影响代码运行的变动) # refactor:重构(即不是新增功能,也不是修改bug的代码变动) # test:增加测试 # chore:构建过程或辅助工具的变动
This commit is contained in:
parent
3d47d2c32e
commit
6f83434965
@ -70,7 +70,7 @@
|
|||||||
<el-button-group>
|
<el-button-group>
|
||||||
<el-button size="mini" class="f-s-14" v-if="planeState & 1 && airLock" key="pubBut" type="info"
|
<el-button size="mini" class="f-s-14" v-if="planeState & 1 && airLock" key="pubBut" type="info"
|
||||||
icon="iconfont el-icon-loading" disabled>
|
icon="iconfont el-icon-loading" disabled>
|
||||||
<font class="m-l-5">航线锁定</font>
|
<font class="m-l-5">注册航线</font>
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button size="mini" class="f-s-14" v-if="planeState & 1 && !airLock" type="primary"
|
<el-button size="mini" class="f-s-14" v-if="planeState & 1 && !airLock" type="primary"
|
||||||
icon="f-s-14 iconfont icon-chakanzhihangrizhi" @click="checkQuest">
|
icon="f-s-14 iconfont icon-chakanzhihangrizhi" @click="checkQuest">
|
||||||
@ -639,6 +639,8 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
|
// 初始化
|
||||||
|
// 当站点列表 航线列表都载入之后 判断飞机的锁定状态airLock
|
||||||
if (this.siteList && this.routeList) {
|
if (this.siteList && this.routeList) {
|
||||||
this.airLock = this.siteList.some(item => {
|
this.airLock = this.siteList.some(item => {
|
||||||
if (item.runing) {
|
if (item.runing) {
|
||||||
@ -648,6 +650,8 @@ export default {
|
|||||||
return false
|
return false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 主动获取飞机状态
|
||||||
|
this.publishFun('{getPlaneState:1}')
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
airLock (val) {
|
airLock (val) {
|
||||||
@ -674,6 +678,12 @@ export default {
|
|||||||
if (!found) {
|
if (!found) {
|
||||||
this.questForm.id = ''
|
this.questForm.id = ''
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
plane (val) {
|
||||||
|
this.publishFun('{getPlaneState:1}')
|
||||||
|
},
|
||||||
|
planeState (val) {
|
||||||
|
console.log(val)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse the time to string
|
* Parse the time to string
|
||||||
* @param {(Object|string|number)} time
|
* @param {(Object|string|number)} time
|
||||||
|
@ -91,7 +91,7 @@ export default {
|
|||||||
this.form.upFile = ''
|
this.form.upFile = ''
|
||||||
},
|
},
|
||||||
handleUpSuccess (res) {
|
handleUpSuccess (res) {
|
||||||
this.$refs.mapbox.makeRoute(res.content)// 绘出航线
|
this.$refs.mapbox.makeRoute(res.content.questAss)// 绘出航线
|
||||||
if (res.status === 0) {
|
if (res.status === 0) {
|
||||||
this.fileList = []
|
this.fileList = []
|
||||||
this.$message.error(res.msg)
|
this.$message.error(res.msg)
|
||||||
|
Loading…
Reference in New Issue
Block a user