Administrator
2021-11-26 66d85a91a9fbf30d9dc778658fa7d0a0709e5693
src/views/system/user.vue
@@ -200,7 +200,7 @@
  resetPassword,
  getJurisdiction,
} from "@/api/system/user";
import { getDeptTree, getDeptLazyTree } from "@/api/system/dept";
import { getSecurityDeptTree, getDeptLazyTree } from "@/api/system/dept";
import { getRoleTree } from "@/api/system/role";
import { getPostList } from "@/api/system/post";
import { mapGetters } from "vuex";
@@ -697,7 +697,7 @@
    },
  },
  created() {
    console.log(this.userInfo.role_name);
    // console.log(this.userInfo.role_name);
    if (
      this.userInfo.role_name == "保安公司管理员" ||
      this.userInfo.role_name == "分公司管理员"
@@ -706,7 +706,7 @@
      this.sizes = [0, 24];
      this.isguanli = false;
      this.option.group[0].column[0]["value"] = this.userInfo.dept_id;
      this.option.group[0].column[0]["disabled"] = true;
      // this.option.group[0].column[0]["disabled"] = true;
      // this.option.group[2].column[1]["disabled"] = true;
    } else {
      this.deptids = null;
@@ -739,7 +739,11 @@
      //     );
      //   });
      // };
      getDeptLazyTree(0).then((res) => {
      // getDeptLazyTree(0).then((res) => {
      //   that.treeData = res.data.data;
      // });
      // var parentId1 = this.userInfo.dept_id;
      getSecurityDeptTree(null,null,this.userInfo.dept_id).then((res) => {
        that.treeData = res.data.data;
      });
    }
@@ -784,11 +788,11 @@
          column.dicData = k;
        }
      });
// this.userInfo.role_name == "保安公司管理员"
      //公安局进入
      if (
        this.userInfo.role_name == "公安管理员" ||
        this.userInfo.role_name == "保安公司管理员"
        this.userInfo.role_name == "公安管理员"
      ) {
        var parentId = this.userInfo.dept_id;
        var userId = this.userInfo.Id;
@@ -797,9 +801,13 @@
          column.dicData = res.data.data;
        });
      } else {
        getDeptLazyTree(0).then((res) => {
          const column = this.findObject(this.option.group, "deptId");
          column.dicData = res.data.data;
        // getDeptLazyTree(0).then((res) => {
        //   const column = this.findObject(this.option.group, "deptId");
        //   column.dicData = res.data.data;
        // });
        getSecurityDeptTree(null,null,this.userInfo.dept_id).then((res) => {
            const column = this.findObject(this.option.group, "deptId");
            column.dicData = res.data.data;
        });
      }
      // getDeptTree(tenantId).then((res) => {