Commit 30b612f0 authored by 李志鸣's avatar 李志鸣

fix(avi 详情页): 修改avi跳转逻辑

parent d3a43356
......@@ -24,6 +24,22 @@
:tableConfig="tableConfig"
@onPageSizeChange="onSizeChange"
@onCurrentPageChange="onCurrentChange">
<template slot="currentRuntime">
<el-table-column
label="当班运行时间">
<template slot-scope="scope">
<span>{{scope.row.currentRuntime !== null ? `${scope.row.currentRuntime}(h)` : '暂无'}}</span>
</template>
</el-table-column>
</template>
<template slot="totalRuntime">
<el-table-column
label="累计运行时间">
<template slot-scope="scope">
<span>{{scope.row.totalRuntime !== null ? `${scope.row.totalRuntime}(h)` : '暂无'}}</span>
</template>
</el-table-column>
</template>
</Table>
</div>
</div>
......@@ -52,8 +68,8 @@
{ label: '车间', value: 'workshopCode' },
{ label: '设备编号', value: 'equipCode' },
{ label: '设备名称', value: 'alias' },
{ label: '当班运行时间', value: 'currentRuntime' },
{ label: '累计运行时间', value: 'totalRuntime' }
{ label: '当班运行时间', value: 'currentRuntime', slot: 'currentRuntime' },
{ label: '累计运行时间', value: 'totalRuntime', slot: 'totalRuntime' }
],
paginationToggle: true,
paginationConfig: {
......
......@@ -650,6 +650,10 @@ export default {
},
data () {
return {
// 工单
orderNo: '',
// 订单号
workOrderNo: '',
// 定时器
timer: null,
// 当前在线人数
......@@ -660,14 +664,14 @@ export default {
query: {},
// 根据车身号获得当前车体信息
BusInformation: {}
};
}
},
mounted () {
this.pollingGetInterface();
this.pollingGetInterface()
},
beforeDestroy () {
clearInterval(this.timer);
clearInterval(this.timer)
},
methods: {
// 获取面色/漆作业区实时信息
......@@ -719,13 +723,11 @@ export default {
},
// 查询车辆定位
getCarPostion () {
let queryParams = { orderNo: '1111', workOrderNo: '' };
let queryParams = { orderNo: this.orderNo, workOrderNo: this.workOrderNo }
// 请求接口
this.$fetch('area-controller/busNo-get', { queryParams }).then(
res => {
this.carPostionInfo = _.cloneDeep(res);
}
);
this.$fetch('area-controller/workOrderNo-get', { queryParams }).then(res => {
this.carPostionInfo = _.cloneDeep(res)
})
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -736,19 +738,15 @@ export default {
// 轮询请求接口
pollingGetInterface () {
// 查询车辆定位
console.log('2222', this.$route.query);
if (
this.$route.query.hasOwnProperty('orderNo') ||
this.$route.query.hasOwnProperty('workOrderNo')
) {
this.getCarPostion();
}
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
this.getCarPostion()
// 获取面色/漆作业区实时信息
this.getComplexionPaintInformation();
this.getComplexionPaintInformation()
this.timer = setInterval(() => {
this.carPostionInfo = {};
this.carPostionInfo = {}
// 获取面色/漆作业区实时信息
this.getComplexionPaintInformation();
this.getComplexionPaintInformation()
}, 20000);
}
}
......
......@@ -455,6 +455,10 @@ export default {
},
data () {
return {
// 工单
orderNo: '',
// 订单号
workOrderNo: '',
//定时器
timer: null,
// 车辆定位数据
......@@ -465,15 +469,13 @@ export default {
query: {},
// 根据车身号获得当前车体信息
BusInformation: {}
};
}
},
mounted () {
this.pollingGetInterface();
console.log('2222', this.timer);
console.log(this.$root.$children[0].$el)
this.pollingGetInterface()
},
beforeDestroy () {
clearInterval(this.timer);
clearInterval(this.timer)
},
methods: {
// 点击车位弹出车体信息
......@@ -526,13 +528,11 @@ export default {
},
// 查询车辆定位
getCarPostion () {
let queryParams = { orderNo: '1111', workOrderNo: '' };
let queryParams = { orderNo: this.orderNo, workOrderNo: this.workOrderNo }
// 请求接口
this.$fetch('area-controller/busNo-get', { queryParams }).then(
res => {
this.carPostionInfo = _.cloneDeep(res);
}
);
this.$fetch('area-controller/workOrderNo-get', { queryParams }).then(res => {
this.carPostionInfo = _.cloneDeep(res)
})
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -543,18 +543,15 @@ export default {
// 轮询请求接口
pollingGetInterface () {
// 查询车辆定位
if (
this.$route.query.hasOwnProperty('orderNo') ||
this.$route.query.hasOwnProperty('workOrderNo')
) {
this.getCarPostion();
}
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
this.getCarPostion()
// 获取电泳作业区实时信息
this.getElectrophoresisInformation();
this.getElectrophoresisInformation()
this.timer = setInterval(() => {
this.carPostionInfo = {};
// 获取电泳作业区实时信息
this.getElectrophoresisInformation();
this.getElectrophoresisInformation()
}, 20000);
}
}
......
......@@ -156,6 +156,10 @@ export default {
},
data () {
return {
// 工单
orderNo: '',
// 订单号
workOrderNo: '',
// 成品车作业区实时信息
query: {},
// 轮询定时器
......@@ -166,7 +170,7 @@ export default {
carPostionInfo: {},
// 根据车身号获得当前车体信息
BusInformation: {}
};
}
},
mounted () {
this.pollingGetInterface();
......@@ -224,13 +228,11 @@ export default {
},
// 查询车辆定位
getCarPostion () {
let queryParams = { orderNo: '1111', workOrderNo: '' };
let queryParams = { orderNo: this.orderNo, workOrderNo: this.workOrderNo }
// 请求接口
this.$fetch('area-controller/busNo-get', { queryParams }).then(
res => {
this.carPostionInfo = _.cloneDeep(res);
}
);
this.$fetch('area-controller/workOrderNo-get', { queryParams }).then(res => {
this.carPostionInfo = _.cloneDeep(res)
})
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -241,18 +243,15 @@ export default {
// 轮询请求接口
pollingGetInterface () {
// 查询车辆定位
if (
this.$route.query.hasOwnProperty('orderNo') ||
this.$route.query.hasOwnProperty('workOrderNo')
) {
this.getCarPostion();
}
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
this.getCarPostion()
// 获取成品车作业区实时信息
this.getFinishedCarInformation();
this.getFinishedCarInformation()
this.timer = setInterval(() => {
this.carPostionInfo = {};
this.carPostionInfo = {}
// 获取成品车作业区实时信息
this.getFinishedCarInformation();
this.getFinishedCarInformation()
}, 20000);
}
}
......
......@@ -205,6 +205,10 @@ export default {
},
data () {
return {
// 工单
orderNo: '',
// 订单号
workOrderNo: '',
// 中涂作业区实时信息
query: {},
// 轮询定时器
......@@ -215,14 +219,14 @@ export default {
carPostionInfo: {},
// 根据车身号获得当前车体信息
BusInformation: {}
};
}
},
mounted () {
this.pollingGetInterface();
this.pollingGetInterface()
},
beforeDestroy () {
clearInterval(this.timer);
clearInterval(this.timer)
},
methods: {
// 获取中涂作业区实时信息
......@@ -273,13 +277,11 @@ export default {
},
// 查询车辆定位
getCarPostion () {
let queryParams = { orderNo: '1111', workOrderNo: '' };
let queryParams = { orderNo: this.orderNo, workOrderNo: this.workOrderNo }
// 请求接口
this.$fetch('area-controller/busNo-get', { queryParams }).then(
res => {
this.carPostionInfo = _.cloneDeep(res);
}
);
this.$fetch('area-controller/workOrderNo-get', { queryParams }).then(res => {
this.carPostionInfo = _.cloneDeep(res)
})
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -290,18 +292,15 @@ export default {
// 轮询请求接口
pollingGetInterface () {
// 查询车辆定位
if (
this.$route.query.hasOwnProperty('orderNo') ||
this.$route.query.hasOwnProperty('workOrderNo')
) {
this.getCarPostion();
}
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
this.getCarPostion()
// 获取电泳作业区实时信息
this.getMiddleCoatInformation();
this.getMiddleCoatInformation()
this.timer = setInterval(() => {
this.carPostionInfo = {};
this.carPostionInfo = {}
// 获取电泳作业区实时信息
this.getMiddleCoatInformation();
this.getMiddleCoatInformation()
}, 20000);
}
}
......
......@@ -229,6 +229,10 @@ export default {
},
data () {
return {
// 工单
orderNo: '',
// 订单号
workOrderNo: '',
// 定时器
timer: null,
// 腻子作业区实时信息
......@@ -239,11 +243,11 @@ export default {
carPostionInfo: {},
// 当前在线人数
onlineNum: null
};
}
},
mounted () {
this.pollingGetInterface();
this.pollingGetInterface()
},
methods: {
......@@ -299,13 +303,11 @@ export default {
},
// 查询车辆定位
getCarPostion () {
let queryParams = { orderNo: '', workOrderNo: '' };
let queryParams = { orderNo: this.orderNo, workOrderNo: this.workOrderNo }
// 请求接口
this.$fetch('area-controller/busNo-get', { queryParams }).then(
res => {
this.carPostionInfo = _.cloneDeep(res);
}
);
this.$fetch('area-controller/workOrderNo-get', { queryParams }).then(res => {
this.carPostionInfo = _.cloneDeep(res)
})
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -316,18 +318,15 @@ export default {
// 轮询请求接口
pollingGetInterface () {
// 查询车辆定位
if (
this.$route.query.hasOwnProperty('orderNo') ||
this.$route.query.hasOwnProperty('workOrderNo')
) {
this.getCarPostion();
}
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
this.getCarPostion()
// 获取腻子作业区实时信息
this.getPuttyInformation();
this.getPuttyInformation()
this.timer = setInterval(() => {
this.carPostionInfo = {};
this.carPostionInfo = {}
// 获取腻子作业区实时信息
this.getPuttyInformation();
this.getPuttyInformation()
}, 20000);
}
}
......
......@@ -325,7 +325,7 @@ export default {
carPostion: {},
// 当前车体信息
currentBusInfo: {}
};
}
},
methods: {
// 解析车体类型及车体定位样式
......@@ -376,12 +376,12 @@ export default {
let queryParams = {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
};
}
this.$fetch('area-controller/workOrderNo-get', queryParams).then(
response => {
this.carPostion = _.cloneDeep(response);
this.carPostion = _.cloneDeep(response)
}
);
)
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -391,21 +391,23 @@ export default {
},
// 轮询查询区域实时信息
pollingGetAreaRealTimeData () {
// 获取密封防腐作业区实时数据
this.getSealedAnticorrosionRealTimeData();
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
// 根据工单号或订单号定位当前车体位置
this.getCurrentPosition();
this.getCurrentPosition()
// 获取密封防腐作业区实时数据
this.getSealedAnticorrosionRealTimeData()
setInterval(() => {
this.carPostion = {};
this.carPostion = {}
// 获取密封防腐作业区实时数据
this.getSealedAnticorrosionRealTimeData();
this.getSealedAnticorrosionRealTimeData()
}, 20000);
}
},
mounted () {
setTimeout(() => {
// 轮询查询区域实时信息
this.pollingGetAreaRealTimeData();
this.pollingGetAreaRealTimeData()
}, 0);
}
};
......
......@@ -306,6 +306,10 @@ export default {
},
data () {
return {
// 工单
orderNo: '',
// 订单号
workOrderNo: '',
// 定时器
timer: null,
// 当前在线人数
......@@ -319,10 +323,10 @@ export default {
};
},
mounted () {
this.pollingGetInterface();
this.pollingGetInterface()
},
beforeDestroy () {
clearInterval(this.timer);
clearInterval(this.timer)
},
methods: {
// 获取钣金车存放区实时信息
......@@ -377,13 +381,11 @@ export default {
},
// 查询车辆定位
getCarPostion () {
let queryParams = { orderNo: '1111', workOrderNo: '' };
let queryParams = { orderNo: this.orderNo, workOrderNo: this.workOrderNo }
// 请求接口
this.$fetch('area-controller/busNo-get', { queryParams }).then(
res => {
this.carPostionInfo = _.cloneDeep(res);
}
);
this.$fetch('area-controller/workOrderNo-get', { queryParams }).then(res => {
this.carPostionInfo = _.cloneDeep(res)
})
},
// 点击返回AVI大屏首页
doReturnMonitorIndex () {
......@@ -394,17 +396,15 @@ export default {
// 轮询请求接口
pollingGetInterface () {
// 查询车辆定位
if (
this.$route.query.hasOwnProperty('orderNo') || this.$route.query.hasOwnProperty('workOrderNo')
) {
this.getCarPostion();
}
this.orderNo = this.$route.query.orderNo
this.workOrderNo = this.$route.query.workOrderNo
this.getCarPostion()
// 获取钣金作业区实时信息
this.getSheetMetalInformation();
this.getSheetMetalInformation()
this.timer = setInterval(() => {
this.carPostionInfo = {};
this.carPostionInfo = {}
// 获取钣金作业区实时信息
this.getSheetMetalInformation();
this.getSheetMetalInformation()
}, 20000);
}
}
......
......@@ -1626,43 +1626,71 @@
// 点击电泳工作区
doElectrophoresisClick () {
this.$router.push({
path: '/monitor/monitorElectrophoresis'
path: '/monitor/monitorElectrophoresis',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 点击腻子作业区
doPuttyClick () {
this.$router.push({
path: '/monitor/monitorPutty'
path: '/monitor/monitorPutty',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 点击中涂作业区
doMiddleCoatClick () {
this.$router.push({
path: '/monitor/monitorMiddleCoat'
path: '/monitor/monitorMiddleCoat',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 点击面/色漆作业区
doComplexionPaintClick () {
this.$router.push({
path: '/monitor/monitorComplexionPaint'
path: '/monitor/monitorComplexionPaint',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 点击钣金车存放区
doSheetMetalCarClick () {
this.$router.push({
path: '/monitor/monitorSheetMetalCar'
path: '/monitor/monitorSheetMetalCar',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 点击密封防腐作业区
doSealedAnticorrosion () {
this.$router.push({
path: '/monitor/monitorSealedAnticorrosion'
path: '/monitor/monitorSealedAnticorrosion',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 点击成品车存放区
doFinishedCarStorage () {
this.$router.push({
path: '/monitor/monitorFinishedCar'
path: '/monitor/monitorFinishedCar',
query: {
orderNo: this.orderNo,
workOrderNo: this.workOrderNo
}
})
},
// 获取涂装车间实时信息
......
......@@ -102,26 +102,21 @@
},
{
id: 5,
label: '烘干室',
code: 'DRYING_ROOM'
},
{
id: 6,
label: '打磨室',
code: 'POLISHING_ROOM'
},
{
id: 7,
id: 6,
label: '喷涂机器人',
code: 'PAINTING_ROBOT'
},
{
id: 8,
id: 7,
label: '旋转辊床',
code: 'ROTARY_ROLLER_BED'
},
{
id: 9,
id: 8,
label: 'VOC',
code: 'VOC'
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment