Commit 9d08fc1c authored by jingnan's avatar jingnan 👀

指令下发强制关闭修改

parent a70a4c18
......@@ -33,6 +33,13 @@
label="序号"
align="center"
/>
<el-table-column
prop="area"
align="center"
label="机上区域"
:width="120"
sortable
/>
<el-table-column
prop="number"
align="center"
......@@ -145,6 +152,13 @@
:width="120"
sortable
/>
<el-table-column
prop="planStateLabel"
align="center"
label="计划状态"
:width="120"
sortable
/>
<el-table-column
prop="stateDisplayName"
align="center"
......@@ -174,6 +188,7 @@
>
<template slot-scope="scope">
<el-button
v-if="scope.row.planStateLabel!=='已完成'"
type="danger"
size="mini"
@click.native.prevent="close(scope.row)"
......@@ -282,6 +297,23 @@
/>
</div>
</div>
<dee-dialog
title=" 关闭依据"
width="800px"
height="500px"
:dialog-visible="showDialog"
@handleClose="closeDialog"
>
<dee-form
:form="form"
:form-data="formData"
:form-buttons="formButtons"
form-btn-position="center"
:rules="rules"
@on-submit="closeConfirm"
@on-cancel="closeDialog"
/>
</dee-dialog>
</section>
</template>
......@@ -339,7 +371,51 @@ export default {
nodeData: {},
level: null,
loginUser: localStorage.getItem('userId'),
loginUserName: localStorage.getItem('user')
loginUserName: localStorage.getItem('user'),
curRow: null,
joExecutePlanStateData: [],
showDialog: false,
form: {
aoNumber: ''
},
formData: [
{
title: '',
split: 1,
data: [
{
title: '关闭依据',
key: 'aoNumber',
component: {
name: 'el-input',
disabled: false
}
}
]
}
],
rules: {
aoNumber: [
{ required: true, message: '请选择', trigger: 'blur' }
]
},
formButtons: [
{
text: '确定',
type: 'submit',
component: {
type: 'primary',
size: 'small'
}
},
{
text: '取消',
type: 'cancel',
component: {
size: 'small'
}
}
]
}
},
created() {
......@@ -365,6 +441,7 @@ export default {
},
async getDicListByCode() {
this.stateOption = await this.$utils.getDicListByCode('ObjStatus')
this.joExecutePlanStateData = await this.$utils.getDicListByCode('PlanState')
},
/**
* 工作包选项数据
......@@ -662,15 +739,14 @@ export default {
openProps: [
{
'name': 'extWorkPackageLinks',
'pageFrom': 1,
'pageSize': 9999,
'openProps': [
{
'name': 'source',
'pageFrom': 1,
'pageSize': 9999
'name': 'source'
}
]
},
{
'name': 'joExecutePlan'
}
],
sortItem: [
......@@ -714,8 +790,10 @@ export default {
createTime: p.createTime,
processTaskId: p.id,
note: p.note,
area: p.area,
workPackageSelect: false,
workPackage: p.extWorkPackageLinks && p.extWorkPackageLinks[0].source.id
workPackage: p.extWorkPackageLinks && p.extWorkPackageLinks[0].source.id,
planStateLabel: p.joExecutePlan && this.$utils.getParamsFromLists(this.joExecutePlanStateData, 'value', p.joExecutePlan[0].planState, 'label')
}
})
that.tableData.length &&
......@@ -823,12 +901,17 @@ export default {
this.getTableData(this.nodeData, this.level)
},
close(row) {
this.showDialog = true
this.curRow = row
},
closeConfirm(row) {
this.aoLoading = true
post('/ExtProcessPlan/AORClosed?aoId=' + row.id, {},)
post(`/ExtProcessPlan/AORClosed?aoId=${this.curRow.id}&aoNumber=${this.form.aoNumber}`, {},)
.then((res) => {
if (res.message.includes('成功')) {
this.getTableData(this.nodeData, this.level)
this.$utils.showMessageSuccess(res.message)
this.closeDialog()
} else {
this.$message({
showClose: true,
......@@ -840,6 +923,9 @@ export default {
.catch((err) => console.error(err))
.finally(() => {})
},
closeDialog() {
this.showDialog = false
},
scrap(row) {
this.aoLoading = true
post('/ExtProcessPlan/cancel?aoId=' + row.id, {},)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment