From 6d348c6003c3b7ff2dfdd8dad6aa3f41fddd5d4a Mon Sep 17 00:00:00 2001
From: songhuangfeng123 <shf18767906695@163.com>
Date: Thu, 31 Mar 2022 10:37:21 +0800
Subject: [PATCH] fix
---
src/views/majorHazardSourceMonitoring/productionEquipment/index.vue | 49 +++++++++++++++++++++++++++----------------------
1 files changed, 27 insertions(+), 22 deletions(-)
diff --git a/src/views/majorHazardSourceMonitoring/productionEquipment/index.vue b/src/views/majorHazardSourceMonitoring/productionEquipment/index.vue
index 42f70b8..0c4be72 100644
--- a/src/views/majorHazardSourceMonitoring/productionEquipment/index.vue
+++ b/src/views/majorHazardSourceMonitoring/productionEquipment/index.vue
@@ -64,7 +64,7 @@
</template>
</el-table-column>
</el-table>
- <div style="text-align:right">
+ <div style="text-align:right;margin-top: 20px;">
<el-pagination
v-show="recordTotal>0"
@size-change="handleSizeChange"
@@ -145,7 +145,7 @@
<el-button type="primary" class="btns" @click="AddelementManagement()"
>确 定</el-button
>
- <el-button @click="dialogVisible = false">取 消</el-button>
+ <el-button @click="cancel()">取 消</el-button>
</span>
</el-dialog>
</div>
@@ -227,7 +227,6 @@
this.$nextTick(() => {
this.$refs["form"].clearValidate();
});
-
if (type == "新增") {
this.title = "新增";
this.form = {
@@ -257,10 +256,6 @@
title: "成功",
});
} else {
- this.$message({
- type: "warning",
- message: res.data.message,
- });
}
});
} else {
@@ -275,10 +270,7 @@
title: "成功",
});
} else {
- his.$message({
- type: "warning",
- message: res.data.message,
- });
+
}
});
}
@@ -286,17 +278,30 @@
});
},
deleteById(val) {
- majorEquipmentDel({id:val}).then((res) => {
- if (res.data.code == 200) {
- this.elementManagementL();
- this.$notify({
- title: "成功",
- message: "删除成功",
- type: "success",
- duration: 2000,
- });
- }
- });
+ this.$confirm('确认删除吗','提示', {
+ confirmButtonText: '确认',
+ cancelButtonText: '取消',
+ type: 'warning'
+ })
+ .then(()=>{
+ majorEquipmentDel({id:val}).then((res) => {
+ if (res.data.code == 200) {
+ this.elementManagementL();
+ this.$notify({
+ title: "成功",
+ message: "删除成功",
+ type: "success",
+ duration: 2000,
+ });
+ }
+ });
+ })
+ .catch(error =>{
+ });
+ },
+ cancel(){
+ this.elementManagementL();
+ this.dialogVisible = false;
},
find(){
this.elementManagementL();
--
Gitblit v1.9.2