|
|
|
|
@ -24,7 +24,7 @@ |
|
|
|
|
<el-button type="primary" @click="handleApprove">批量审核</el-button> |
|
|
|
|
</template> |
|
|
|
|
<template #menu-right> |
|
|
|
|
<el-button type="warning" @click="pendingReviewFn()" >待审核</el-button> |
|
|
|
|
<el-button type="warning" @click="pendingReviewFn()">待审核</el-button> |
|
|
|
|
</template> |
|
|
|
|
<template #menu="{ row }"> |
|
|
|
|
<el-button type="text" @click="handleView(row)">详情</el-button> |
|
|
|
|
@ -46,8 +46,8 @@ |
|
|
|
|
</el-form> |
|
|
|
|
<template #footer> |
|
|
|
|
<span class="dialog-footer"> |
|
|
|
|
<el-button type="danger" @click="approveDialog = false">不通过</el-button> |
|
|
|
|
<el-button type="primary" @click="submitApprove">通过</el-button> |
|
|
|
|
<el-button @click="approveDialog = false">取消</el-button> |
|
|
|
|
<el-button type="primary" @click="submitApprove">确定</el-button> |
|
|
|
|
</span> |
|
|
|
|
</template> |
|
|
|
|
</el-dialog> |
|
|
|
|
@ -66,7 +66,7 @@ export default { |
|
|
|
|
}, |
|
|
|
|
data() { |
|
|
|
|
return { |
|
|
|
|
id:null, |
|
|
|
|
id: null, |
|
|
|
|
searchForm: {}, |
|
|
|
|
tabPosition: 'addRequirements', |
|
|
|
|
loading: false, |
|
|
|
|
@ -117,7 +117,211 @@ export default { |
|
|
|
|
gridBtn: false, |
|
|
|
|
searchMenuPosition: 'right', |
|
|
|
|
align: 'center', |
|
|
|
|
column: [], |
|
|
|
|
column: [ |
|
|
|
|
{ |
|
|
|
|
label: '需求单号', |
|
|
|
|
prop: 'demandCode', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: true, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
searchLabelWidth: 80, |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入需求单号', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '作业中心', |
|
|
|
|
prop: 'wcId', |
|
|
|
|
span: 24, |
|
|
|
|
type: 'select', |
|
|
|
|
width: 150, |
|
|
|
|
overflow: true, |
|
|
|
|
search: true, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
searchLabelWidth: 80, |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入作业中心', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
dicUrl: '/blade-desk/bsWorkCenter/getList', |
|
|
|
|
props: { |
|
|
|
|
label: 'wcName', |
|
|
|
|
value: 'id', |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '物料编号', |
|
|
|
|
prop: 'goodsCode', |
|
|
|
|
span: 24, |
|
|
|
|
width: 150, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入物料编号', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '物料名称', |
|
|
|
|
prop: 'goodsName', |
|
|
|
|
span: 24, |
|
|
|
|
width: 150, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入物料名称', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '镀层物料需求(克)', |
|
|
|
|
prop: 'goodsDemand', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
width: 160, |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入金钾申报量(克)', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '已使用(克)', |
|
|
|
|
prop: 'usedGoldVal', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入金钾申报量(克)', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '申报量(克)', |
|
|
|
|
prop: 'declaredQuota', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入银钾申报量(克)', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '剩余量(克)', |
|
|
|
|
prop: 'surplus', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入银板申报量(克)', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '状态', |
|
|
|
|
prop: 'status', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: true, |
|
|
|
|
type: 'select', |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
searchLabelWidth: 50, |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入状态', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
dicData: [ |
|
|
|
|
// { label: '待领取', value: 1 }, |
|
|
|
|
// { label: '已领取', value: 2 }, |
|
|
|
|
// { label: '已过期', value: 3 }, |
|
|
|
|
{ label: '待审核', value: 10000 }, |
|
|
|
|
{ label: '审核通过', value: 10001 }, |
|
|
|
|
{ label: '使用中', value: 10002 }, |
|
|
|
|
{ label: '审核不通过', value: 10005 }, |
|
|
|
|
{ label: '已完成', value: 10004 }, |
|
|
|
|
{ label: '已超期', value: 10003 }, |
|
|
|
|
{ label: '已关闭', value: 10006 }, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '创建人', |
|
|
|
|
prop: 'createUserName', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入申报人', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: '创建时间', |
|
|
|
|
prop: 'createTime', |
|
|
|
|
span: 24, |
|
|
|
|
overflow: true, |
|
|
|
|
search: false, |
|
|
|
|
headerAlign: 'center', |
|
|
|
|
align: 'center', |
|
|
|
|
width:160, |
|
|
|
|
rules: [ |
|
|
|
|
{ |
|
|
|
|
required: true, |
|
|
|
|
message: '请输入创建时间', |
|
|
|
|
trigger: 'blur', |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
approveRules: { |
|
|
|
|
approvalStatus: [{ required: true, message: '请选择审批结果', trigger: 'blur' }], |
|
|
|
|
@ -130,17 +334,17 @@ export default { |
|
|
|
|
total: 0, |
|
|
|
|
}, |
|
|
|
|
selectionList: [], |
|
|
|
|
query:{} |
|
|
|
|
query: {}, |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
|
mounted() { |
|
|
|
|
this.option.column = coatingColumnData[this.tabPosition]; |
|
|
|
|
// this.option.column = coatingColumnData[this.tabPosition]; |
|
|
|
|
}, |
|
|
|
|
methods: { |
|
|
|
|
// 待审核搜索 |
|
|
|
|
pendingReviewFn() { |
|
|
|
|
this.query.status = 10000 |
|
|
|
|
this.onLoad() |
|
|
|
|
this.query.status = 10000; |
|
|
|
|
this.onLoad(); |
|
|
|
|
// this.onLoad(this.page, { type: '2' }); |
|
|
|
|
}, |
|
|
|
|
searchReset() { |
|
|
|
|
@ -159,7 +363,7 @@ export default { |
|
|
|
|
}, |
|
|
|
|
// 点击详情 |
|
|
|
|
handleView(row) { |
|
|
|
|
this.id=row.id |
|
|
|
|
this.id = row.id; |
|
|
|
|
this.addDialog = true; |
|
|
|
|
}, |
|
|
|
|
deleteRow(row) { |
|
|
|
|
@ -185,8 +389,8 @@ export default { |
|
|
|
|
this.showDialog = false; |
|
|
|
|
this.addQuantity = false; |
|
|
|
|
this.addDialog = false; |
|
|
|
|
if(val){ |
|
|
|
|
this.onLoad() |
|
|
|
|
if (val) { |
|
|
|
|
this.onLoad(); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
addQuantityClick() { |
|
|
|
|
@ -204,11 +408,16 @@ export default { |
|
|
|
|
this.$refs.crud.toggleSelection(); |
|
|
|
|
}, |
|
|
|
|
handleApprove() { |
|
|
|
|
if (this.selectionList.length != 0) { |
|
|
|
|
this.approveDialog = true; |
|
|
|
|
} else { |
|
|
|
|
if(this.selectionList.length == 0){ |
|
|
|
|
this.$message.error('请至少选择一条数据!'); |
|
|
|
|
return |
|
|
|
|
} |
|
|
|
|
let tmp = this.selectionList.find(item => item.status != 10000) |
|
|
|
|
if(tmp){ |
|
|
|
|
this.$message.error('请选择状态为【待审核】的数据') |
|
|
|
|
return |
|
|
|
|
} |
|
|
|
|
this.approveDialog = true; |
|
|
|
|
}, |
|
|
|
|
submitApprove() { |
|
|
|
|
this.$refs.approveForm.validate(valid => { |
|
|
|
|
@ -223,20 +432,19 @@ export default { |
|
|
|
|
this.onLoad(); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
this.approveDialog = false; |
|
|
|
|
this.$refs.crud.toggleSelection(); |
|
|
|
|
this.onLoad(this.page); |
|
|
|
|
// this.approveDialog = false; |
|
|
|
|
// this.$refs.crud.toggleSelection(); |
|
|
|
|
// this.onLoad(this.page); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
async onLoad(page, params = {}) { |
|
|
|
|
|
|
|
|
|
try { |
|
|
|
|
this.loading = true; |
|
|
|
|
const res = await getList({ |
|
|
|
|
current:this.page.currentPage, |
|
|
|
|
size:this.page.pageSize, |
|
|
|
|
...this.query |
|
|
|
|
current: this.page.currentPage, |
|
|
|
|
size: this.page.pageSize, |
|
|
|
|
...this.query, |
|
|
|
|
}); |
|
|
|
|
// if (res.code) { |
|
|
|
|
this.data = res.data.data.records; |
|
|
|
|
|