|
@@ -40,6 +40,9 @@
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button @click="modifyRelation(scope.row)" type="text" size="small">修改</el-button>
|
|
<el-button @click="modifyRelation(scope.row)" type="text" size="small">修改</el-button>
|
|
<span style="margin:0 3px;">|</span>
|
|
<span style="margin:0 3px;">|</span>
|
|
|
|
+ <el-button @click="resetFildF(scope.row)" v-if="scope.row.id !== -1" :style="scope.row.id !== -1? 'color: #48c5d7;' : 'color: #bfbfbf;'" type="text" size="small">方案重置</el-button>
|
|
|
|
+ <el-button type="text" size="small" v-else disabled>方案重置</el-button>
|
|
|
|
+ <span style="margin:0 3px;">|</span>
|
|
<el-button
|
|
<el-button
|
|
@click="startOrEndHos(scope.row,'start')"
|
|
@click="startOrEndHos(scope.row,'start')"
|
|
type="text"
|
|
type="text"
|
|
@@ -326,6 +329,34 @@ export default {
|
|
this.warning(error);
|
|
this.warning(error);
|
|
});
|
|
});
|
|
});
|
|
});
|
|
|
|
+ },
|
|
|
|
+ // 方案重置
|
|
|
|
+ resetFildF(row){
|
|
|
|
+ this.$confirm(`此操作将重置${row.name}数据, 是否继续?`, '提示', {
|
|
|
|
+ confirmButtonText: '确定',
|
|
|
|
+ cancelButtonText: '取消',
|
|
|
|
+ type: 'warning'
|
|
|
|
+ }).then(() => {
|
|
|
|
+ api.getResetFildF({
|
|
|
|
+ id: row.id
|
|
|
|
+ })
|
|
|
|
+ .then(res => {
|
|
|
|
+ if(res.data.code === '0'){
|
|
|
|
+ this.getDataList()
|
|
|
|
+ this.$message({
|
|
|
|
+ showClose: true,
|
|
|
|
+ message: '重置成功',
|
|
|
|
+ type: 'success',
|
|
|
|
+ duration: 1000
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ }).catch(() => {
|
|
|
|
+ this.$message({
|
|
|
|
+ type: 'info',
|
|
|
|
+ message: '已取消重置'
|
|
|
|
+ });
|
|
|
|
+ });
|
|
}
|
|
}
|
|
}
|
|
}
|
|
};
|
|
};
|