Browse Source

修改发料添加供应商代码

intex
lijuncheng 5 days ago
parent
commit
e0668bc2f0
  1. 29
      src/pages/issue/job/issueDetailBatch.vue
  2. 6
      src/pages/issue/record/directIssueByBatch.vue

29
src/pages/issue/job/issueDetailBatch.vue

@ -8,17 +8,16 @@
<work-station :workshopCode="jobContent.workShopCode"
:productionLineCode="jobContent.detailProductionLineCode"
:workStationCode="jobContent.detailWorkStationCode"
:rawLocationCode="jobContent.detailToLocationCode"
:itemGroup="jobContent.itemGroup" :isShowItemGroup='true'>
:rawLocationCode="jobContent.detailToLocationCode" :itemGroup="jobContent.itemGroup"
:isShowItemGroup='true'>
</work-station>
</view>
</view>
<view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll">
<view v-for="(toLocation, index) in detailSource">
<comIssueDetailCardBatch ref='comIssueDetailCardBatch' :dataContent="toLocation" :settingParam="jobContent"
@updateData='updateData'
>
<comIssueDetailCardBatch ref='comIssueDetailCardBatch' :dataContent="toLocation"
:settingParam="jobContent" @updateData='updateData'>
</comIssueDetailCardBatch>
<view class="split_line"></view>
</view>
@ -41,8 +40,8 @@
@afterScan='afterScan' :locationCode='fromLocationCode'>
</com-scan-issue-pack> -->
<winScanPackAndLocation :balanceFromInventoryStatuses="true" ref="scanPopup"
@getResult='getScanResult' :noShowBalanceMessage="false" @confirm='confirmFromLocation'>
<winScanPackAndLocation :balanceFromInventoryStatuses="true" ref="scanPopup" @getResult='getScanResult'
:noShowBalanceMessage="false" @confirm='confirmFromLocation'>
</winScanPackAndLocation>
<balance-select ref="balanceSelect"></balance-select>
<comMessage ref="comMessage"></comMessage>
@ -529,6 +528,7 @@
packUnit: result.package.packUnit,
uom: result.balance.uom,
isRecommTaskItem: false, //
supplierCode: result.label.supplierCode
}
detail.subList.push(item)
//
@ -605,7 +605,6 @@
return
}
console.log("提交参数", params);
issueJobSubmit(params).then(res => {
uni.hideLoading()
if (res.data) {
@ -626,7 +625,10 @@
let arr = []
toLocationCode.subList.forEach(record => {
if (record.scaned) {
let obj = {...toLocationCode,...record}
let obj = {
...toLocationCode,
...record
}
obj.recordList = []
delete obj.balance
delete obj.subList
@ -651,7 +653,8 @@
obj1.toPackingNumber = "";
obj1.packingNumber = "";
let single_price = record.balance.singlePrice == null ? 0 : record.balance.singlePrice;
let single_price = record.balance.singlePrice == null ? 0 : record.balance
.singlePrice;
obj1.singlePrice = single_price;
obj1.amount = single_price * record.qty;
@ -796,7 +799,8 @@
detail.subList.forEach(item => {
if (item.scaned) {
if (parseFloat(item.handleQty) > parseFloat(item.balance.qty)) {
str2 += `物料号【${detail.itemCode}】批次【${item.batch}】提交数量【${parseFloat(item.handleQty)}】不可以大于库存数量【${item.balance.qty}\n`
str2 +=
`物料号【${detail.itemCode}】批次【${item.batch}】提交数量【${parseFloat(item.handleQty)}】不可以大于库存数量【${item.balance.qty}\n`
}
}
if (item.isRecommTaskItem) { //
@ -806,7 +810,8 @@
str3 = '推荐的箱码没扫,'
}
if (parseFloat(item.handleQty) != parseFloat(item.qty)) {
str3 += `物料号【${detail.itemCode}】批次【${item.batch}】扫描数量【${parseFloat(item.handleQty)}】和任务数量【${item.qty}】不一致\n`
str3 +=
`物料号【${detail.itemCode}】批次【${item.batch}】扫描数量【${parseFloat(item.handleQty)}】和任务数量【${item.qty}】不一致\n`
}
}

6
src/pages/issue/record/directIssueByBatch.vue

@ -245,6 +245,7 @@
let newDetail = createDetailInfo(balance, pack); //
newDetail.packingNumber = pack.number
newDetail.handleQty =label.qty
newDetail.supplierCode =label.supplierCode
itemp.subList.push(newDetail);
this.detailSource.push(itemp)
} else {
@ -260,6 +261,7 @@
let newDetail = createDetailInfo(balance, pack);
newDetail.packingNumber = pack.number
newDetail.handleQty =label.qty
newDetail.supplierCode =label.supplierCode
item.subList.push(newDetail);
} else {
detail.handleQty=calc.add(detail.handleQty,result.label.qty)
@ -455,7 +457,6 @@
var params = {
...this.setRecordParams()
}
console.log("提交参数", JSON.stringify(params));
const isHaveItem = params.subList.find(item => item.handleQty > item.balanceQty)
if (isHaveItem) {
this.showErrorMessage(`物料号${isHaveItem.itemCode}`)
@ -520,7 +521,8 @@
fromPackUnit: detail.packUnit,
toPackUnit: detail.packUnit,
fromPackQty: detail.packQty,
toPackQty: detail.packQty
toPackQty: detail.packQty,
supplierCode:detail.supplierCode
}]
subList.push(submitItem)
}

Loading…
Cancel
Save