|
|
|
|
@ -4,16 +4,17 @@ |
|
|
|
|
<view class="task global-font" style="font-size: 32rpx;"> |
|
|
|
|
<span>扫描托盘条码:</span> |
|
|
|
|
<u-input v-model="dataForm.containerCode" border |
|
|
|
|
style="background-color: #ffffff;margin-bottom: 20px;margin-top: 20rpx;" placeholder="请输入或输入要搬运的托盘条码" |
|
|
|
|
:focus="focusFlag" @confirm="changeCode()"></u-input> |
|
|
|
|
style="background-color: #ffffff;margin-bottom: 20px;margin-top: 20rpx;" placeholder="请扫描或输入要搬运的托盘条码" |
|
|
|
|
:focus="focusFlag" @input="changeCode()"></u-input> |
|
|
|
|
|
|
|
|
|
<span>搬运起始点位:</span> |
|
|
|
|
<u-input v-model="begin" style="background-color: #ffffff;margin-bottom: 20px;margin-top: 20rpx;" border |
|
|
|
|
<!-- <u-input v-model="begin" style="background-color: #ffffff;margin-bottom: 20px;margin-top: 20rpx;" border |
|
|
|
|
type="select" font-size='32' placeholder="请选择起始点位" prop="wareHouse" class="u-input" |
|
|
|
|
placeholder-style="color:#000000" @click="show = true" /> |
|
|
|
|
<u-select v-model="show" :list="pointList1" @confirm="confirm" mode="single-column"></u-select> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<u-select v-model="show" :list="pointList1" @confirm="confirm" mode="single-column"></u-select> --> |
|
|
|
|
<select-lay @transfer="reomveValue" :pointNoChild="begin" :options="pointList" style="width: 100%; margin-top: 1vh;" |
|
|
|
|
smoldName="ptName" slabel="label" smodel="ptName" name="name3" svalue="value" @selectitem="queryList" |
|
|
|
|
:value="begin" placeholder="选择要释放位置编码" > </select-lay> |
|
|
|
|
</view> |
|
|
|
|
<view class="img1" style="text-align: center;font-size: 32rpx;"> |
|
|
|
|
<!-- <img src="@/static/icon/down.png" alt="" style="width: 300rpx;"> --> |
|
|
|
|
@ -21,10 +22,14 @@ |
|
|
|
|
</view> |
|
|
|
|
<view class="task global-font" style="font-size: 32rpx;"> |
|
|
|
|
<span>搬运目标点位:</span> |
|
|
|
|
<u-input v-model="end" style="background-color: #ffffff;margin-bottom: 20px;margin-top: 20rpx;" border |
|
|
|
|
<!-- <u-input v-model="end" style="background-color: #ffffff;margin-bottom: 20px;margin-top: 20rpx;" border |
|
|
|
|
type="select" font-size='32' placeholder="请选择目标点位" prop="wareHouse" class="u-input" |
|
|
|
|
placeholder-style="color:#000000" @click="showTwo = true" /> |
|
|
|
|
<u-select v-model="showTwo" :list="pointList1" @confirm="confirmTwo" mode="single-column"></u-select> |
|
|
|
|
<u-select v-model="showTwo" :list="pointList1" @confirm="confirmTwo" mode="single-column"></u-select> --> |
|
|
|
|
<select-lay @transfer="reomveValue1" :pointNoChild="end" :options="pointList1" style="margin-top: 1vh;" |
|
|
|
|
smoldName="ptName" slabel="label" smodel="ptName" name="name3" svalue="value" @selectitem="queryList1" |
|
|
|
|
:value="end" placeholder="选择要释放位置编码"> </select-lay> |
|
|
|
|
|
|
|
|
|
</view> |
|
|
|
|
<view class="footer" style="position: absolute;bottom:8%;left: 50%;transform: translateX(-50%);"> |
|
|
|
|
<u-button type="success" @click="checkOutPick()" style="width: 400rpx;background-color: #41ABE2;">开始搬运 |
|
|
|
|
@ -40,6 +45,7 @@ |
|
|
|
|
show: false, |
|
|
|
|
showTwo: false, |
|
|
|
|
focusFlag: true, |
|
|
|
|
flag: true, |
|
|
|
|
begin: '', |
|
|
|
|
endValue: '', |
|
|
|
|
end: '', |
|
|
|
|
@ -49,16 +55,18 @@ |
|
|
|
|
containerCode: '', |
|
|
|
|
endPoint: '', |
|
|
|
|
}, |
|
|
|
|
timer: 0, |
|
|
|
|
pointList: [], |
|
|
|
|
pointList1: [], |
|
|
|
|
pointList2:[], |
|
|
|
|
pointList3:[], |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
onLoad() { |
|
|
|
|
// this.getDic() |
|
|
|
|
|
|
|
|
|
this.$u.api.AvgCarry.getPointList({ |
|
|
|
|
this.$u.api.AvgCarry.getPointList({ |
|
|
|
|
pageNum: 1, |
|
|
|
|
pageSize: 100 |
|
|
|
|
pageSize: 999, |
|
|
|
|
// pointGroup:1 |
|
|
|
|
}).then(res => { |
|
|
|
|
this.pointList = [] |
|
|
|
|
this.pointList1 = [] |
|
|
|
|
@ -73,63 +81,70 @@ |
|
|
|
|
this.pointList1.push(obj); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
// this.$u.api.AvgCarry.getPointList({ |
|
|
|
|
// pageNum: 1, |
|
|
|
|
// pageSize: 999 |
|
|
|
|
// }).then(res => { |
|
|
|
|
// this.pointList2 = [] |
|
|
|
|
// this.pointList3 = [] |
|
|
|
|
// if (res.code == 200) { |
|
|
|
|
// let dataArry = res.rows; |
|
|
|
|
// for (var i = 0; i < dataArry.length; i++) { |
|
|
|
|
// var obj = { |
|
|
|
|
// value: dataArry[i].pointNo, |
|
|
|
|
// label: dataArry[i].pointName, |
|
|
|
|
// }; |
|
|
|
|
// this.pointList2.push(obj); |
|
|
|
|
// this.pointList3.push(obj); |
|
|
|
|
// } |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
// this.getList() |
|
|
|
|
|
|
|
|
|
// }) |
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
methods: { |
|
|
|
|
|
|
|
|
|
changeCode() { |
|
|
|
|
this.focusFlag = false |
|
|
|
|
// this.query = { |
|
|
|
|
// pageNum: 1, |
|
|
|
|
// pageSize: 10 |
|
|
|
|
// } |
|
|
|
|
// this.getDataList() |
|
|
|
|
|
|
|
|
|
this.$u.api.AvgCarry.queryBillingDByContainerCode({ |
|
|
|
|
containerCode: this.dataForm.containerCode |
|
|
|
|
}).then(res => { |
|
|
|
|
// console.log(res); |
|
|
|
|
// res.data=[{ |
|
|
|
|
// "targetPoint":"0460" |
|
|
|
|
// }] |
|
|
|
|
// this.endValue = res.data[0].targetPoint |
|
|
|
|
// this.beginValue= res.data[1].startPoint |
|
|
|
|
// this.pointList.forEach(item=>{ |
|
|
|
|
// if(res.data[0].targetPoint == item.value){ |
|
|
|
|
// this.end = item.label |
|
|
|
|
// } |
|
|
|
|
// if(res.data[1].startPoint == item.value){ |
|
|
|
|
// this.begin = item.label |
|
|
|
|
// } |
|
|
|
|
// }) |
|
|
|
|
this.endValue = res.data[0] ? res.data[0].targetPoint : '' |
|
|
|
|
this.beginValue = res.data[1] ? res.data[1].startPoint : '' |
|
|
|
|
this.pointList.forEach(item => { |
|
|
|
|
if (res.data[0]) { |
|
|
|
|
if (res.data[0].targetPoint == item.value) { |
|
|
|
|
this.end = item.label |
|
|
|
|
clearTimeout(this.timer) |
|
|
|
|
//防抖节流 |
|
|
|
|
this.flag = true |
|
|
|
|
if (this.flag === false) return; |
|
|
|
|
this.flag = false; |
|
|
|
|
this.timer = setTimeout(() => { |
|
|
|
|
this.flag = true |
|
|
|
|
this.focusFlag = false |
|
|
|
|
this.$u.api.AvgCarry.queryBillingDByContainerCode({ |
|
|
|
|
containerCode: this.dataForm.containerCode |
|
|
|
|
}).then(res => { |
|
|
|
|
this.endValue = res.data[0] ? res.data[0].targetPoint : '' |
|
|
|
|
this.beginValue = res.data[1] ? res.data[1].startPoint : '' |
|
|
|
|
this.pointList.forEach(item => { |
|
|
|
|
if (res.data[0]) { |
|
|
|
|
if (res.data[0].targetPoint == item.value) { |
|
|
|
|
this.end = item.label |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
if (res.data[1]) { |
|
|
|
|
if (res.data[1].startPoint == item.value) { |
|
|
|
|
this.begin = item.label |
|
|
|
|
|
|
|
|
|
if (res.data[1]) { |
|
|
|
|
if (res.data[1].startPoint == item.value) { |
|
|
|
|
this.begin = item.label |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
// this.end = res.data |
|
|
|
|
this.pointList1 = this.pointList.filter(item => item.value != this.beginValue && item.value != |
|
|
|
|
this.endValue) |
|
|
|
|
// this.pointList1 = this.pointList.filter(item => item.value != this.beginValue && item.value != |
|
|
|
|
// this.endValue) |
|
|
|
|
// this.dataForm.endPoint = res.data |
|
|
|
|
// this.endValue=res.data |
|
|
|
|
this.pointList = this.pointList.filter(item => item.value != this.beginValue && item.value != |
|
|
|
|
this.endValue) |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
this.$forceUpdate() |
|
|
|
|
},800) |
|
|
|
|
}, |
|
|
|
|
//呼叫搬运 |
|
|
|
|
checkOutPick() { |
|
|
|
|
@ -150,7 +165,6 @@ |
|
|
|
|
this.$u.toast("请选择目标位置"); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
// }).catch(err=>console.log(err)) |
|
|
|
|
this.$u.api.AvgCarry.agvCarry({ |
|
|
|
|
startPoint: this.beginValue, |
|
|
|
|
toLocation: this.endValue, |
|
|
|
|
@ -188,6 +202,17 @@ |
|
|
|
|
} |
|
|
|
|
}).catch(err => {}) |
|
|
|
|
}, |
|
|
|
|
// 选择点位 |
|
|
|
|
queryList(index,item){ |
|
|
|
|
this.begin=item.label |
|
|
|
|
this.beginValue=item.value |
|
|
|
|
this.judge() |
|
|
|
|
}, |
|
|
|
|
queryList1(index,item){ |
|
|
|
|
this.end = item.label |
|
|
|
|
this.endValue = item.value |
|
|
|
|
this.judge() |
|
|
|
|
}, |
|
|
|
|
//获取点位 |
|
|
|
|
async getList() { |
|
|
|
|
this.list = []; |
|
|
|
|
@ -206,14 +231,22 @@ |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
this.showList = [...this.list] |
|
|
|
|
// console.log(this.list) |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
reomveValue(){ |
|
|
|
|
this.beginValue = '' |
|
|
|
|
this.begin = '' |
|
|
|
|
}, |
|
|
|
|
reomveValue1(){ |
|
|
|
|
this.end = '' |
|
|
|
|
this.endValue = '' |
|
|
|
|
}, |
|
|
|
|
//过滤数组 |
|
|
|
|
judge(e) { |
|
|
|
|
// console.log(e); |
|
|
|
|
// console.log(this.pointList); |
|
|
|
|
this.pointList1 = this.pointList.filter(item => item.value != this.beginValue && item.value != this |
|
|
|
|
.endValue) |
|
|
|
|
.endValue) |
|
|
|
|
// this.pointList = this.pointList1.filter(item => item.value != this.beginValue && item.value != this |
|
|
|
|
// .endValue) |
|
|
|
|
}, |
|
|
|
|
confirm(e) { |
|
|
|
|
this.begin = e[0].label |
|
|
|
|
@ -234,7 +267,7 @@ |
|
|
|
|
@import "index.scss"; |
|
|
|
|
|
|
|
|
|
.img1 { |
|
|
|
|
height: 220px; |
|
|
|
|
height: 200px; |
|
|
|
|
background-image: url(@/static/down.png); |
|
|
|
|
background-size: 50% 100%; |
|
|
|
|
background-repeat: no-repeat; |
|
|
|
|
|