| | |
| | | }; |
| | | }, |
| | | watch: { |
| | | // windowHeight() { |
| | | // let d = { |
| | | // option: this.option, |
| | | // fn: function () { |
| | | // console.log(123); |
| | | // }, |
| | | // add: 100, |
| | | // }; |
| | | // this.$store.dispatch("WHchangeHight", d); |
| | | // }, |
| | | radio() { |
| | | if (this.radio) { |
| | | this.SFZloding = true; |
| | |
| | | }, |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userInfo", "permission"]), |
| | | ...mapGetters(["userInfo", "permission", "windowHeight"]), |
| | | permissionList() { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.securityGuard_add, false), |
| | |
| | | var roleName = this.userInfo.role_name; |
| | | // console.log(this.userInfo,52252); |
| | | // this.userInfo.rname.forEach((roleName) => { |
| | | if ( |
| | | roleName == "保安公司管理员" || |
| | | roleName == "保安" || |
| | | roleName == "分公司管理员" |
| | | ) { |
| | | //查询保安单位信息(包含子级) |
| | | const column = this.findObject(this.option.column, "deptId"); |
| | | // column.search = false; |
| | | //默认全部展开 |
| | | column.defaultExpandAll = true; |
| | | column.dicUrl = |
| | | "/api/blade-system/dept/security_lazy-tree?deptId=" + |
| | | this.userInfo.dept_id; |
| | | } else if (roleName == "公安管理员" || roleName == "administrator") { |
| | | var columnDept = that.findObject(that.option.column, "deptId"); |
| | | columnDept.dicUrl = |
| | | "/api/blade-system/dept/security_lazy-tree?jurisdiction=" + |
| | | that.userInfo.jurisdiction; |
| | | } else { |
| | | //查询保安单位信息(包含子级) |
| | | const column = this.findObject(this.option.column, "deptId"); |
| | | // column.search = false; |
| | | //默认全部展开 |
| | | column.dicUrl = "/api/blade-system/dept/security_lazy-tree"; |
| | | } |
| | | if ( |
| | | roleName == "保安公司管理员" || |
| | | roleName == "保安" || |
| | | roleName == "分公司管理员" |
| | | ) { |
| | | //查询保安单位信息(包含子级) |
| | | const column = this.findObject(this.option.column, "deptId"); |
| | | // column.search = false; |
| | | //默认全部展开 |
| | | column.defaultExpandAll = true; |
| | | column.dicUrl = |
| | | "/api/blade-system/dept/security_lazy-tree?deptId=" + |
| | | this.userInfo.dept_id; |
| | | } else if (roleName == "公安管理员" || roleName == "administrator") { |
| | | var columnDept = that.findObject(that.option.column, "deptId"); |
| | | columnDept.dicUrl = |
| | | "/api/blade-system/dept/security_lazy-tree?jurisdiction=" + |
| | | that.userInfo.jurisdiction; |
| | | } else { |
| | | //查询保安单位信息(包含子级) |
| | | const column = this.findObject(this.option.column, "deptId"); |
| | | // column.search = false; |
| | | //默认全部展开 |
| | | column.dicUrl = "/api/blade-system/dept/security_lazy-tree"; |
| | | } |
| | | // }); |
| | | |
| | | if ( |