|
|
@ -43,8 +43,8 @@ |
|
|
:label="item.columnLabel"> |
|
|
:label="item.columnLabel"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<span v-if="!item.columnHidden">{{ |
|
|
<span v-if="!item.columnHidden">{{ |
|
|
item.columnProp === 'status' |
|
|
|
|
|
? (scope.row.status === 'Y' ? '在用' : scope.row.status === 'N' ? '禁用' : scope.row.status) |
|
|
|
|
|
|
|
|
item.columnProp === 'partStage' |
|
|
|
|
|
? formatPartStageDesc(scope.row.partStage) |
|
|
: scope.row[item.columnProp] |
|
|
: scope.row[item.columnProp] |
|
|
}}</span> |
|
|
}}</span> |
|
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
|
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
|
|
@ -141,7 +141,7 @@ |
|
|
<el-form-item label="产品规格" prop="partSpec"> |
|
|
<el-form-item label="产品规格" prop="partSpec"> |
|
|
<el-input v-model="currentpart.partSpec"></el-input> |
|
|
<el-input v-model="currentpart.partSpec"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
|
|
|
|
|
|
</el-col> |
|
|
</el-row> |
|
|
</el-row> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
@ -166,10 +166,10 @@ |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="6"> |
|
|
<el-col :span="6"> |
|
|
<el-form-item label="是否在用"> |
|
|
|
|
|
|
|
|
<el-form-item label="状态"> |
|
|
<el-select v-model="currentpart.status" placeholder="请选择" > |
|
|
<el-select v-model="currentpart.status" placeholder="请选择" > |
|
|
<el-option label="在用" value="Y"></el-option> |
|
|
|
|
|
<el-option label="禁用" value="N"></el-option> |
|
|
|
|
|
|
|
|
<el-option label="启用" value="N"></el-option> |
|
|
|
|
|
<el-option label="停用" value="Y"></el-option> |
|
|
</el-select> |
|
|
</el-select> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
@ -461,6 +461,24 @@ export default { |
|
|
status: true, |
|
|
status: true, |
|
|
fixed: false |
|
|
fixed: false |
|
|
}, |
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
userId: this.$store.state.user.name, |
|
|
|
|
|
functionId: this.functionId, |
|
|
|
|
|
serialNumber: 'partTablePartStage', |
|
|
|
|
|
tableId: 'partTable', |
|
|
|
|
|
tableName: '产品信息', |
|
|
|
|
|
columnProp: 'partStage', |
|
|
|
|
|
headerAlign: 'center', |
|
|
|
|
|
align: 'center', |
|
|
|
|
|
columnLabel: '物料阶段', |
|
|
|
|
|
columnWidth: '100', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
columnSortable: false, |
|
|
|
|
|
sortLv: 0, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: false |
|
|
|
|
|
}, |
|
|
{ |
|
|
{ |
|
|
userId: this.$store.state.user.name, |
|
|
userId: this.$store.state.user.name, |
|
|
functionId: this.functionId, |
|
|
functionId: this.functionId, |
|
|
@ -470,7 +488,7 @@ export default { |
|
|
columnProp: 'status', |
|
|
columnProp: 'status', |
|
|
headerAlign: 'center', |
|
|
headerAlign: 'center', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
columnLabel: '是否在用', |
|
|
|
|
|
|
|
|
columnLabel: '状态', |
|
|
columnWidth: '80', |
|
|
columnWidth: '80', |
|
|
columnHidden: false, |
|
|
columnHidden: false, |
|
|
columnImage: false, |
|
|
columnImage: false, |
|
|
@ -583,7 +601,7 @@ export default { |
|
|
sourcingName: '', |
|
|
sourcingName: '', |
|
|
category: '', |
|
|
category: '', |
|
|
unit: '', |
|
|
unit: '', |
|
|
status: 'Y', |
|
|
|
|
|
|
|
|
status: 'N', |
|
|
codeNo: '', |
|
|
codeNo: '', |
|
|
createBy: '', |
|
|
createBy: '', |
|
|
remark: '', |
|
|
remark: '', |
|
|
@ -602,8 +620,8 @@ export default { |
|
|
partSpec: [ |
|
|
partSpec: [ |
|
|
{ required: true, message: ' ', trigger: 'blur' } |
|
|
{ required: true, message: ' ', trigger: 'blur' } |
|
|
] |
|
|
] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
@ -626,9 +644,12 @@ export default { |
|
|
this.height = (window.innerHeight - 280) / 2 |
|
|
this.height = (window.innerHeight - 280) / 2 |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
formatPartStageDesc (partStage) { |
|
|
|
|
|
return partStage === 'Approved' ? '正式物料' : '新增物料' |
|
|
|
|
|
}, |
|
|
getBaseList (val, type) { |
|
|
getBaseList (val, type) { |
|
|
this.tagNo = val |
|
|
this.tagNo = val |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
|
@ -649,7 +670,7 @@ export default { |
|
|
if (val === 528) { |
|
|
if (val === 528) { |
|
|
strVal = this.currentpart.sourcingName |
|
|
strVal = this.currentpart.sourcingName |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (val === 527) { |
|
|
if (val === 527) { |
|
|
strVal = this.currentpart.codeNo |
|
|
strVal = this.currentpart.codeNo |
|
|
} |
|
|
} |
|
|
@ -676,12 +697,12 @@ export default { |
|
|
if (this.tagNo === 528) { |
|
|
if (this.tagNo === 528) { |
|
|
this.currentpart.sourcingName = val.UserName |
|
|
this.currentpart.sourcingName = val.UserName |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (this.tagNo === 527) { |
|
|
if (this.tagNo === 527) { |
|
|
this.currentpart.codeNo = val.code_no |
|
|
this.currentpart.codeNo = val.code_no |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
getMainData () { |
|
|
getMainData () { |
|
|
this.searchData.limit = this.pageSize |
|
|
this.searchData.limit = this.pageSize |
|
|
this.searchData.page = this.pageIndex |
|
|
this.searchData.page = this.pageIndex |
|
|
@ -693,16 +714,16 @@ export default { |
|
|
if (item.flowNodeInstanceData) { |
|
|
if (item.flowNodeInstanceData) { |
|
|
item.departmentName = item.flowNodeInstanceData.departmentName; |
|
|
item.departmentName = item.flowNodeInstanceData.departmentName; |
|
|
item.assigneeName = item.flowNodeInstanceData.assigneeName; |
|
|
item.assigneeName = item.flowNodeInstanceData.assigneeName; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
} else { |
|
|
item.departmentName = ''; |
|
|
item.departmentName = ''; |
|
|
item.assigneeName = ''; |
|
|
item.assigneeName = ''; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
return item; |
|
|
return item; |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// this.mainDataList = data.page.list |
|
|
// this.mainDataList = data.page.list |
|
|
this.pageIndex = data.page.currPage |
|
|
this.pageIndex = data.page.currPage |
|
|
this.pageSize = data.page.pageSize |
|
|
this.pageSize = data.page.pageSize |
|
|
@ -719,11 +740,11 @@ export default { |
|
|
this.dataListLoading = false |
|
|
this.dataListLoading = false |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
tabClick (tab, event) { |
|
|
tabClick (tab, event) { |
|
|
this.refreshCurrentTabTable() |
|
|
this.refreshCurrentTabTable() |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 每页数 |
|
|
// 每页数 |
|
|
sizeChangeHandle (val) { |
|
|
sizeChangeHandle (val) { |
|
|
this.pageSize = val |
|
|
this.pageSize = val |
|
|
@ -736,12 +757,12 @@ export default { |
|
|
this.pageIndex = val |
|
|
this.pageIndex = val |
|
|
this.getMainData() |
|
|
this.getMainData() |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
changeData (row) { |
|
|
changeData (row) { |
|
|
this.currentRow = JSON.parse(JSON.stringify(row)) |
|
|
this.currentRow = JSON.parse(JSON.stringify(row)) |
|
|
this.refreshCurrentTabTable() |
|
|
this.refreshCurrentTabTable() |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
refreshCurrentTabTable () { |
|
|
refreshCurrentTabTable () { |
|
|
if (this.currentRow === '' || this.currentRow === null) { |
|
|
if (this.currentRow === '' || this.currentRow === null) { |
|
|
this.currentRow = {site: '', partNo: ''} |
|
|
this.currentRow = {site: '', partNo: ''} |
|
|
@ -762,7 +783,7 @@ export default { |
|
|
this.refreshAttachments() |
|
|
this.refreshAttachments() |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
async exportExcel () { |
|
|
async exportExcel () { |
|
|
this.searchData.limit = -1 |
|
|
this.searchData.limit = -1 |
|
|
this.searchData.page = 1 |
|
|
this.searchData.page = 1 |
|
|
@ -773,11 +794,13 @@ export default { |
|
|
params: this.searchData, |
|
|
params: this.searchData, |
|
|
fileName: this.exportName + '.xlsx', |
|
|
fileName: this.exportName + '.xlsx', |
|
|
rowFetcher: res => res.data, |
|
|
rowFetcher: res => res.data, |
|
|
columnFormatter: [], |
|
|
|
|
|
|
|
|
columnFormatter: [ |
|
|
|
|
|
{ columnProp: 'partStage', formatter: (val) => this.formatPartStageDesc(val) } |
|
|
|
|
|
], |
|
|
dropColumns: [] |
|
|
dropColumns: [] |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
refreshBasicInfo () { |
|
|
refreshBasicInfo () { |
|
|
let inData = { |
|
|
let inData = { |
|
|
site: this.currentRow.site, |
|
|
site: this.currentRow.site, |
|
|
@ -787,7 +810,7 @@ export default { |
|
|
} |
|
|
} |
|
|
this.$refs.basicInfo.init(inData) |
|
|
this.$refs.basicInfo.init(inData) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
refreshSpecParams () { |
|
|
refreshSpecParams () { |
|
|
let inData = { |
|
|
let inData = { |
|
|
site: this.currentRow.site, |
|
|
site: this.currentRow.site, |
|
|
@ -798,7 +821,7 @@ export default { |
|
|
} |
|
|
} |
|
|
this.$refs.specParams.init(inData) |
|
|
this.$refs.specParams.init(inData) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
refreshSuppliers () { |
|
|
refreshSuppliers () { |
|
|
let inData = { |
|
|
let inData = { |
|
|
site: this.currentRow.site, |
|
|
site: this.currentRow.site, |
|
|
@ -807,7 +830,7 @@ export default { |
|
|
} |
|
|
} |
|
|
this.$refs.suppliers.init(inData) |
|
|
this.$refs.suppliers.init(inData) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
refreshApproval () { |
|
|
refreshApproval () { |
|
|
let inData = { |
|
|
let inData = { |
|
|
site: this.currentRow.site, |
|
|
site: this.currentRow.site, |
|
|
@ -817,18 +840,18 @@ export default { |
|
|
} |
|
|
} |
|
|
this.$refs.approval.init(inData) |
|
|
this.$refs.approval.init(inData) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
refreshAttachments () { |
|
|
refreshAttachments () { |
|
|
let inData = { |
|
|
let inData = { |
|
|
orderRef1: this.currentRow.site, |
|
|
orderRef1: this.currentRow.site, |
|
|
orderRef2: this.currentRow.partNo, |
|
|
orderRef2: this.currentRow.partNo, |
|
|
orderRef3: this.currentRow.partDesc, |
|
|
orderRef3: this.currentRow.partDesc, |
|
|
orderReftype: 'part', |
|
|
|
|
|
|
|
|
orderReftype: 'part', |
|
|
height: Number(this.height) - 20 |
|
|
height: Number(this.height) - 20 |
|
|
} |
|
|
} |
|
|
this.$refs.attachments.init(inData) |
|
|
this.$refs.attachments.init(inData) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 新增产品 |
|
|
// 新增产品 |
|
|
addPart() { |
|
|
addPart() { |
|
|
this.isAdd = true |
|
|
this.isAdd = true |
|
|
@ -841,7 +864,7 @@ export default { |
|
|
sourcingName: '', |
|
|
sourcingName: '', |
|
|
category: '', |
|
|
category: '', |
|
|
unit: '', |
|
|
unit: '', |
|
|
status: 'Y', |
|
|
|
|
|
|
|
|
status: 'N', |
|
|
codeNo: '', |
|
|
codeNo: '', |
|
|
createBy: this.$store.state.user.name, |
|
|
createBy: this.$store.state.user.name, |
|
|
remark: '', |
|
|
remark: '', |
|
|
@ -849,7 +872,7 @@ export default { |
|
|
} |
|
|
} |
|
|
this.partDialogVisible = true |
|
|
this.partDialogVisible = true |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 编辑产品 |
|
|
// 编辑产品 |
|
|
editPart(row) { |
|
|
editPart(row) { |
|
|
if (!row) { |
|
|
if (!row) { |
|
|
@ -860,7 +883,7 @@ export default { |
|
|
this.currentpart = {...row} |
|
|
this.currentpart = {...row} |
|
|
this.partDialogVisible = true |
|
|
this.partDialogVisible = true |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 保存产品 |
|
|
// 保存产品 |
|
|
savePart() { |
|
|
savePart() { |
|
|
this.$refs.partForm.validate((valid) => { |
|
|
this.$refs.partForm.validate((valid) => { |
|
|
@ -913,7 +936,7 @@ export default { |
|
|
// flowVersion: row.flowNodeInstanceData.flowVersion, |
|
|
// flowVersion: row.flowNodeInstanceData.flowVersion, |
|
|
// nodeCode: row.flowNodeInstanceData.nodeCode, |
|
|
// nodeCode: row.flowNodeInstanceData.nodeCode, |
|
|
// comment: '' |
|
|
// comment: '' |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// } |
|
|
// } |
|
|
// this.approveDialogVisible = true |
|
|
// this.approveDialogVisible = true |
|
|
// }, |
|
|
// }, |
|
|
@ -967,7 +990,7 @@ export default { |
|
|
// }) |
|
|
// }) |
|
|
// }).catch(() => {}) |
|
|
// }).catch(() => {}) |
|
|
// } |
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
@ -1090,4 +1113,4 @@ export default { |
|
|
height: 28px; |
|
|
height: 28px; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
</style> |
|
|
|
|
|
|
|
|
</style> |