|
|
|
@ -200,8 +200,8 @@ |
|
|
|
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;"> |
|
|
|
<el-row :gutter="20"> |
|
|
|
<el-col :span="4"> |
|
|
|
<el-form-item :label="'生产订单'"> |
|
|
|
<el-input v-model="seqNoData.orderno"></el-input> |
|
|
|
<el-form-item :label="'生产订单号'"> |
|
|
|
<el-input v-model="seqNoData.orderNo"></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<!-- <el-col :span="4"> |
|
|
|
@ -209,13 +209,13 @@ |
|
|
|
<el-input v-model="seqNoData.seqno"></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> --> |
|
|
|
<el-col :span="4"> |
|
|
|
<!-- <el-col :span="4"> |
|
|
|
<el-form-item> |
|
|
|
<span slot="label" style="" @click="getBaseList(515)"><a herf="#">机台</a></span> |
|
|
|
|
|
|
|
<el-input v-model="seqNoData.sResourceid"></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-col> --> |
|
|
|
<el-col :span="4"> |
|
|
|
<el-form-item> |
|
|
|
<span slot="label" style="" @click="getBaseList(216)"><a herf="#">加工中心</a></span> |
|
|
|
@ -223,7 +223,7 @@ |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="4"> |
|
|
|
<el-form-item :label="'派工日期'"> |
|
|
|
<el-form-item :label="'日期'"> |
|
|
|
<el-date-picker style="width: 100%" v-model="seqNoData.startDate" type="date" value-format="yyyy-MM-dd" |
|
|
|
placeholder="选择日期"> |
|
|
|
</el-date-picker> |
|
|
|
@ -246,7 +246,7 @@ |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
</el-form> |
|
|
|
<el-table :height="400" :data="seqNoList" border style="width: 100%;"> |
|
|
|
<el-table :height="400" :data="seqNoList" border style="width: 100%;" class="choose-sos-table"> |
|
|
|
<el-table-column v-for="(item,index) in columnList2" :key="index" :sortable="item.columnSortable" |
|
|
|
:prop="item.columnProp" :header-align="item.headerAlign" :show-overflow-tooltip="item.showOverflowTooltip" |
|
|
|
:align="item.align" :fixed="item.fixed==''?false:item.fixed" :min-width="item.columnWidth" |
|
|
|
@ -257,9 +257,9 @@ |
|
|
|
style="width: 100px; height: 80px" /></span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column fixed="left" header-align="center" align="center" width="60" label="操作"> |
|
|
|
<el-table-column fixed="left" header-align="center" align="center" width="80" label="操作"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<a type="text" size="small" @click="chooseSOS(scope.row)">选择</a> |
|
|
|
<el-button type="primary" size="mini" plain class="choose-sos-btn" :loading="chooseLoading" @click="chooseSOS(scope.row)">选择</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
@ -271,7 +271,7 @@ |
|
|
|
<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-form-item :label="'生产订单号'"> |
|
|
|
<el-input v-model="notifyOrderData.orderNo" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
@ -280,11 +280,11 @@ |
|
|
|
<el-input v-model="notifyOrderData.seqno" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> --> |
|
|
|
<el-col :span="6"> |
|
|
|
<!-- <el-col :span="6"> |
|
|
|
<el-form-item :label="'机台'"> |
|
|
|
<el-input v-model="notifyOrderData.sResourceID" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-col> --> |
|
|
|
<el-col :span="6"> |
|
|
|
<el-form-item :label="'工单数量'"> |
|
|
|
<el-input v-model="notifyOrderData.qtyRequired" disabled></el-input> |
|
|
|
@ -311,20 +311,21 @@ |
|
|
|
</el-date-picker> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="6"> |
|
|
|
<!-- <el-col :span="6"> |
|
|
|
<el-form-item label="机台"> |
|
|
|
<el-input v-model="notifyOrderData.locationNo" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-col> --> |
|
|
|
<el-col :span="6"> |
|
|
|
<el-form-item :label="'此次领料数量'"> |
|
|
|
<el-input-number v-model="notifyOrderData.issureQty" style="padding: 0px;width: 100%" :controls="false" |
|
|
|
:step="0" :min="0" class="text-right"></el-input-number> |
|
|
|
<!-- <el-input-number v-model="notifyOrderData.issureQty" style="padding: 0px;width: 100%" :controls="false" |
|
|
|
:step="0" :min="0" class="text-right"></el-input-number> --> |
|
|
|
<el-input v-model="notifyOrderData.issureQty" @input=" value=>notifyOrderData.issureQty = value.match(/0$|^[1-9]\d*/) ? value.match(/0$|^[1-9]\d*/)[0] : ''"></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="6"> |
|
|
|
<el-form-item :label="' '"> |
|
|
|
<el-button type="primary" @click="qtyAllForSeqNo()" style="margin-top: 4%;">全数领料</el-button> |
|
|
|
<el-button type="primary" @click="qtyAllForSeqNo()">全数领料</el-button> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
@ -366,7 +367,7 @@ |
|
|
|
<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-form-item :label="'生产订单号'"> |
|
|
|
<el-input v-model="sobomData.orderno" disabled></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
@ -606,7 +607,9 @@ import { |
|
|
|
saveSOIssueNotifyOrderList, |
|
|
|
getSOSBOMForIssure, |
|
|
|
saveMaterialDetail, |
|
|
|
deleteNotifySOS |
|
|
|
deleteNotifySOS, |
|
|
|
getIFSShopOrderByOrderNo, |
|
|
|
searchNotifyMaterialList, |
|
|
|
} from '@/api/orderIssure/soIssueNotify.js' |
|
|
|
import Chooselist from '@/views/modules/common/Chooselist_eam' |
|
|
|
import walUploadExcel from './walmart_upload_excel.vue' |
|
|
|
@ -678,22 +681,20 @@ export default { |
|
|
|
itemNo: '', |
|
|
|
notifyOrderData: { |
|
|
|
partNo: '', |
|
|
|
orderno: '', |
|
|
|
itemno: '', |
|
|
|
seqno: '', |
|
|
|
orderNo: '', |
|
|
|
itemNo: '', |
|
|
|
seqNo: '', |
|
|
|
partDesc: '', |
|
|
|
qtyrequired: '', |
|
|
|
sResourceid: '', |
|
|
|
sResourceID: '', |
|
|
|
issureQty: '', |
|
|
|
locationNo: '', |
|
|
|
needDate: '', |
|
|
|
}, |
|
|
|
seqNoData: { |
|
|
|
site: this.$store.state.user.site, |
|
|
|
bu: '', |
|
|
|
orderno: '', |
|
|
|
seqno: '', |
|
|
|
sResourceid: '', |
|
|
|
sResourceID: '', |
|
|
|
sWorkcenterno: '', |
|
|
|
operatorId: '', |
|
|
|
sShiftno: '', |
|
|
|
@ -805,7 +806,7 @@ export default { |
|
|
|
functionId: 701001, |
|
|
|
serialNumber: '701001Table1ItemNo', |
|
|
|
tableId: '701001Table1', |
|
|
|
tableName: '领料申请派工单子表', |
|
|
|
tableName: '领料申请工单子表', |
|
|
|
columnProp: 'itemNo', |
|
|
|
headerAlign: 'center', |
|
|
|
align: 'right', |
|
|
|
@ -841,11 +842,11 @@ export default { |
|
|
|
functionId: 701001, |
|
|
|
serialNumber: '701001Table1SOOrderNo', |
|
|
|
tableId: '701001Table1', |
|
|
|
tableName: '领料申请派工单子表', |
|
|
|
columnProp: 'sOOrderNo', |
|
|
|
tableName: '领料申请工单子表', |
|
|
|
columnProp: 'soorderNo', |
|
|
|
headerAlign: 'center', |
|
|
|
align: 'center', |
|
|
|
columnLabel: '生产订单', |
|
|
|
columnLabel: '生产订单号', |
|
|
|
columnHidden: false, |
|
|
|
columnImage: false, |
|
|
|
columnSortable: false, |
|
|
|
@ -859,7 +860,7 @@ export default { |
|
|
|
functionId: 701001, |
|
|
|
serialNumber: '701001Table1OpsItemNo', |
|
|
|
tableId: '701001Table1', |
|
|
|
tableName: '领料申请派工单子表', |
|
|
|
tableName: '领料申请工单子表', |
|
|
|
columnProp: 'opsItemNo', |
|
|
|
headerAlign: 'center', |
|
|
|
align: 'right', |
|
|
|
@ -877,7 +878,7 @@ export default { |
|
|
|
functionId: 701001, |
|
|
|
serialNumber: '701001Table1ItemDesc', |
|
|
|
tableId: '701001Table1', |
|
|
|
tableName: '领料申请派工单子表', |
|
|
|
tableName: '领料申请工单子表', |
|
|
|
columnProp: 'itemDesc', |
|
|
|
headerAlign: 'center', |
|
|
|
align: 'left', |
|
|
|
@ -895,7 +896,7 @@ export default { |
|
|
|
functionId: 701001, |
|
|
|
serialNumber: '701001Table1LocationNo', |
|
|
|
tableId: '701001Table1', |
|
|
|
tableName: '领料申请派工单子表', |
|
|
|
tableName: '领料申请工单子表', |
|
|
|
columnProp: 'locationNo', |
|
|
|
headerAlign: 'center', |
|
|
|
align: 'left', |
|
|
|
@ -1206,7 +1207,7 @@ export default { |
|
|
|
serialNumber: '701001Table3PartDesc', |
|
|
|
tableId: '701001Table3', |
|
|
|
tableName: '领料申请BOM子表', |
|
|
|
columnProp: 'partDesc', |
|
|
|
columnProp: 'componentPartDesc', |
|
|
|
headerAlign: 'center', |
|
|
|
align: 'left', |
|
|
|
columnLabel: '物料描述', |
|
|
|
@ -1369,6 +1370,7 @@ export default { |
|
|
|
showAddNotifyTypeDialog: false, |
|
|
|
selectedNotifyType: 'production', |
|
|
|
selectedNotifyRemark:'', |
|
|
|
chooseLoading: false, |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
@ -1564,7 +1566,27 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
addNotify() { |
|
|
|
this.showAddNotifyTypeDialog = true |
|
|
|
//this.showAddNotifyTypeDialog = true |
|
|
|
let inData = { |
|
|
|
site: this.$store.state.user.site, |
|
|
|
userName: this.$store.state.user.name, |
|
|
|
} |
|
|
|
createNotify(inData).then(({ data }) => { |
|
|
|
if (data.code === 0) { |
|
|
|
this.showAddNotifyTypeDialog = false |
|
|
|
this.$message({ |
|
|
|
message: '操作成功', |
|
|
|
type: 'success', |
|
|
|
duration: 1500, |
|
|
|
onClose: () => {}, |
|
|
|
}) |
|
|
|
this.getUserNotifyNo() |
|
|
|
} else { |
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
confirmAddNotify() { |
|
|
|
let outWorkOrderFlag = 'N' |
|
|
|
@ -1599,6 +1621,7 @@ export default { |
|
|
|
}, |
|
|
|
chooseSOS(row) { |
|
|
|
if (this.dataList.length > 0) { |
|
|
|
//这边是有个判断的,判断派工单号不能重复 |
|
|
|
let stop = false |
|
|
|
for (let i = 0; i < this.dataList.length; i++) { |
|
|
|
if (this.dataList[i].seqNo == row.seqno) { |
|
|
|
@ -1612,19 +1635,34 @@ export default { |
|
|
|
return false |
|
|
|
} |
|
|
|
} |
|
|
|
console.log("row",row); |
|
|
|
|
|
|
|
this.notifyOrderData.partNo = row.partNo |
|
|
|
this.notifyOrderData.orderNo = row.orderNo |
|
|
|
this.notifyOrderData.itemNo = row.itemNo |
|
|
|
this.notifyOrderData.seqNo = row.seqNo |
|
|
|
this.notifyOrderData.partDesc = row.partDesc |
|
|
|
this.notifyOrderData.qtyRequired = row.qtyRequired |
|
|
|
let inData = { |
|
|
|
site: '55', |
|
|
|
orderNo: '3039496', |
|
|
|
} |
|
|
|
this.chooseLoading = true |
|
|
|
getIFSShopOrderByOrderNo(inData).then(({ data }) => { |
|
|
|
if (data.code === 0) { |
|
|
|
console.log("data",data); |
|
|
|
this.notifyOrderData.partNo = data.shopOrderVo[0].partNo |
|
|
|
this.notifyOrderData.orderNo = data.shopOrderVo[0].orderNo |
|
|
|
this.notifyOrderData.itemNo = data.shopOrderVo[0].itemNo |
|
|
|
this.notifyOrderData.seqNo = data.shopOrderVo[0].seqNo |
|
|
|
this.notifyOrderData.partDesc = data.shopOrderVo[0].partDesc |
|
|
|
this.notifyOrderData.qtyRequired = data.shopOrderVo[0].lotSize |
|
|
|
this.notifyOrderData.sResourceID = row.sResourceID |
|
|
|
this.notifyOrderData.issureQty = '' |
|
|
|
this.notifyOrderData.needDate = this.dayjs().format('YYYY-MM-DD HH:mm') |
|
|
|
this.notifyOrderData.locationNo = row.sResourceID |
|
|
|
this.saveSeqNoModalFlag = true |
|
|
|
}else { |
|
|
|
this.$meassage.error(data.msg) |
|
|
|
return; |
|
|
|
} |
|
|
|
}).finally(() => { |
|
|
|
this.chooseLoading = false |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
saveSOS() { |
|
|
|
if ( |
|
|
|
@ -1647,6 +1685,7 @@ export default { |
|
|
|
return false |
|
|
|
} |
|
|
|
let row = this.notifyOrderData |
|
|
|
console.log("row",row); |
|
|
|
if (this.dataList.length > 0) { |
|
|
|
let stop = false |
|
|
|
for (let i = 0; i < this.dataList.length; i++) { |
|
|
|
@ -1661,7 +1700,7 @@ export default { |
|
|
|
return false |
|
|
|
} |
|
|
|
} |
|
|
|
this.$confirm('确定选择工单' + row.seqno + '?', '提示', { |
|
|
|
this.$confirm('确定选择工单' + row.orderNo + '?', '提示', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
cancelButtonText: '取消', |
|
|
|
type: 'warning', |
|
|
|
@ -1669,10 +1708,10 @@ export default { |
|
|
|
let inData = { |
|
|
|
site: this.$store.state.user.site, |
|
|
|
notifyNo: this.notifyNo, |
|
|
|
fGPartNo: row.partNo, |
|
|
|
sOOrderNo: row.orderno, |
|
|
|
opsItemNo: row.itemno, |
|
|
|
seqNo: row.seqno, |
|
|
|
fgPartNo: row.partNo, |
|
|
|
soorderNo: row.orderNo, |
|
|
|
opsItemNo: row.itemNo, |
|
|
|
seqNo: row.seqNo, |
|
|
|
locationNo: row.locationNo, |
|
|
|
needDate: row.needDate, |
|
|
|
issureQty: row.issureQty, |
|
|
|
@ -1681,9 +1720,9 @@ export default { |
|
|
|
saveSOIssueNotifyOrderList(inData).then(({ data }) => { |
|
|
|
if (data.code === 0) { |
|
|
|
this.saveSeqNoModalFlag = false |
|
|
|
row.itemNo = data.itemNo |
|
|
|
this.getNotifyNoDetail() |
|
|
|
this.enterSOS(row) |
|
|
|
//this.itemNo = data.itemNo |
|
|
|
} else { |
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
@ -1702,14 +1741,28 @@ export default { |
|
|
|
let rows = { |
|
|
|
site: this.$store.state.user.site, |
|
|
|
notifyNo: this.notifyNo, |
|
|
|
orderno: row.sOOrderNo, |
|
|
|
seqno: row.seqNo, |
|
|
|
partNo: row.fGPartNo, |
|
|
|
itemno: row.opsItemNo, |
|
|
|
orderNo: row.soorderNo, |
|
|
|
seqNo: row.seqNo, |
|
|
|
partNo: row.fgPartNo, |
|
|
|
itemNo: row.itemNo, |
|
|
|
} |
|
|
|
this.itemNo = row.itemNo |
|
|
|
|
|
|
|
//this.searchNotifyMaterialList(rows) |
|
|
|
this.enterSOS(rows) |
|
|
|
}, |
|
|
|
searchNotifyMaterialList(row){ |
|
|
|
this.bomLoadFlag = true |
|
|
|
this.materialModalFlag = true |
|
|
|
searchNotifyMaterialList(row).then(({ data }) => { |
|
|
|
if (data.code === 0) { |
|
|
|
this.sobomList = data.rows |
|
|
|
this.bomLoadFlag = false |
|
|
|
} |
|
|
|
}).catch(()=>{ |
|
|
|
this.bomLoadFlag = false |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
enterSOS(row) { |
|
|
|
console.log("row",row); |
|
|
|
|
|
|
|
@ -1717,23 +1770,26 @@ export default { |
|
|
|
this.materialModalFlag = true |
|
|
|
this.sobomList = [] |
|
|
|
this.sobomData = { |
|
|
|
orderno: row.orderno, |
|
|
|
seqno: row.seqno, |
|
|
|
orderNo: row.orderNo, |
|
|
|
seqNo: row.seqNo, |
|
|
|
partNo: row.partNo, |
|
|
|
} |
|
|
|
this.bomLoadFlag = true |
|
|
|
let inData = { |
|
|
|
site: this.$store.state.user.site, |
|
|
|
notifyNo: this.notifyNo, |
|
|
|
orderno: row.orderno, |
|
|
|
seqno: row.seqno, |
|
|
|
orderNo: row.orderNo, |
|
|
|
seqNo: row.seqNo, |
|
|
|
partNo: row.partNo, |
|
|
|
itemno: row.itemno, |
|
|
|
itemNo: row.itemNo, |
|
|
|
} |
|
|
|
getSOSBOMForIssure(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 |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
@ -1772,6 +1828,8 @@ export default { |
|
|
|
) { |
|
|
|
this.sobomList[i].applyQty = 0 |
|
|
|
} |
|
|
|
this.sobomList[i].notifyNo = this.notifyNo |
|
|
|
this.sobomList[i].site = this.$store.state.user.site |
|
|
|
} |
|
|
|
|
|
|
|
let materialList = this.sobomList.filter((item) => item.qtyToIssue > 0) |
|
|
|
@ -1923,11 +1981,11 @@ export default { |
|
|
|
}) |
|
|
|
return false |
|
|
|
} |
|
|
|
checkPartStock(this.notifyData).then(({ data }) => { |
|
|
|
/* checkPartStock(this.notifyData).then(({ data }) => { |
|
|
|
if (data.code === 0) { |
|
|
|
this.xiadaList = data.rows |
|
|
|
} |
|
|
|
}) |
|
|
|
}) */ |
|
|
|
this.xiadaModelFlag = true |
|
|
|
}, |
|
|
|
xiadaNotify() { |
|
|
|
@ -2000,7 +2058,7 @@ export default { |
|
|
|
updateBuModel() { |
|
|
|
if (this.dataList.length > 0) { |
|
|
|
this.$alert( |
|
|
|
'已经选择了派工单,无法切换BU,请删除已选派工单!', |
|
|
|
'已经选择了工单,无法切换BU,请删除已选工单!', |
|
|
|
'错误', |
|
|
|
{ |
|
|
|
confirmButtonText: '确定', |
|
|
|
@ -2061,7 +2119,7 @@ export default { |
|
|
|
}, |
|
|
|
// 删除 |
|
|
|
deleteNotifySOS(row) { |
|
|
|
this.$confirm(`是否删除这个派工单的申请信息?`, '提示', { |
|
|
|
this.$confirm(`是否删除这个工单的申请信息?`, '提示', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
cancelButtonText: '取消', |
|
|
|
type: 'warning', |
|
|
|
@ -2216,4 +2274,17 @@ export default { |
|
|
|
height: 20px; |
|
|
|
} |
|
|
|
</style> |
|
|
|
<style scoped> |
|
|
|
/* 选择工单弹窗:紧凑表格与按钮样式 */ |
|
|
|
.choose-sos-btn { |
|
|
|
height: 14px; |
|
|
|
box-sizing: border-box; |
|
|
|
padding: 0 6px; |
|
|
|
line-height: 12px; |
|
|
|
font-size: 12px; |
|
|
|
display: inline-flex; |
|
|
|
align-items: center; |
|
|
|
justify-content: center; |
|
|
|
} |
|
|
|
</style> |
|
|
|
|