From b6d70fd9329b1c5fee415713e7ca5d9dcab66526 Mon Sep 17 00:00:00 2001
From: liuyg <liuyg@qq.com>
Date: Wed, 02 Mar 2022 09:01:06 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.105:10010/r/zhba_enterprises
---
src/views/system/user.vue | 28 ++++++++++++++++++++++------
1 files changed, 22 insertions(+), 6 deletions(-)
diff --git a/src/views/system/user.vue b/src/views/system/user.vue
index e527212..fe5c521 100644
--- a/src/views/system/user.vue
+++ b/src/views/system/user.vue
@@ -717,7 +717,7 @@
var that = this;
//公安局进入
- if (this.userInfo.role_name == "公安管理员") {
+ if (this.userInfo.role_name == "公安管理员" || this.userInfo.role_name == "民警") {
var parentId = this.userInfo.dept_id;
var userId = this.userInfo.Id;
getDeptLazyTree(parentId, userId).then(res => {
@@ -803,8 +803,24 @@
column.dicData = b;
} else if (d == "公安管理员") {
for (var i in k) {
- if (k[i].title == "公安管理员") {
+ if (k[i].title == "公安管理员" || k[i].title == "民警") {
b.push(k[i]);
+ }
+ }
+ column.dicData = b;
+ }else if (d == "民警") {
+ for (var z in k) {
+ if (k[z].title == "民警") {
+ b.push(k[z]);
+ }
+ if (k[z].children) {
+ for (var ff in k[z].children) {
+ if (
+ k[z].children[ff].title == "民警"
+ ) {
+ b.push(k[z].children[ff]);
+ }
+ }
}
}
column.dicData = b;
@@ -814,7 +830,7 @@
});
// this.userInfo.role_name == "保安公司管理员"
//公安局进入
- if (this.userInfo.role_name == "公安管理员") {
+ if (this.userInfo.role_name == "公安管理员" || this.userInfo.role_name == "民警") {
var parentId = this.userInfo.dept_id;
var userId = this.userInfo.Id;
getDeptLazyTree(parentId, userId).then(res => {
@@ -1031,7 +1047,7 @@
},
beforeOpen(done, type) {
if (["edit", "view"].includes(type)) {
- if (this.userInfo.role_name != "公安管理员") {
+ if (this.userInfo.role_name != "公安管理员" && this.userInfo.role_name != "民警") {
const column = this.findObject(this.option.group, "code");
column.display = false;
}
@@ -1050,7 +1066,7 @@
});
}
if (["add"].includes(type)) {
- if (this.userInfo.role_name != "公安管理员") {
+ if (this.userInfo.role_name != "公安管理员" && this.userInfo.role_name !== "民警") {
const column = this.findObject(this.option.group, "code");
column.display = false;
}
@@ -1071,7 +1087,7 @@
this.loading = true;
var deptid = this.deptids == null ? this.treeDeptId.id : this.deptids;
//公安局进入
- if (this.userInfo.role_name == "公安管理员") {
+ if (this.userInfo.role_name == "公安管理员" || this.userInfo.role_name == "民警") {
params["jurisdiction"] = this.userInfo.jurisdiction;
params["roleId"] = "1";
}
--
Gitblit v1.9.3