fix: 修复alert-config编辑弹框内删除无效的问题

This commit is contained in:
chenjinsong
2019-12-26 17:03:07 +08:00
parent d0f291f117
commit 9713286f34

View File

@@ -308,16 +308,17 @@
this.getAssetList(); this.getAssetList();
} }
}, },
del: function(u) { del: function() {
this.$confirm(this.$t("tip.confirmDelete"), { this.$confirm(this.$t("tip.confirmDelete"), {
confirmButtonText: this.$t("tip.yes"), confirmButtonText: this.$t("tip.yes"),
cancelButtonText: this.$t("tip.no"), cancelButtonText: this.$t("tip.no"),
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.$delete("alert/rule?ids=" + u.id).then(response => { this.$delete("alert/rule?ids=" + this.alertRule.id).then(response => {
if (response.code === 200) { if (response.code === 200) {
this.$message({type: 'success', message: this.$t("tip.deleteSuccess")}); this.$message({type: 'success', message: this.$t("tip.deleteSuccess")});
this.$emit('reload'); this.$emit('reload');
this.rightBox.show = false;
} else { } else {
this.$message.error(response.msg); this.$message.error(response.msg);
} }