From fbbdd9499906a37c7c8f5758562f5790e9aa78e9 Mon Sep 17 00:00:00 2001
From: 若依 <yzz_ivy@163.com>
Date: Tue, 13 Oct 2020 14:38:02 +0800
Subject: [PATCH] !105 update ruoyi-ui/src/views/system/role/index.vue. Merge pull request !105 from FlyFive/N/A
---
ruoyi-ui/src/views/system/role/index.vue | 32 +++++++++++++-------------------
1 files changed, 13 insertions(+), 19 deletions(-)
diff --git a/ruoyi-ui/src/views/system/role/index.vue b/ruoyi-ui/src/views/system/role/index.vue
index f54a7e7..7835eb6 100644
--- a/ruoyi-ui/src/views/system/role/index.vue
+++ b/ruoyi-ui/src/views/system/role/index.vue
@@ -377,9 +377,9 @@
// 所有部门节点数据
getDeptAllCheckedKeys() {
// 目前被选中的部门节点
- let checkedKeys = this.$refs.dept.getHalfCheckedKeys();
+ let checkedKeys = this.$refs.dept.getCheckedKeys();
// 半选中的部门节点
- let halfCheckedKeys = this.$refs.dept.getCheckedKeys();
+ let halfCheckedKeys = this.$refs.dept.getHalfCheckedKeys();
checkedKeys.unshift.apply(checkedKeys, halfCheckedKeys);
return checkedKeys;
},
@@ -537,20 +537,16 @@
if (this.form.roleId != undefined) {
this.form.menuIds = this.getMenuAllCheckedKeys();
updateRole(this.form).then(response => {
- if (response.code === 200) {
- this.msgSuccess("修改成功");
- this.open = false;
- this.getList();
- }
+ this.msgSuccess("修改成功");
+ this.open = false;
+ this.getList();
});
} else {
this.form.menuIds = this.getMenuAllCheckedKeys();
addRole(this.form).then(response => {
- if (response.code === 200) {
- this.msgSuccess("新增成功");
- this.open = false;
- this.getList();
- }
+ this.msgSuccess("新增成功");
+ this.open = false;
+ this.getList();
});
}
}
@@ -561,11 +557,9 @@
if (this.form.roleId != undefined) {
this.form.deptIds = this.getDeptAllCheckedKeys();
dataScope(this.form).then(response => {
- if (response.code === 200) {
- this.msgSuccess("修改成功");
- this.openDataScope = false;
- this.getList();
- }
+ this.msgSuccess("修改成功");
+ this.openDataScope = false;
+ this.getList();
});
}
},
@@ -581,7 +575,7 @@
}).then(() => {
this.getList();
this.msgSuccess("删除成功");
- }).catch(function() {});
+ })
},
/** 导出按钮操作 */
handleExport() {
@@ -594,7 +588,7 @@
return exportRole(queryParams);
}).then(response => {
this.download(response.msg);
- }).catch(function() {});
+ })
}
}
};
--
Gitblit v1.9.2