|
|
|
@ -2,7 +2,7 @@ |
|
|
|
<div class="pda-container"> |
|
|
|
<!-- 头部栏 --> |
|
|
|
<div class="header-bar"> |
|
|
|
<div class="header-left" @click="$router.back()"> |
|
|
|
<div class="header-left" @click="$router.push({name:'outsourcingDirectIssue'})"> |
|
|
|
<i class="el-icon-arrow-left"></i> |
|
|
|
<span>委外直接发料</span> |
|
|
|
</div> |
|
|
|
@ -192,12 +192,12 @@ export default { |
|
|
|
}) |
|
|
|
.then(() => { |
|
|
|
this.scannedLabels = [] |
|
|
|
this.$router.back() |
|
|
|
this.$router.push({name:'outsourcingDirectIssue'}) |
|
|
|
this.$message.success('已清空') |
|
|
|
}) |
|
|
|
.catch(() => {}) |
|
|
|
} else { |
|
|
|
this.$router.back() |
|
|
|
this.$router.push({name:'outsourcingDirectIssue'}) |
|
|
|
} |
|
|
|
}, |
|
|
|
confirmIssue() { |
|
|
|
@ -229,7 +229,7 @@ export default { |
|
|
|
.then(({ data }) => { |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.$message.success('委外发料成功') |
|
|
|
this.$router.back() |
|
|
|
this.$router.push({name:'outsourcingDirectIssue'}) |
|
|
|
} else { |
|
|
|
this.$message.error(data.msg || '委外发料失败') |
|
|
|
} |
|
|
|
@ -241,15 +241,15 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
initFromRoute() { |
|
|
|
this.outsourcingNo = this.$route.params.outsourcingNo |
|
|
|
this.partNo = this.$route.params.partNo |
|
|
|
this.outsourcingNo = this.$route.query.outsourcingNo |
|
|
|
this.partNo = this.$route.query.partNo |
|
|
|
|
|
|
|
// 如果存在发料记录信息,从中获取详细信息 |
|
|
|
const issueRecord = this.$route.params.issueRecord |
|
|
|
const issueRecord = this.$route.query.issueRecord |
|
|
|
if (issueRecord) { |
|
|
|
this.componentPartNo = issueRecord.componentPartNo |
|
|
|
this.componentPartDesc = issueRecord.componentPartDescription || '' |
|
|
|
this.requiredQty = Number(issueRecord.requiredQty || this.$route.params.requiredQty || 0) |
|
|
|
this.requiredQty = Number(issueRecord.requiredQty || this.$route.query.requiredQty || 0) |
|
|
|
this.issuedQty = Number(issueRecord.issuedQty || 0) |
|
|
|
this.releaseNo = issueRecord.releaseNo |
|
|
|
this.lineNo = issueRecord.lineNo |
|
|
|
@ -257,12 +257,12 @@ export default { |
|
|
|
} else { |
|
|
|
// 兼容旧的参数结构 |
|
|
|
this.componentPartNo = issueRecord.componentPartNo |
|
|
|
this.componentPartDesc = this.$route.params.componentPartDescription || '' |
|
|
|
this.requiredQty = Number(this.$route.params.requiredQty || 0) |
|
|
|
this.issuedQty = Number(this.$route.params.issuedQty || 0) |
|
|
|
this.releaseNo = this.$route.params.releaseNo |
|
|
|
this.lineNo = this.$route.params.lineNo |
|
|
|
this.itemNo = this.$route.params.lineItemNo |
|
|
|
this.componentPartDesc = this.$route.query.componentPartDescription || '' |
|
|
|
this.requiredQty = Number(this.$route.query.requiredQty || 0) |
|
|
|
this.issuedQty = Number(this.$route.query.issuedQty || 0) |
|
|
|
this.releaseNo = this.$route.query.releaseNo |
|
|
|
this.lineNo = this.$route.query.lineNo |
|
|
|
this.itemNo = this.$route.query.lineItemNo |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
|