增加强制停止按钮
This commit is contained in:
@@ -121,3 +121,12 @@ export function materialFinalData(data) {
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 复位
|
||||
export function materialReset(query) {
|
||||
return request({
|
||||
url: '/work/step/updateNextState',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
@@ -134,7 +134,10 @@
|
||||
<img src="../../../assets/img/FlowChart-2-2.png" class="image-circle-rows">
|
||||
</div>
|
||||
<div style="">
|
||||
|
||||
<el-button type="primary" plain
|
||||
@click="reset" :loading="!submitButton">
|
||||
强制停止
|
||||
</el-button>
|
||||
<el-button type="success" plain
|
||||
@click="submit(1)" :loading="!submitButton"
|
||||
>确认
|
||||
@@ -396,7 +399,8 @@ import {
|
||||
materialUpdate,
|
||||
stepPLC, stepProcess,
|
||||
stepSubmit,
|
||||
stepUpdate
|
||||
stepUpdate,
|
||||
materialReset
|
||||
} from '@/api/system/process'
|
||||
import {
|
||||
materialAbnormalStart,
|
||||
@@ -461,6 +465,19 @@ export default {
|
||||
})
|
||||
},
|
||||
|
||||
reset() {
|
||||
this.submitButton = false
|
||||
materialReset().then(res => {
|
||||
if (res.data == true) {
|
||||
this.$message('强制停止成功')
|
||||
this.submitButton = true
|
||||
this.getDataList()
|
||||
} else {
|
||||
this.$message('强制停止失败,请联系管理员')
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
submit(state) {
|
||||
// 获取正在运行的对象
|
||||
this.submitButton = false
|
||||
|
||||
@@ -134,6 +134,10 @@
|
||||
<img src="../../../assets/img/FlowChart-2-2.png" class="image-circle-rows">
|
||||
</div>
|
||||
<div style="">
|
||||
<el-button type="primary" plain
|
||||
@click="reset" :loading="!submitButton">
|
||||
强制停止
|
||||
</el-button>
|
||||
<el-button type="success" plain
|
||||
@click="submit(1)" :loading="!submitButton"
|
||||
>确认
|
||||
@@ -396,7 +400,8 @@ import {
|
||||
materialUpdate, stepCheck, stepFinish,
|
||||
stepNext, stepPLC, stepProcess,
|
||||
stepSubmit,
|
||||
stepUpdate
|
||||
stepUpdate,
|
||||
materialReset
|
||||
} from '@/api/system/process'
|
||||
import {getFaultMessage, newIP} from '@/api/system/common'
|
||||
|
||||
@@ -457,6 +462,17 @@ export default {
|
||||
})
|
||||
},
|
||||
|
||||
reset() {
|
||||
materialReset().then(res => {
|
||||
if (res.data == true) {
|
||||
this.$message('强制停止成功')
|
||||
this.getDataList()
|
||||
} else {
|
||||
this.$message('强制停止失败,请联系管理员')
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
submit(state) {
|
||||
this.submitButton = false
|
||||
// 获取正在运行的对象
|
||||
|
||||
Reference in New Issue
Block a user