Abstract out the display of entities (users, robot accounts, and teams) into a nice directive to ensure that we always display the correctly formatted entity information (icon and name)
This commit is contained in:
parent
72acc8769b
commit
d5c0f768c2
8 changed files with 63 additions and 35 deletions
|
@ -427,16 +427,6 @@ function RepoAdminCtrl($scope, Restangular, $routeParams, $rootScope) {
|
|||
|
||||
$scope.permissions = {'team': [], 'user': []};
|
||||
|
||||
$scope.getPrefix = function(name) {
|
||||
var plus = name.indexOf('+');
|
||||
return name.substr(0, plus + 1);
|
||||
};
|
||||
|
||||
$scope.getShortenedName = function(name) {
|
||||
var plus = name.indexOf('+');
|
||||
return name.substr(plus + 1);
|
||||
};
|
||||
|
||||
$scope.grantRole = function() {
|
||||
$('#confirmaddoutsideModal').modal('hide');
|
||||
var entity = $scope.currentAddEntity;
|
||||
|
|
Reference in a new issue