From c65031eea5c5747acb1dfdd15be369b85f15f189 Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Wed, 29 Oct 2014 14:21:08 -0400 Subject: [PATCH] Add a throbber when loading repo permissions --- static/js/controllers.js | 3 ++- static/partials/repo-admin.html | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/static/js/controllers.js b/static/js/controllers.js index d28181b7c..aa02ed388 100644 --- a/static/js/controllers.js +++ b/static/js/controllers.js @@ -1330,7 +1330,7 @@ function RepoAdminCtrl($scope, Restangular, ApiService, KeyService, TriggerServi var name = $routeParams.name; $scope.Features = Features; - $scope.permissions = {'team': [], 'user': []}; + $scope.permissions = {'team': [], 'user': [], 'loading': 2}; $scope.logsShown = 0; $scope.deleting = false; @@ -1680,6 +1680,7 @@ function RepoAdminCtrl($scope, Restangular, ApiService, KeyService, TriggerServi var permissionsFetch = Restangular.one('repository/' + namespace + '/' + name + '/permissions/' + kind + '/'); permissionsFetch.get().then(function(resp) { $scope.permissions[kind] = resp.permissions; + $scope.permissions['loading']--; }, function() { $scope.permissions[kind] = null; }); diff --git a/static/partials/repo-admin.html b/static/partials/repo-admin.html index aa0e008d3..748f35715 100644 --- a/static/partials/repo-admin.html +++ b/static/partials/repo-admin.html @@ -92,8 +92,9 @@
- - + + +
User/Team/Robot Account