Merge pull request #1522 from coreos-inc/fix-team-list
Fix teams list in entity search
This commit is contained in:
commit
a4aa5cc02a
1 changed files with 4 additions and 2 deletions
|
@ -78,7 +78,9 @@ angular.module('quay').directive('entitySearch', function () {
|
||||||
// Note: We load the org here again so that we always have the fully up-to-date
|
// Note: We load the org here again so that we always have the fully up-to-date
|
||||||
// teams list.
|
// teams list.
|
||||||
ApiService.getOrganization(null, {'orgname': $scope.namespace}).then(function(resp) {
|
ApiService.getOrganization(null, {'orgname': $scope.namespace}).then(function(resp) {
|
||||||
$scope.teams = resp.teams;
|
$scope.teams = Object.keys(resp.teams).map(function(key) {
|
||||||
|
return resp.teams[key];
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -113,7 +115,7 @@ angular.module('quay').directive('entitySearch', function () {
|
||||||
|
|
||||||
$scope.handleTeamCreated = function(created) {
|
$scope.handleTeamCreated = function(created) {
|
||||||
$scope.setEntity(created.name, 'team', false, created.avatar);
|
$scope.setEntity(created.name, 'team', false, created.avatar);
|
||||||
$scope.teams[created.name] = created;
|
$scope.teams.push(created);
|
||||||
};
|
};
|
||||||
|
|
||||||
$scope.handleRobotCreated = function(created) {
|
$scope.handleRobotCreated = function(created) {
|
||||||
|
|
Reference in a new issue