diff --git a/forms/common-themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js b/forms/common-themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js index b55fe2dd10..f7968a0357 100755 --- a/forms/common-themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js +++ b/forms/common-themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js @@ -266,6 +266,21 @@ module.controller('UserListCtrl', function($scope, realm, User, UserImpersonatio }); +module.controller('UserTabCtrl', function($scope, $location, Dialog, Notifications, Current) { + $scope.removeUser = function() { + Dialog.confirmDelete($scope.user.id, 'user', function() { + $scope.user.$remove({ + realm : Current.realm.realm, + userId : $scope.user.id + }, function() { + $location.url("/realms/" + Current.realm.realm + "/users"); + Notifications.success("The user has been deleted."); + }, function() { + Notifications.error("User couldn't be deleted"); + }); + }); + }; +}); module.controller('UserDetailCtrl', function($scope, realm, user, User, UserFederationInstances, UserImpersonation, RequiredActions, $location, Dialog, Notifications) { $scope.realm = realm; @@ -396,20 +411,6 @@ module.controller('UserDetailCtrl', function($scope, realm, user, User, UserFede $scope.cancel = function() { $location.url("/realms/" + realm.realm + "/users"); }; - - $scope.remove = function() { - Dialog.confirmDelete($scope.user.id, 'user', function() { - $scope.user.$remove({ - realm : realm.realm, - userId : $scope.user.id - }, function() { - $location.url("/realms/" + realm.realm + "/users"); - Notifications.success("The user has been deleted."); - }, function() { - Notifications.error("User couldn't be deleted"); - }); - }); - }; }); module.controller('UserCredentialsCtrl', function($scope, realm, user, User, UserCredentials, Notifications, Dialog) { diff --git a/forms/common-themes/src/main/resources/theme/base/admin/resources/partials/role-mappings.html b/forms/common-themes/src/main/resources/theme/base/admin/resources/partials/role-mappings.html index d12b30476d..8223936aff 100755 --- a/forms/common-themes/src/main/resources/theme/base/admin/resources/partials/role-mappings.html +++ b/forms/common-themes/src/main/resources/theme/base/admin/resources/partials/role-mappings.html @@ -4,8 +4,6 @@