|
|
@ -82,18 +82,18 @@ |
|
|
|
}, |
|
|
|
|
|
|
|
props: { |
|
|
|
operation: "receipt" ,//reject 收货 拒绝 |
|
|
|
isShowAsn:{ |
|
|
|
type: Boolean, |
|
|
|
default: true |
|
|
|
}, |
|
|
|
isShowJob:{ |
|
|
|
type: Boolean, |
|
|
|
default: true |
|
|
|
}, |
|
|
|
scanTitle:{ |
|
|
|
type: String, |
|
|
|
default: '箱标签' |
|
|
|
operation: "receipt", //reject 收货 拒绝 |
|
|
|
isShowAsn: { |
|
|
|
type: Boolean, |
|
|
|
default: true |
|
|
|
}, |
|
|
|
isShowJob: { |
|
|
|
type: Boolean, |
|
|
|
default: true |
|
|
|
}, |
|
|
|
scanTitle: { |
|
|
|
type: String, |
|
|
|
default: '箱标签' |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
@ -136,10 +136,17 @@ |
|
|
|
this.detailOptions = getDetailOption(); |
|
|
|
this.detailGiveupOptions = getDetailGiveupOption(); |
|
|
|
this.refresh(); |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
methods: { |
|
|
|
onReach() { |
|
|
|
//避免多次触发 |
|
|
|
if (this.loadingType == 'loading' || this.loadingType == 'nomore') { |
|
|
|
return; |
|
|
|
} |
|
|
|
this.getList("more"); |
|
|
|
}, |
|
|
|
refresh() { |
|
|
|
this.getList('refresh'); |
|
|
|
}, |
|
|
@ -341,65 +348,65 @@ |
|
|
|
this.$refs.scanPopup.closeScanPopup(); |
|
|
|
this.openJobDetail(item, item.packingNumber); |
|
|
|
}, |
|
|
|
getScanResult(result) { |
|
|
|
|
|
|
|
getScanResult(result) { |
|
|
|
|
|
|
|
try { |
|
|
|
let filters = [] |
|
|
|
if(result.label.barType=="BarCode"){ |
|
|
|
// ASN单号 |
|
|
|
filters = [{ |
|
|
|
column: "asn_number", |
|
|
|
action: "==", |
|
|
|
value: result.label.code |
|
|
|
}] |
|
|
|
}else{ |
|
|
|
filters = [{ |
|
|
|
column: "packingNumber", |
|
|
|
action: "==", |
|
|
|
value: result.label.packingNumber |
|
|
|
}, |
|
|
|
{ |
|
|
|
column: "batch", |
|
|
|
action: "==", |
|
|
|
value: result.label.batch |
|
|
|
}, |
|
|
|
// { |
|
|
|
// column: "qty", |
|
|
|
// action: "==", |
|
|
|
// value: result.label.qty |
|
|
|
// }, |
|
|
|
{ |
|
|
|
column: "itemCode", |
|
|
|
action: "==", |
|
|
|
value: result.label.itemCode |
|
|
|
}, |
|
|
|
// { |
|
|
|
// column: "fromLocationCode", |
|
|
|
// action: "==", |
|
|
|
// value: result.label.fromLocationCode |
|
|
|
// } |
|
|
|
] |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
let filters = [] |
|
|
|
if (result.label.barType == "BarCode") { |
|
|
|
// ASN单号 |
|
|
|
filters = [{ |
|
|
|
column: "asn_number", |
|
|
|
action: "==", |
|
|
|
value: result.label.code |
|
|
|
}] |
|
|
|
} else { |
|
|
|
filters = [{ |
|
|
|
column: "packingNumber", |
|
|
|
action: "==", |
|
|
|
value: result.label.packingNumber |
|
|
|
}, |
|
|
|
{ |
|
|
|
column: "batch", |
|
|
|
action: "==", |
|
|
|
value: result.label.batch |
|
|
|
}, |
|
|
|
// { |
|
|
|
// column: "qty", |
|
|
|
// action: "==", |
|
|
|
// value: result.label.qty |
|
|
|
// }, |
|
|
|
{ |
|
|
|
column: "itemCode", |
|
|
|
action: "==", |
|
|
|
value: result.label.itemCode |
|
|
|
}, |
|
|
|
// { |
|
|
|
// column: "fromLocationCode", |
|
|
|
// action: "==", |
|
|
|
// value: result.label.fromLocationCode |
|
|
|
// } |
|
|
|
] |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
getPurchaseReceiptJobList({ |
|
|
|
filters: filters, |
|
|
|
pageNo: 1, |
|
|
|
pageSize: 100, |
|
|
|
}).then(res => { |
|
|
|
let resultList = res.data.list; |
|
|
|
if (resultList.length > 0) { |
|
|
|
resultList.forEach(item => { |
|
|
|
item.title = item.number; |
|
|
|
item.selected = false |
|
|
|
}) |
|
|
|
let list = [] |
|
|
|
resultList.forEach(item=>{ |
|
|
|
if(!list.find(subItem=>subItem.title==item.title)){ |
|
|
|
list.push(item) |
|
|
|
} |
|
|
|
}) |
|
|
|
|
|
|
|
if (resultList.length > 0) { |
|
|
|
resultList.forEach(item => { |
|
|
|
item.title = item.number; |
|
|
|
item.selected = false |
|
|
|
}) |
|
|
|
let list = [] |
|
|
|
resultList.forEach(item => { |
|
|
|
if (!list.find(subItem => subItem.title == item.title)) { |
|
|
|
list.push(item) |
|
|
|
} |
|
|
|
}) |
|
|
|
|
|
|
|
console.log('list', list) |
|
|
|
if (list.length > 1) { |
|
|
|
this.$refs.jobList.openList(list) |
|
|
|