| | |
| | | }, |
| | | methods: { |
| | | nodeClick(data) { |
| | | this.treeDeptId = data.id; |
| | | if (data.id == "1123598813738675201") { |
| | | data.id = "1372091709474910209"; |
| | | } |
| | | this.treeDeptId = data; |
| | | this.page.currentPage = 1; |
| | | // console.log(this.treeDeptId); |
| | | this.onLoad(this.page); |
| | | }, |
| | | initData(tenantId, d) { |
| | |
| | | }, |
| | | onLoad(page, params = {}) { |
| | | this.loading = true; |
| | | var deptid = this.deptids == null ? this.treeDeptId : this.deptids; |
| | | var deptid = this.deptids == null ? this.treeDeptId.id : this.deptids; |
| | | //公安局进入 |
| | | if (this.userInfo.role_name == "公安管理员") { |
| | | params["jurisdiction"] = this.userInfo.jurisdiction; |
| | | } |
| | | params['status'] = 1; |
| | | var test = /派出所|分局|公安局|市公安局$/g; |
| | | var jurisdiction = ""; |
| | | if (test.test(this.treeDeptId.title)) { |
| | | jurisdiction = this.treeDeptId.id; |
| | | } |
| | | params["status"] = 1; |
| | | getList( |
| | | page.currentPage, |
| | | page.pageSize, |
| | | Object.assign(params, this.query), |
| | | deptid |
| | | deptid, |
| | | jurisdiction |
| | | ).then((res) => { |
| | | const data = res.data.data; |
| | | this.page.total = data.total; |
| | |
| | | }, |
| | | platformOnLoad(page, params = {}) { |
| | | this.platformLoading = true; |
| | | var jurisdiction = ""; |
| | | var deptid = this.deptids == null ? this.treeDeptId : this.deptids; |
| | | getList( |
| | | page.currentPage, |
| | | page.pageSize, |
| | | Object.assign(params, this.query), |
| | | deptid |
| | | deptid, |
| | | jurisdiction |
| | | ).then((res) => { |
| | | const data = res.data.data; |
| | | this.platformPage.total = data.total; |