Show group members

This commit is contained in:
Girish Ramakrishnan
2018-07-26 23:58:25 -07:00
parent fb85770fd3
commit a9e46c64b1
2 changed files with 8 additions and 1 deletions

View File

@@ -323,7 +323,6 @@
</span> </span>
</td> </td>
</td>
<td class="text-right no-wrap" style="vertical-align: bottom"> <td class="text-right no-wrap" style="vertical-align: bottom">
<button ng-show="!isMe(user)" class="btn btn-xs btn-default" ng-click="sendInvite(user)" title="Send invitation email"><i class="fa fa-paper-plane-o"></i></button> <button ng-show="!isMe(user)" class="btn btn-xs btn-default" ng-click="sendInvite(user)" title="Send invitation email"><i class="fa fa-paper-plane-o"></i></button>
<button class="btn btn-xs btn-default" ng-click="useredit.show(user)" title="Edit User"><i class="fa fa-pencil"></i></button> <button class="btn btn-xs btn-default" ng-click="useredit.show(user)" title="Edit User"><i class="fa fa-pencil"></i></button>
@@ -359,6 +358,7 @@
<thead> <thead>
<tr> <tr>
<th>Name</th> <th>Name</th>
<th>Users</th>
<th style="width: 300px" class="text-right">Actions</th> <th style="width: 300px" class="text-right">Actions</th>
</tr> </tr>
</thead> </thead>
@@ -366,6 +366,9 @@
<tr ng-repeat="group in groups"> <tr ng-repeat="group in groups">
<td class="hand elide-table-cell" style="text-overflow: ellipsis; white-space: nowrap;" ng-click="groupEdit.show(group)"> <td class="hand elide-table-cell" style="text-overflow: ellipsis; white-space: nowrap;" ng-click="groupEdit.show(group)">
{{ group.name }} {{ group.name }}
</td>
<td class="hand elide-table-cell" style="text-overflow: ellipsis; white-space: nowrap;" ng-click="groupEdit.show(group)">
{{ groupMembers(group) }}
</td> </td>
<td class="text-right" style="vertical-align: bottom"> <td class="text-right" style="vertical-align: bottom">
<button class="btn btn-xs btn-default" ng-click="groupEdit.show(group)" title="Edit Group"><i class="fa fa-pencil"></i></button> <button class="btn btn-xs btn-default" ng-click="groupEdit.show(group)" title="Edit Group"><i class="fa fa-pencil"></i></button>

View File

@@ -14,6 +14,10 @@ angular.module('Application').controller('UsersController', ['$scope', '$locatio
$scope.config = Client.getConfig(); $scope.config = Client.getConfig();
$scope.userInfo = Client.getUserInfo(); $scope.userInfo = Client.getUserInfo();
$scope.groupMembers = function (group) {
return group.userIds.map(function (uid) { return $scope.usersById[uid].username || $scope.usersById[uid].email; }).join(', ');
};
$scope.userremove = { $scope.userremove = {
busy: false, busy: false,
error: {}, error: {},