删除动火未通知app端bug修复

pull/11/head
liujun 2024-02-05 16:49:53 +08:00
parent 186b35792b
commit 4522d10cfe
1 changed files with 34 additions and 6 deletions

View File

@ -67,18 +67,16 @@
<span v-else-if="row.APPLY_STATUS==-98">已作废未进行气体检测</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="230">
<el-table-column label="操作" align="center" width="350">
<template slot-scope="{row}">
<el-button type="danger" icon="el-icon-delete" @click="handleDelete(row)"></el-button>
<el-button type="primary" icon="el-icon-plus" @click="goChart(row)"></el-button>
<el-button type="primary" icon="el-icon-document" size="mini" @click="goDetail(row.HOTWORK_ID)"></el-button>
</template>
</el-table-column>
</el-table>
<div class="page-btn-group">
<div>
<!-- <el-button v-show="add" type="primary" icon="el-icon-plus" @click="handleAdd"></el-button>-->
<!-- <el-button v-show="del" type="danger" icon="el-icon-delete" plain @click="batchDel"></el-button>-->
</div>
<div/>
<pagination :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList" />
</div>
<el-dialog :visible.sync="dialogFormShow " :title="dialogType==='add'?'查看流程图':'新增'" width="1550px">
@ -168,7 +166,6 @@
</div>
</div>
<div slot="footer" class="dialog-footer">
<!-- <el-button @click="dialogFormShow = false"> </el-button>-->
<el-button type="primary" @click="dialogFormShow = false"> </el-button>
</div>
</el-dialog>
@ -394,6 +391,37 @@ export default {
goDetail(id) {
this.$parent.activeName = 'Detail'
this.$parent.HOTWORK_ID = id
},
handleDelete(row) {
if ((+row.APPLY_STATUS) >= 7) {
this.$message({
message: '数据已到验收阶段,暂不支持删除',
type: 'error'
})
} else {
this.$confirm('是否确定删除此条数据', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.$message({
type: 'success',
message: '删除成功!'
})
this.listLoading = true
requestFN(
'/hotwork/cfd/deleteInFlow', { HOTWORK_ID: row.HOTWORK_ID }
).then((data) => {
this.$message.error('删除成功')
this.listLoading = false
this.getList()
}).catch((e) => {
this.listLoading = false
})
}).catch(() => {
this.$message({ type: 'info', message: '已取消删除' })
})
}
}
}
}