|
|
|
@ -172,6 +172,18 @@ |
|
|
|
</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<!-- 操作列 --> |
|
|
|
<el-table-column |
|
|
|
fixed="right" |
|
|
|
header-align="center" |
|
|
|
align="center" |
|
|
|
width="120" |
|
|
|
label="操作"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<a type="text" size="small" v-if="scope.row.pushWmsFlag !== 'Y' && currentRow && currentRow.pushWcsFlag === '未推送'" @click="enterSOSDetail(scope.row)" style="margin-right: 10px;">修改</a> |
|
|
|
<a type="text" size="small" v-if="scope.row.pushWmsFlag !== 'Y' && currentRow && currentRow.pushWcsFlag === '未推送'" @click="deleteNotifySOSPlus(scope.row)">删除</a> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
|
|
|
|
</el-tab-pane> |
|
|
|
@ -273,6 +285,76 @@ |
|
|
|
</el-footer> |
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
<!-- 物料明细对话框 --> |
|
|
|
<el-dialog title="申请明细" :close-on-click-modal="false" v-drag :visible.sync="materialModalFlag" width="900px"> |
|
|
|
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;"> |
|
|
|
<el-row :gutter="20"> |
|
|
|
<el-col :span="6"> |
|
|
|
<el-form-item :label="'生产订单号'"> |
|
|
|
<el-input v-model="sobomData.orderNo" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="6"> |
|
|
|
<el-form-item :label="'产品编码'"> |
|
|
|
<el-input v-model="sobomData.partNo" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
</el-form> |
|
|
|
<div class="yzzTable"> |
|
|
|
<el-table :height="400" :data="sobomList" border v-loading="bomLoadFlag" style="width: 100%;"> |
|
|
|
<el-table-column |
|
|
|
prop="componentPartNo" |
|
|
|
label="物料编码" |
|
|
|
sortable |
|
|
|
width="120" |
|
|
|
align="left"> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="componentPartDesc" |
|
|
|
label="物料描述" |
|
|
|
width="200" |
|
|
|
align="left" |
|
|
|
show-overflow-tooltip> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="qtyRequired" |
|
|
|
label="需求数量" |
|
|
|
width="100" |
|
|
|
align="right"> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="qtyToIssue" |
|
|
|
label="本次申请数量" |
|
|
|
width="120" |
|
|
|
align="right"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-input v-model="scope.row.qtyToIssue" type="number" style="height: 11px; width: 98%;" :step="0" |
|
|
|
:min="0"></el-input> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="remark" |
|
|
|
label="备注" |
|
|
|
width="200" |
|
|
|
align="left"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-input v-model="scope.row.remark" style="padding: 0;width: 100%"></el-input> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="" header-align="center" align="center" min-width="80" label="操作"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button type="primary" @click="qtyAllForBom(scope.row)" style="width: 100%">全数领料</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</div> |
|
|
|
<el-footer style="height:40px;margin-top: 10px;text-align:center"> |
|
|
|
<el-button type="primary" @click="saveMaterialDetail()">保存</el-button> |
|
|
|
<el-button type="primary" @click="materialModalFlag=false">关闭</el-button> |
|
|
|
</el-footer> |
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
<!-- 库存预览模态框 --> |
|
|
|
<el-dialog |
|
|
|
title="库存匹配预览" |
|
|
|
@ -378,6 +460,8 @@ |
|
|
|
, pushInventoryToWcs |
|
|
|
, checkUserHasUnissueShopOrder |
|
|
|
, cancelIssueNotify |
|
|
|
, getSOSBOMForIssureNew |
|
|
|
, saveMaterialDetail |
|
|
|
|
|
|
|
} from "@/api/orderIssure/soIssueNotify.js" |
|
|
|
|
|
|
|
@ -1042,6 +1126,15 @@ |
|
|
|
previewDialogVisible: false, |
|
|
|
previewLoading: false, |
|
|
|
previewData: [], |
|
|
|
// 物料明细对话框相关数据 |
|
|
|
materialModalFlag: false, |
|
|
|
sobomList: [], |
|
|
|
sobomData: { |
|
|
|
orderNo: '', |
|
|
|
seqNo: '', |
|
|
|
partNo: '', |
|
|
|
}, |
|
|
|
bomLoadFlag: false, |
|
|
|
} |
|
|
|
}, |
|
|
|
mounted () { |
|
|
|
@ -1442,6 +1535,92 @@ |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
// 进入工单物料明细 |
|
|
|
enterSOSDetail(row) { |
|
|
|
let rows = { |
|
|
|
site: this.currentRow.site || this.$store.state.user.site, |
|
|
|
notifyNo: this.currentRow.notifyNo, |
|
|
|
orderNo: row.soorderNo || row.orderNo, |
|
|
|
seqNo: row.seqNo || '', |
|
|
|
partNo: row.fgPartNo || row.partNo, |
|
|
|
itemNo: row.itemNo, |
|
|
|
releaseNo: row.releaseNo, |
|
|
|
sequenceNo: row.sequenceNo, |
|
|
|
} |
|
|
|
this.enterSOS(rows) |
|
|
|
}, |
|
|
|
// 打开物料明细对话框 |
|
|
|
enterSOS(row) { |
|
|
|
this.materialModalFlag = true |
|
|
|
this.sobomList = [] |
|
|
|
this.sobomData = { |
|
|
|
orderNo: row.orderNo, |
|
|
|
seqNo: row.seqNo, |
|
|
|
partNo: row.partNo, |
|
|
|
} |
|
|
|
this.bomLoadFlag = true |
|
|
|
let inData = { |
|
|
|
site: this.currentRow.site || this.$store.state.user.site, |
|
|
|
notifyNo: this.currentRow.notifyNo, |
|
|
|
orderNo: row.orderNo, |
|
|
|
releaseNo: row.releaseNo, |
|
|
|
sequenceNo: row.sequenceNo, |
|
|
|
partNo: row.partNo, |
|
|
|
itemNo: row.itemNo, |
|
|
|
} |
|
|
|
getSOSBOMForIssureNew(inData).then(({ data }) => { |
|
|
|
this.bomLoadFlag = false |
|
|
|
if (data.code === 0) { |
|
|
|
this.sobomList = data.rows |
|
|
|
for (let i = 0; i < this.sobomList.length; i++) { |
|
|
|
this.sobomList[i].itemNo = inData.itemNo |
|
|
|
} |
|
|
|
} else { |
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
confirmButtonText: '确定' |
|
|
|
}) |
|
|
|
} |
|
|
|
}).catch(() => { |
|
|
|
this.bomLoadFlag = false |
|
|
|
this.$message.error('获取物料明细失败') |
|
|
|
}) |
|
|
|
}, |
|
|
|
// 全数领料 |
|
|
|
qtyAllForBom(row) { |
|
|
|
row.qtyToIssue = row.qtyRequired |
|
|
|
}, |
|
|
|
// 保存物料明细 |
|
|
|
saveMaterialDetail() { |
|
|
|
for (let i = 0; i < this.sobomList.length; i++) { |
|
|
|
if ( |
|
|
|
this.sobomList[i].qtyToIssue === '' || |
|
|
|
this.sobomList[i].qtyToIssue == null |
|
|
|
) { |
|
|
|
this.sobomList[i].qtyToIssue = 0 |
|
|
|
} |
|
|
|
this.sobomList[i].notifyNo = this.currentRow.notifyNo |
|
|
|
this.sobomList[i].site = this.currentRow.site || this.$store.state.user.site |
|
|
|
} |
|
|
|
|
|
|
|
let materialList = this.sobomList.filter((item) => item.qtyToIssue > 0) |
|
|
|
if (materialList.length == 0) { |
|
|
|
this.$alert('没有需要保存的内容!', '提示', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
}) |
|
|
|
return false |
|
|
|
} |
|
|
|
saveMaterialDetail(materialList).then(({ data }) => { |
|
|
|
if (data.code === 0) { |
|
|
|
this.materialModalFlag = false |
|
|
|
this.refreshCurrentTabTable() |
|
|
|
this.$message.success('操作成功') |
|
|
|
} else { |
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -1513,6 +1692,12 @@ |
|
|
|
text-align: right !important; |
|
|
|
} |
|
|
|
|
|
|
|
.yzzTable /deep/.el-table .cell { |
|
|
|
line-height: 20px; |
|
|
|
font-size: 12px; |
|
|
|
height: 20px; |
|
|
|
} |
|
|
|
|
|
|
|
.single-line-multi-select >>> .el-select__tags { |
|
|
|
display: flex; |
|
|
|
flex-wrap: nowrap; |
|
|
|
|