|
|
|
@ -15,8 +15,8 @@ |
|
|
|
<image class="Icon" :src="deviceData.autoDockLightFlag==0?errorIcon:normalIcon"/> |
|
|
|
</view> |
|
|
|
<view> |
|
|
|
<span>急停有效:</span> |
|
|
|
<image class="Icon" :src="deviceData.stopLightFlag==0?errorIcon:normalIcon"/> |
|
|
|
<span>急停状态:</span> |
|
|
|
<image class="Icon" :src="deviceData.stopLightFlag==0?errorIcon:stopIcon"/> |
|
|
|
</view> |
|
|
|
<view> |
|
|
|
<span>自动装填:</span> |
|
|
|
@ -46,14 +46,14 @@ |
|
|
|
</view> |
|
|
|
|
|
|
|
<view> |
|
|
|
<view style="width: 25%;">急停有效:</view> |
|
|
|
<view style="width: 25%;">急停状态:</view> |
|
|
|
<view > |
|
|
|
<image class="Icon" :src="normalIcon"/>: |
|
|
|
<span>有效</span> |
|
|
|
<image class="Icon" :src="stopIcon"/>: |
|
|
|
<span>急停</span> |
|
|
|
</view> |
|
|
|
<view > |
|
|
|
<image class="Icon" :src="errorIcon"/>: |
|
|
|
<span>无效</span> |
|
|
|
<span>正常</span> |
|
|
|
</view> |
|
|
|
|
|
|
|
</view> |
|
|
|
@ -149,7 +149,7 @@ |
|
|
|
</view> |
|
|
|
<view style="width: 24%;"> |
|
|
|
<span class="infoTitle">编码器位置:</span> |
|
|
|
<span class="detail">{{deviceData.encoderPosition}}mm</span> |
|
|
|
<span class="detail">{{deviceData.encoderPosition}}圈</span> |
|
|
|
</view> |
|
|
|
<view style="width: 10%;opacity: 0;"> |
|
|
|
|
|
|
|
@ -186,11 +186,11 @@ |
|
|
|
<view class="controlButton"> |
|
|
|
<view class="deviceitle control">设备控制</view> |
|
|
|
<view class="controlContent"> |
|
|
|
<view @click="controlDevice(1)">对接</view> |
|
|
|
<view @click="controlDevice(2)">装填</view> |
|
|
|
<view @click="controlDevice(3)">退货</view> |
|
|
|
<view @click="controlDevice(4)">急停</view> |
|
|
|
<view @click="controlDevice(5)">恢复</view> |
|
|
|
<view @click="controlDevice(1,'对接')">对接</view> |
|
|
|
<view @click="controlDevice(2,'装填')">装填</view> |
|
|
|
<view @click="controlDevice(3,'退货')">退货</view> |
|
|
|
<view @click="controlDevice(4,'急停')">急停</view> |
|
|
|
<view @click="controlDevice(5,'恢复')">恢复</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
@ -235,32 +235,45 @@ |
|
|
|
lightFlag: 1,//设备状态:0-正常、1-异常 |
|
|
|
}, |
|
|
|
errorIcon:'../../static/image/error.png', |
|
|
|
normalIcon:'../../static/image/normal.png' |
|
|
|
normalIcon:'../../static/image/normal.png', |
|
|
|
stopIcon:'../../static/image/stopIcon.png' |
|
|
|
} |
|
|
|
}, |
|
|
|
methods:{ |
|
|
|
controlDevice(value){ |
|
|
|
controlDevice(value,contents){ |
|
|
|
console.log(value) |
|
|
|
httpPost({ |
|
|
|
url:`/zhxx/dt/horizonLoadIControl/${value}`, |
|
|
|
data:{} |
|
|
|
}).then((res)=>{ |
|
|
|
console.log(res) |
|
|
|
|
|
|
|
if(res.data.code==200){ |
|
|
|
this.$eventBus.emit('showToast',{title:res.data.msg,duration:1000,icon:'success'}) |
|
|
|
}else { |
|
|
|
console.log(22222) |
|
|
|
this.$eventBus.emit('showToast',{title:res.data.msg?res.data.msg:'请求失败',duration:1000,icon:'error'}) |
|
|
|
let that=this; |
|
|
|
|
|
|
|
uni.showModal({ |
|
|
|
title:'提示', |
|
|
|
content:`是否执行${contents}操作?`, |
|
|
|
success:function(states) { |
|
|
|
if(states.confirm){ |
|
|
|
httpPost({ |
|
|
|
url:`/zhxx/dt/horizonLoadIControl/${value}`, |
|
|
|
data:{} |
|
|
|
}).then((res)=>{ |
|
|
|
console.log(res) |
|
|
|
|
|
|
|
if(res.data.code==200){ |
|
|
|
that.$eventBus.emit('showToast',{title:res.data.msg,duration:1000,icon:'success'}) |
|
|
|
}else { |
|
|
|
console.log(res.data.msg) |
|
|
|
that.$eventBus.emit('showToast',{title:res.data.msg?res.data.msg:'请求失败',duration:1000,icon:'error'}) |
|
|
|
} |
|
|
|
}).catch((Error)=>{ |
|
|
|
// console.log(Error) |
|
|
|
uni.showToast({ |
|
|
|
title: Error, |
|
|
|
icon: "error", |
|
|
|
duration: 1000 |
|
|
|
}) |
|
|
|
}) |
|
|
|
}else{ |
|
|
|
console.log('fewfewfew') |
|
|
|
} |
|
|
|
} |
|
|
|
}).catch((Error)=>{ |
|
|
|
// console.log(Error) |
|
|
|
uni.showToast({ |
|
|
|
title: Error, |
|
|
|
icon: "error", |
|
|
|
duration: 1000 |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
}, |
|
|
|
computed:{ |
|
|
|
@ -393,8 +406,8 @@ |
|
|
|
} |
|
|
|
|
|
|
|
.Icon{ |
|
|
|
width: 24px; |
|
|
|
height: 24px; |
|
|
|
width: 18px; |
|
|
|
height: 20px; |
|
|
|
} |
|
|
|
|
|
|
|
.left-bottom{ |
|
|
|
|