|
|
|
@ -115,6 +115,7 @@ export class UserComponent implements OnInit {
|
|
|
|
|
} |
|
|
|
|
//获取所有组织机构
|
|
|
|
|
nodes: any = [] |
|
|
|
|
organization |
|
|
|
|
async getAllOrganization() { |
|
|
|
|
let OrganizationUnitId = sessionStorage.getItem('isGasStation') == 'true' ? JSON.parse(sessionStorage.getItem('userdataOfgasstation')).organization.id : JSON.parse(sessionStorage.getItem('userdata')).organization.id |
|
|
|
|
let params = { |
|
|
|
@ -125,6 +126,7 @@ export class UserComponent implements OnInit {
|
|
|
|
|
this.http.get('/api/services/app/Organization/GetAll', { |
|
|
|
|
params: params |
|
|
|
|
}).subscribe(async (data: any) => { |
|
|
|
|
this.organization = data.result.items |
|
|
|
|
await this.getuser(data.result.items) |
|
|
|
|
resolve(data) |
|
|
|
|
this.getAllUsers() |
|
|
|
@ -249,6 +251,14 @@ export class UserComponent implements OnInit {
|
|
|
|
|
nzOnOk: async () => { |
|
|
|
|
if (instance.validateForm.valid) { |
|
|
|
|
await new Promise(resolve => { |
|
|
|
|
|
|
|
|
|
for (let index = 0; index < instance.validateForm.value.role2.length; index++) { |
|
|
|
|
const element = instance.validateForm.value.role2[index]; |
|
|
|
|
if (element.indexOf('HANDLE') != -1) { |
|
|
|
|
instance.validateForm.value.role2.splice(index, 1) |
|
|
|
|
index-- |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
let roleNames = [...instance.validateForm.value.role, ...instance.validateForm.value.role2] |
|
|
|
|
let body = { |
|
|
|
|
id: data.id, |
|
|
|
|