|
@ -7,6 +7,9 @@ |
|
|
<view class="header_item"> |
|
|
<view class="header_item"> |
|
|
申请单号 : {{jobContent.requestNumber}} |
|
|
申请单号 : {{jobContent.requestNumber}} |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
<view class="header_item"> |
|
|
|
|
|
来源仓库 : {{jobContent.fromWarehouseCode}} |
|
|
|
|
|
</view> |
|
|
<u-line color="#D8D8D8" style="margin-bottom: 15rpx;margin-top: 10rpx;"></u-line> |
|
|
<u-line color="#D8D8D8" style="margin-bottom: 15rpx;margin-top: 10rpx;"></u-line> |
|
|
</view> |
|
|
</view> |
|
|
<view class="page-main"> |
|
|
<view class="page-main"> |
|
@ -37,7 +40,8 @@ |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<win-scan-button @goScan='openScanPopup'></win-scan-button> |
|
|
<win-scan-button @goScan='openScanPopup'></win-scan-button> |
|
|
<win-scan-pack-and-location ref="scanPopup" @getResult='getScanResult'></win-scan-pack-and-location> |
|
|
<win-scan-pack ref="scanPopup" @getResult='getScanResult'></win-scan-pack> |
|
|
|
|
|
<!-- <win-scan-pack-and-location ref="scanPopup" @getResult='getScanResult'></win-scan-pack-and-location> --> |
|
|
<detail-info-popup ref="detailInfoPopup"></detail-info-popup> |
|
|
<detail-info-popup ref="detailInfoPopup"></detail-info-popup> |
|
|
|
|
|
|
|
|
<com-message ref="comMessage"></com-message> |
|
|
<com-message ref="comMessage"></com-message> |
|
@ -57,7 +61,8 @@ |
|
|
navigateBack, |
|
|
navigateBack, |
|
|
getPackingNumberAndBatch, |
|
|
getPackingNumberAndBatch, |
|
|
getInventoryStatusName, |
|
|
getInventoryStatusName, |
|
|
getDirectoryItemArray |
|
|
getDirectoryItemArray, |
|
|
|
|
|
compareAsc |
|
|
} from '@/common/basic.js'; |
|
|
} from '@/common/basic.js'; |
|
|
|
|
|
|
|
|
import { |
|
|
import { |
|
@ -75,6 +80,7 @@ |
|
|
import requiredLocation from '@/mycomponents/location/requiredLocation.vue' |
|
|
import requiredLocation from '@/mycomponents/location/requiredLocation.vue' |
|
|
import comMessage from '@/mycomponents/common/comMessage.vue' |
|
|
import comMessage from '@/mycomponents/common/comMessage.vue' |
|
|
import winScanPackAndLocation from "@/mycomponents/scan/winScanPackAndLocation.vue" |
|
|
import winScanPackAndLocation from "@/mycomponents/scan/winScanPackAndLocation.vue" |
|
|
|
|
|
import winScanPack from "@/mycomponents/scan/winScanPack.vue" |
|
|
import comDetailCard from "@/mycomponents/detail/comDetailCard.vue" |
|
|
import comDetailCard from "@/mycomponents/detail/comDetailCard.vue" |
|
|
import detailInfoPopup from '@/pages/transfer/coms/detailInfoPopup.vue' |
|
|
import detailInfoPopup from '@/pages/transfer/coms/detailInfoPopup.vue' |
|
|
import jobTop from '@/mycomponents/job/jobTop.vue' |
|
|
import jobTop from '@/mycomponents/job/jobTop.vue' |
|
@ -85,7 +91,7 @@ |
|
|
winScanButton, |
|
|
winScanButton, |
|
|
requiredLocation, |
|
|
requiredLocation, |
|
|
comMessage, |
|
|
comMessage, |
|
|
winScanPackAndLocation, |
|
|
winScanPack, |
|
|
comDetailCard, |
|
|
comDetailCard, |
|
|
detailInfoPopup, |
|
|
detailInfoPopup, |
|
|
jobTop |
|
|
jobTop |
|
@ -101,7 +107,7 @@ |
|
|
toLocationCode: "", |
|
|
toLocationCode: "", |
|
|
businessTypeInfo: {}, |
|
|
businessTypeInfo: {}, |
|
|
managementList: [], |
|
|
managementList: [], |
|
|
tolocationTypeList:[] |
|
|
tolocationTypeList: [] |
|
|
}; |
|
|
}; |
|
|
}, |
|
|
}, |
|
|
onLoad(option) { |
|
|
onLoad(option) { |
|
@ -227,29 +233,45 @@ |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
openScanPopup() { |
|
|
openScanPopup() { |
|
|
let fromlocationCode = ''; |
|
|
this.$refs.scanPopup.openScanPopup(); |
|
|
let fromlocationList = []; |
|
|
}, |
|
|
for (var i = 0; i < this.detailSource.length; i++) { |
|
|
|
|
|
let item = this.detailSource[i]; |
|
|
getScanResult(result) { |
|
|
item.subList.forEach(l => { |
|
|
try { |
|
|
//重复的库位不往里面插入 |
|
|
var packingNumber = result.label.packingNumber; |
|
|
var location = fromlocationList.filter(res => res.fromLocationCode != l.fromLocationCode) |
|
|
var batch = result.label.batch; |
|
|
if (location.length == 0) { |
|
|
var qty = result.label.qty; |
|
|
fromlocationList.push(l.fromLocationCode); |
|
|
var itemCode = result.label.itemCode; |
|
|
} |
|
|
var detail = this.detailSource.find(r => r.itemCode == itemCode); |
|
|
//来源库位赋默认值 |
|
|
if (detail == undefined) { |
|
|
if (fromlocationCode == '') { |
|
|
this.showMessage("物料号【" + itemCode + "】不在列表中") |
|
|
if (!l.scaned) { |
|
|
} else { |
|
|
fromlocationCode = l.fromLocationCode; |
|
|
var itemDetail = detail.subList.find(r => r.packingNumber == packingNumber && r.batch == batch); |
|
|
|
|
|
if (itemDetail == undefined) { |
|
|
|
|
|
this.showMessage("箱码【" + packingNumber + "】、批次【" + batch + "】不在列表中") |
|
|
|
|
|
} else { |
|
|
|
|
|
if (itemDetail.scaned) { |
|
|
|
|
|
this.showMessage("箱码【" + packingNumber + "】已经扫描") |
|
|
|
|
|
} else { |
|
|
|
|
|
itemDetail.scaned = true; |
|
|
|
|
|
this.detailSource[0].subList.sort(compareAsc('scaned')); //按扫描信息排序 |
|
|
|
|
|
itemDetail.handleQty = Number(result.label.qty); |
|
|
|
|
|
itemDetail.toLocationCode = this.toLocationCode; |
|
|
|
|
|
itemDetail.labelQty = Number(result.label.qty); |
|
|
|
|
|
calcHandleQty(this.detailSource); |
|
|
|
|
|
this.continueScan() |
|
|
|
|
|
this.$forceUpdate() |
|
|
|
|
|
var list = this.detailSource[0].subList; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}) |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} catch (e) { |
|
|
|
|
|
this.showErrorMessage(e.message) |
|
|
} |
|
|
} |
|
|
this.$refs.scanPopup.openScanPopupForJob(fromlocationCode, fromlocationList, this.jobContent); |
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
getScanResult1(result) { |
|
|
getScanResult(result) { |
|
|
|
|
|
try { |
|
|
try { |
|
|
var packingNumber = result.label.packingNumber; |
|
|
var packingNumber = result.label.packingNumber; |
|
|
var batch = result.label.batch; |
|
|
var batch = result.label.batch; |
|
@ -272,15 +294,16 @@ |
|
|
let balanceStatus = getInventoryStatusName(result.balance.inventoryStatus); |
|
|
let balanceStatus = getInventoryStatusName(result.balance.inventoryStatus); |
|
|
let itemStatus = getInventoryStatusName(itemDetail.inventoryStatus); |
|
|
let itemStatus = getInventoryStatusName(itemDetail.inventoryStatus); |
|
|
if (itemDetail.inventoryStatus != result.balance.inventoryStatus) { |
|
|
if (itemDetail.inventoryStatus != result.balance.inventoryStatus) { |
|
|
if(this.jobContent.allowModifyInventoryStatus=="TRUE"){ |
|
|
if (this.jobContent.allowModifyInventoryStatus == "TRUE") { |
|
|
this.showQuestionMessage('任务中允许修改库存状态,实际库存状态[' + balanceStatus + ']与推荐库存状态[' + itemStatus + |
|
|
this.showQuestionMessage('任务中允许修改库存状态,实际库存状态[' + balanceStatus + ']与推荐库存状态[' + |
|
|
|
|
|
itemStatus + |
|
|
']不一致,是否继续入库?', res => { |
|
|
']不一致,是否继续入库?', res => { |
|
|
if (res) { |
|
|
if (res) { |
|
|
itemDetail.scaned = true; |
|
|
itemDetail.scaned = true; |
|
|
itemDetail.handleQty = Number(result.balance.qty) ; |
|
|
itemDetail.handleQty = Number(result.balance.qty); |
|
|
itemDetail.toInventoryStatus = result.balance.inventoryStatus |
|
|
itemDetail.toInventoryStatus = result.balance.inventoryStatus |
|
|
itemDetail.balance = result.balance; |
|
|
itemDetail.balance = result.balance; |
|
|
itemDetail.balance.balanceQty = Number(result.balance.qty) ; |
|
|
itemDetail.balance.balanceQty = Number(result.balance.qty); |
|
|
itemDetail.balance.stdPackQty = Number(result.package.stdPackQty) |
|
|
itemDetail.balance.stdPackQty = Number(result.package.stdPackQty) |
|
|
itemDetail.balance.stdPackUnit = result.package.stdPackUnit |
|
|
itemDetail.balance.stdPackUnit = result.package.stdPackUnit |
|
|
this.calcHandleQty(); |
|
|
this.calcHandleQty(); |
|
@ -288,8 +311,9 @@ |
|
|
this.scanPopupGetFocus(); |
|
|
this.scanPopupGetFocus(); |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
}else { |
|
|
} else { |
|
|
this.showQuestionMessage('任务中不允许修改库存状态,实际库存状态[' + balanceStatus + ']与推荐库存状态[' + itemStatus + |
|
|
this.showQuestionMessage('任务中不允许修改库存状态,实际库存状态[' + balanceStatus + ']与推荐库存状态[' + |
|
|
|
|
|
itemStatus + |
|
|
']不一致,不允许转移!', res => { |
|
|
']不一致,不允许转移!', res => { |
|
|
this.scanPopupGetFocus(); |
|
|
this.scanPopupGetFocus(); |
|
|
}); |
|
|
}); |
|
@ -298,10 +322,10 @@ |
|
|
|
|
|
|
|
|
} else { |
|
|
} else { |
|
|
itemDetail.scaned = true; |
|
|
itemDetail.scaned = true; |
|
|
itemDetail.handleQty = Number(result.balance.qty) ; |
|
|
itemDetail.handleQty = Number(result.balance.qty); |
|
|
itemDetail.toInventoryStatus = result.balance.inventoryStatus |
|
|
itemDetail.toInventoryStatus = result.balance.inventoryStatus |
|
|
itemDetail.balance = result.balance; |
|
|
itemDetail.balance = result.balance; |
|
|
itemDetail.balance.balanceQty = Number(result.balance.qty) ; |
|
|
itemDetail.balance.balanceQty = Number(result.balance.qty); |
|
|
itemDetail.balance.stdPackQty = Number(result.package.stdPackQty) |
|
|
itemDetail.balance.stdPackQty = Number(result.package.stdPackQty) |
|
|
itemDetail.balance.stdPackUnit = result.package.stdPackUnit |
|
|
itemDetail.balance.stdPackUnit = result.package.stdPackUnit |
|
|
this.calcHandleQty(); |
|
|
this.calcHandleQty(); |
|
|