From ce8dd136bdb63dd2a28cfbba794a0f655dc44f23 Mon Sep 17 00:00:00 2001 From: mposolda Date: Fri, 12 Sep 2014 20:15:11 +0200 Subject: [PATCH] Added directive kcNavigationApplication and kcNavigationOauthClient. Hide Scope and Claims for bearer-only apps --- .../theme/admin/base/resources/js/app.js | 18 ++++++++++++++++++ .../resources/partials/application-claims.html | 11 +---------- .../partials/application-credentials.html | 11 +---------- .../resources/partials/application-detail.html | 11 +---------- .../partials/application-installation.html | 11 +---------- .../partials/application-revocation.html | 11 +---------- .../partials/application-role-detail.html | 11 +---------- .../partials/application-role-list.html | 11 +---------- .../partials/application-scope-mappings.html | 11 +---------- .../partials/application-sessions.html | 11 +---------- .../partials/oauth-client-claims.html | 9 +-------- .../partials/oauth-client-credentials.html | 9 +-------- .../partials/oauth-client-detail.html | 9 +-------- .../partials/oauth-client-installation.html | 9 +-------- .../partials/oauth-client-revocation.html | 9 +-------- .../partials/oauth-client-scope-mappings.html | 9 +-------- .../templates/kc-navigation-application.html | 10 ++++++++++ .../templates/kc-navigation-oauth-client.html | 8 ++++++++ 18 files changed, 51 insertions(+), 138 deletions(-) create mode 100644 forms/common-themes/src/main/resources/theme/admin/base/resources/templates/kc-navigation-application.html create mode 100644 forms/common-themes/src/main/resources/theme/admin/base/resources/templates/kc-navigation-oauth-client.html diff --git a/forms/common-themes/src/main/resources/theme/admin/base/resources/js/app.js b/forms/common-themes/src/main/resources/theme/admin/base/resources/js/app.js index 4facb4729d..85e2872fb0 100755 --- a/forms/common-themes/src/main/resources/theme/admin/base/resources/js/app.js +++ b/forms/common-themes/src/main/resources/theme/admin/base/resources/js/app.js @@ -1121,6 +1121,24 @@ module.directive('kcNavigation', function ($compile, Notifications) { } }); +module.directive('kcNavigationApplication', function () { + return { + scope: true, + restrict: 'E', + replace: true, + templateUrl: 'templates/kc-navigation-application.html', + } +}); + +module.directive('kcNavigationOauthClient', function () { + return { + scope: true, + restrict: 'E', + replace: true, + templateUrl: 'templates/kc-navigation-oauth-client.html', + } +}); + /* * Used to select the element (invoke $(elem).select()) on specified action list. * Usages kc-select-action="click mouseover" diff --git a/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/application-claims.html b/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/application-claims.html index 6d09cfdc93..64253df59c 100755 --- a/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/application-claims.html +++ b/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/application-claims.html @@ -1,15 +1,6 @@
- +