|
|
|
|
@ -1,6 +1,24 @@ |
|
|
|
|
<template> |
|
|
|
|
<ifrm> |
|
|
|
|
<uni-forms ref="wrForm" class="formBox" label-position="top"> |
|
|
|
|
<uni-forms-item label="物料箱条码:" label-width="100px"> |
|
|
|
|
<view class="bottom-input-row"> |
|
|
|
|
<view class="weight-input-wrapper"> |
|
|
|
|
<view class="input-box"> |
|
|
|
|
<input |
|
|
|
|
type="text" |
|
|
|
|
v-model="boxCode" |
|
|
|
|
@confirm="handleBoxConfirm" |
|
|
|
|
placeholder="物料箱条码" |
|
|
|
|
class="uni-input-border" |
|
|
|
|
confirm-type="done" |
|
|
|
|
:focus="boxInputFocus" |
|
|
|
|
/> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
</uni-forms-item> |
|
|
|
|
<uni-forms-item label="起点站点:" label-width="100px"> |
|
|
|
|
<input |
|
|
|
|
type="text" |
|
|
|
|
@ -48,6 +66,8 @@ export default { |
|
|
|
|
}, |
|
|
|
|
data() { |
|
|
|
|
return { |
|
|
|
|
boxCode: "", |
|
|
|
|
boxInputFocus:true, |
|
|
|
|
startCode: "", //起点站点 |
|
|
|
|
startInputFocus: true, //起点站点输入框聚焦 |
|
|
|
|
startData: null, |
|
|
|
|
@ -60,6 +80,17 @@ export default { |
|
|
|
|
this.getWorkCenterList(); |
|
|
|
|
}, |
|
|
|
|
methods: { |
|
|
|
|
handleBoxConfirm() { |
|
|
|
|
const code = this.boxCode.trim(); |
|
|
|
|
if (!code) return; |
|
|
|
|
// this.$u.api |
|
|
|
|
// .getQuantityLocation({ boxBarcode: this.boxCode }) |
|
|
|
|
// .then((res) => { |
|
|
|
|
// this.boxData = res.data; |
|
|
|
|
this.boxInputFocus = false; |
|
|
|
|
this.startInputFocus = true; |
|
|
|
|
// }); |
|
|
|
|
}, |
|
|
|
|
// 获取作业中心列表 |
|
|
|
|
getWorkCenterList() { |
|
|
|
|
this.$u.api.getWorkCenter().then((res) => { |
|
|
|
|
@ -120,6 +151,7 @@ export default { |
|
|
|
|
title: "提交中...", |
|
|
|
|
}); |
|
|
|
|
let query = { |
|
|
|
|
boxBarcode: this.boxCode || "", //箱条码 |
|
|
|
|
endWcId: this.endCenterIndex, |
|
|
|
|
startStationCode: this.startCode, |
|
|
|
|
}; |
|
|
|
|
@ -133,12 +165,14 @@ export default { |
|
|
|
|
uni.hideLoading(); |
|
|
|
|
|
|
|
|
|
this.startCode = ""; |
|
|
|
|
this.boxCode = "" |
|
|
|
|
this.startData = null; |
|
|
|
|
this.startInputFocus = true; |
|
|
|
|
}) |
|
|
|
|
.catch((err) => { |
|
|
|
|
uni.hideLoading(); |
|
|
|
|
this.startCode = ""; |
|
|
|
|
this.boxCode = "" |
|
|
|
|
this.startData = null; |
|
|
|
|
this.startInputFocus = true; |
|
|
|
|
}); |
|
|
|
|
|