Revision 60545
Added by Konstantinos Triantafyllou about 3 years ago
role-users.component.ts | ||
---|---|---|
36 | 36 |
public notificationFn: Function; |
37 | 37 |
public user: User = null; |
38 | 38 |
public active: any[]; |
39 |
public managers: any[]; |
|
39 | 40 |
public pending: any[]; |
40 | 41 |
public showActive: boolean = true; |
41 | 42 |
public subs: any[] = []; |
... | ... | |
88 | 89 |
this.loadActive = true; |
89 | 90 |
this.loadPending = true; |
90 | 91 |
this.subs.push(this.userRegistryService.getActiveEmail(this.type, this.id, this.role).subscribe(users => { |
91 |
this.active = users; |
|
92 |
this.loadActive = false; |
|
93 |
this.exists = true; |
|
92 |
if(this.role === 'member') { |
|
93 |
this.subs.push(this.userRegistryService.getActiveEmail(this.type, this.id, 'manager').subscribe(managers => { |
|
94 |
this.managers = managers; |
|
95 |
this.active = users; |
|
96 |
this.active.forEach(user => { |
|
97 |
user['isManager'] = this.managers.find(manager => manager.email === user.email); |
|
98 |
}); |
|
99 |
this.loadActive = false; |
|
100 |
this.exists = true; |
|
101 |
})) |
|
102 |
} else { |
|
103 |
this.active = users; |
|
104 |
this.loadActive = false; |
|
105 |
this.exists = true; |
|
106 |
} |
|
94 | 107 |
}, error => { |
95 | 108 |
this.active = []; |
96 | 109 |
if(error.status === 404) { |
Also available in: Unified diff
[Library | Trunk]: 1. Role users disable remove button for members when a user is a manager. 2. Change email message for community managers invitation