|
@ -13,7 +13,7 @@ |
|
|
margin-right: 20rpx; |
|
|
margin-right: 20rpx; |
|
|
padding:20rpx; |
|
|
padding:20rpx; |
|
|
border-radius: 8rpx;"> |
|
|
border-radius: 8rpx;"> |
|
|
<view class="uni-center" style="width: 25%; "> |
|
|
<view class="uni-center"> |
|
|
位置 : |
|
|
位置 : |
|
|
</view> |
|
|
</view> |
|
|
<view class="" style="width: 75%;padding: 0rpx"> |
|
|
<view class="" style="width: 75%;padding: 0rpx"> |
|
@ -140,8 +140,8 @@ |
|
|
scanOptions: {}, |
|
|
scanOptions: {}, |
|
|
editItem: {}, |
|
|
editItem: {}, |
|
|
positionInfo: "请选择位置", |
|
|
positionInfo: "请选择位置", |
|
|
positionList:[], |
|
|
positionList: [], |
|
|
defaultValueList:[] |
|
|
defaultValueList: [] |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
created() { |
|
|
created() { |
|
@ -154,12 +154,12 @@ |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
openScanPopup(content, jobcontent) { |
|
|
openScanPopup(content, jobcontent) { |
|
|
debugger |
|
|
|
|
|
this.issueRecord = []; |
|
|
this.issueRecord = []; |
|
|
this.dataContent = content; |
|
|
this.dataContent = content; |
|
|
this.jobContent = jobcontent; |
|
|
this.jobContent = jobcontent; |
|
|
this.initData(); |
|
|
this.initData(); |
|
|
this.positionInfo =this.jobContent.workShopCode+"-"+this.jobContent.subList[0].productionLineCode+"-"+this.jobContent.subList[0].workStationCode |
|
|
this.positionInfo = this.jobContent.workShopCode + "-" + this.jobContent.subList[0].productionLineCode + |
|
|
|
|
|
"-" + this.jobContent.subList[0].workStationCode |
|
|
this.$refs.popup.open('bottom'); |
|
|
this.$refs.popup.open('bottom'); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -171,7 +171,6 @@ |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
initData() { |
|
|
initData() { |
|
|
debugger |
|
|
|
|
|
let that = this; |
|
|
let that = this; |
|
|
that.fromLocationList = []; |
|
|
that.fromLocationList = []; |
|
|
if (that.dataContent != null) { |
|
|
if (that.dataContent != null) { |
|
@ -237,19 +236,19 @@ |
|
|
|
|
|
|
|
|
getBalanceByManagementPrecision(result.label, that.fromLocationCode, balanceRes => { |
|
|
getBalanceByManagementPrecision(result.label, that.fromLocationCode, balanceRes => { |
|
|
if (balanceRes.success) { |
|
|
if (balanceRes.success) { |
|
|
if (balanceRes.Data.length == 0) { |
|
|
if (balanceRes.data.list.length == 0) { |
|
|
this.showErrorMessage('在来源库位[' + this.fromLocationCode + '],未查找到该包装的库存记录', |
|
|
this.showErrorMessage('在来源库位[' + this.fromLocationCode + '],未查找到该包装的库存记录', |
|
|
res => { |
|
|
res => { |
|
|
this.packGetFocus(); |
|
|
this.packGetFocus(); |
|
|
}) |
|
|
}) |
|
|
} else if (balanceRes.Data.length == 1) { |
|
|
} else if (balanceRes.data.list.length == 1) { |
|
|
let balance = balanceRes.Data[0]; |
|
|
let balance = balanceRes.data.list[0]; |
|
|
this.afterGetBalance(result.label, balance); |
|
|
this.afterGetBalance(result.label, balance); |
|
|
} else { |
|
|
} else { |
|
|
this.showBalanceSelect(balanceRes.Data); |
|
|
this.showBalanceSelect(balanceRes.data.list); |
|
|
} |
|
|
} |
|
|
} else { |
|
|
} else { |
|
|
this.showErrorMessage(balanceRes.message); |
|
|
this.showErrorMessage(balanceRes.message.message); |
|
|
} |
|
|
} |
|
|
uni.hideLoading(); |
|
|
uni.hideLoading(); |
|
|
}); |
|
|
}); |
|
@ -274,16 +273,18 @@ |
|
|
if (batch.Records == undefined) { |
|
|
if (batch.Records == undefined) { |
|
|
batch.Records = []; |
|
|
batch.Records = []; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
let record = batch.Records.find(r => r.packingNumber == packingCode); |
|
|
let record = batch.Records.find(r => r.packingNumber == packingCode); |
|
|
if (record == undefined) { |
|
|
if (record == undefined) { |
|
|
//有推荐箱码 |
|
|
|
|
|
if (batch.Recommends != undefined) { |
|
|
//如果有推荐箱码 |
|
|
|
|
|
if (batch.Recommends.length > 0) { |
|
|
let recommend = batch.Recommends.find(r => r.packingNumber == packingCode); |
|
|
let recommend = batch.Recommends.find(r => r.packingNumber == packingCode); |
|
|
if (recommend != undefined) { |
|
|
if (recommend != undefined) { |
|
|
that.addRecord(batch, label, balance) |
|
|
that.addRecord(batch, label, balance) |
|
|
} else { |
|
|
} else { |
|
|
//允许修改箱码 |
|
|
//允许修改箱码 |
|
|
if (this.jobContent.AllowModifyPackingNumber) { |
|
|
if (this.jobContent.allowModifyPackingNumber == 'TRUE') { |
|
|
that.addRecord(batch, label, balance); |
|
|
that.addRecord(batch, label, balance); |
|
|
} else { |
|
|
} else { |
|
|
that.showErrorMessage('未查找到该箱码【' + packingCode + '】的明细', |
|
|
that.showErrorMessage('未查找到该箱码【' + packingCode + '】的明细', |
|
|