Commit 9d08fc1c authored by jingnan's avatar jingnan 👀

指令下发强制关闭修改

parent a70a4c18
...@@ -33,6 +33,13 @@ ...@@ -33,6 +33,13 @@
label="序号" label="序号"
align="center" align="center"
/> />
<el-table-column
prop="area"
align="center"
label="机上区域"
:width="120"
sortable
/>
<el-table-column <el-table-column
prop="number" prop="number"
align="center" align="center"
...@@ -145,6 +152,13 @@ ...@@ -145,6 +152,13 @@
:width="120" :width="120"
sortable sortable
/> />
<el-table-column
prop="planStateLabel"
align="center"
label="计划状态"
:width="120"
sortable
/>
<el-table-column <el-table-column
prop="stateDisplayName" prop="stateDisplayName"
align="center" align="center"
...@@ -174,6 +188,7 @@ ...@@ -174,6 +188,7 @@
> >
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-if="scope.row.planStateLabel!=='已完成'"
type="danger" type="danger"
size="mini" size="mini"
@click.native.prevent="close(scope.row)" @click.native.prevent="close(scope.row)"
...@@ -282,6 +297,23 @@ ...@@ -282,6 +297,23 @@
/> />
</div> </div>
</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> </section>
</template> </template>
...@@ -339,7 +371,51 @@ export default { ...@@ -339,7 +371,51 @@ export default {
nodeData: {}, nodeData: {},
level: null, level: null,
loginUser: localStorage.getItem('userId'), 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() { created() {
...@@ -365,6 +441,7 @@ export default { ...@@ -365,6 +441,7 @@ export default {
}, },
async getDicListByCode() { async getDicListByCode() {
this.stateOption = await this.$utils.getDicListByCode('ObjStatus') this.stateOption = await this.$utils.getDicListByCode('ObjStatus')
this.joExecutePlanStateData = await this.$utils.getDicListByCode('PlanState')
}, },
/** /**
* 工作包选项数据 * 工作包选项数据
...@@ -662,15 +739,14 @@ export default { ...@@ -662,15 +739,14 @@ export default {
openProps: [ openProps: [
{ {
'name': 'extWorkPackageLinks', 'name': 'extWorkPackageLinks',
'pageFrom': 1,
'pageSize': 9999,
'openProps': [ 'openProps': [
{ {
'name': 'source', 'name': 'source'
'pageFrom': 1,
'pageSize': 9999
} }
] ]
},
{
'name': 'joExecutePlan'
} }
], ],
sortItem: [ sortItem: [
...@@ -714,8 +790,10 @@ export default { ...@@ -714,8 +790,10 @@ export default {
createTime: p.createTime, createTime: p.createTime,
processTaskId: p.id, processTaskId: p.id,
note: p.note, note: p.note,
area: p.area,
workPackageSelect: false, 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 && that.tableData.length &&
...@@ -823,12 +901,17 @@ export default { ...@@ -823,12 +901,17 @@ export default {
this.getTableData(this.nodeData, this.level) this.getTableData(this.nodeData, this.level)
}, },
close(row) { close(row) {
this.showDialog = true
this.curRow = row
},
closeConfirm(row) {
this.aoLoading = true this.aoLoading = true
post('/ExtProcessPlan/AORClosed?aoId=' + row.id, {},) post(`/ExtProcessPlan/AORClosed?aoId=${this.curRow.id}&aoNumber=${this.form.aoNumber}`, {},)
.then((res) => { .then((res) => {
if (res.message.includes('成功')) { if (res.message.includes('成功')) {
this.getTableData(this.nodeData, this.level) this.getTableData(this.nodeData, this.level)
this.$utils.showMessageSuccess(res.message) this.$utils.showMessageSuccess(res.message)
this.closeDialog()
} else { } else {
this.$message({ this.$message({
showClose: true, showClose: true,
...@@ -840,6 +923,9 @@ export default { ...@@ -840,6 +923,9 @@ export default {
.catch((err) => console.error(err)) .catch((err) => console.error(err))
.finally(() => {}) .finally(() => {})
}, },
closeDialog() {
this.showDialog = false
},
scrap(row) { scrap(row) {
this.aoLoading = true this.aoLoading = true
post('/ExtProcessPlan/cancel?aoId=' + row.id, {},) 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