From b920c7b2c435ad7f3ca04dc54e96a242d7816183 Mon Sep 17 00:00:00 2001 From: Stan Silvert Date: Mon, 14 Nov 2016 15:11:22 -0500 Subject: [PATCH] KEYCLOAK-3905: Role selector sometimes displayed when client full scope enabled --- .../theme/base/admin/resources/js/controllers/clients.js | 6 +++++- .../admin/resources/partials/client-scope-mappings.html | 4 ++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js b/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js index 624e9a5733..564313c860 100755 --- a/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js +++ b/themes/src/main/resources/theme/base/admin/resources/js/controllers/clients.js @@ -1352,7 +1352,11 @@ module.controller('ClientScopeMappingCtrl', function($scope, $http, realm, clien } - + $scope.hideRoleSelector = function() { + return ($scope.client.useTemplateScope && $scope.template && template.fullScopeAllowed) + || (!$scope.template && $scope.client.fullScopeAllowed); + } + $scope.changeFlag = function() { Client.update({ realm : realm.realm, diff --git a/themes/src/main/resources/theme/base/admin/resources/partials/client-scope-mappings.html b/themes/src/main/resources/theme/base/admin/resources/partials/client-scope-mappings.html index 47ab627fbd..fc10e6bf66 100755 --- a/themes/src/main/resources/theme/base/admin/resources/partials/client-scope-mappings.html +++ b/themes/src/main/resources/theme/base/admin/resources/partials/client-scope-mappings.html @@ -41,7 +41,7 @@ -
+
@@ -132,6 +132,6 @@
- + \ No newline at end of file