KEYCLOAK-9387: Add hor scroll & tooltips to role selectors

This commit is contained in:
Stan Silvert 2019-02-01 09:11:42 -05:00 committed by Pavel Drozd
parent 22e160136c
commit 9e16c772bd
19 changed files with 450 additions and 267 deletions

View file

@ -31,7 +31,7 @@ public final class UIUtils {
public static boolean selectContainsOption(Select select, String optionText) { public static boolean selectContainsOption(Select select, String optionText) {
for (WebElement option : select.getOptions()) { for (WebElement option : select.getOptions()) {
if (option.getText().equals(optionText)) { if (option.getText().trim().equals(optionText)) {
return true; return true;
} }
} }

View file

@ -93,7 +93,7 @@ public class ClientScopesSetupForm extends Form {
static Set<String> getSelectValues(Select select) { static Set<String> getSelectValues(Select select) {
Set<String> roles = new HashSet<>(); Set<String> roles = new HashSet<>();
for (WebElement option : select.getOptions()) { for (WebElement option : select.getOptions()) {
roles.add(getTextFromElement(option)); roles.add(getTextFromElement(option).trim());
} }
return roles; return roles;
} }

View file

@ -676,7 +676,7 @@ module.controller('ClientOfflineSessionsCtrl', function($scope, realm, offlineSe
module.controller('ClientRoleDetailCtrl', function($scope, realm, client, role, roles, clients, module.controller('ClientRoleDetailCtrl', function($scope, realm, client, role, roles, clients,
Role, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites, Role, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites,
$http, $location, Dialog, Notifications) { $http, $location, Dialog, Notifications, ComponentUtils) {
$scope.realm = realm; $scope.realm = realm;
$scope.client = client; $scope.client = client;
$scope.role = angular.copy(role); $scope.role = angular.copy(role);
@ -754,7 +754,7 @@ module.controller('ClientRoleDetailCtrl', function($scope, realm, client, role,
roleControl($scope, realm, role, roles, clients, roleControl($scope, realm, role, roles, clients,
ClientRole, RoleById, RoleRealmComposites, RoleClientComposites, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites,
$http, $location, Notifications, Dialog); $http, $location, Notifications, Dialog, ComponentUtils);
}); });
@ -1610,41 +1610,45 @@ module.controller('ClientScopeMappingCtrl', function($scope, $http, realm, clien
}; };
$scope.addRealmRole = function() { $scope.addRealmRole = function() {
var roles = $scope.selectedRealmRoles; $scope.selectedRealmRolesToAdd = JSON.parse('[' + $scope.selectedRealmRoles + ']');
$scope.selectedRealmRoles = []; $scope.selectedRealmRoles = [];
$http.post(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/realm', $http.post(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/realm',
roles).then(function() { $scope.selectedRealmRolesToAdd).then(function() {
updateRealmRoles(); updateRealmRoles();
$scope.selectedRealmRolesToAdd = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
$scope.deleteRealmRole = function() { $scope.deleteRealmRole = function() {
var roles = $scope.selectedRealmMappings; $scope.selectedRealmMappingsToRemove = JSON.parse('[' + $scope.selectedRealmMappings + ']');
$scope.selectedRealmMappings = []; $scope.selectedRealmMappings = [];
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/realm', $http.delete(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/realm',
{data : roles, headers : {"content-type" : "application/json"}}).then(function () { {data : $scope.selectedRealmMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function () {
updateRealmRoles(); updateRealmRoles();
$scope.selectedRealmMappingsToRemove = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
$scope.addClientRole = function() { $scope.addClientRole = function() {
var roles = $scope.selectedClientRoles; $scope.selectedClientRolesToAdd = JSON.parse('[' + $scope.selectedClientRoles + ']');
$scope.selectedClientRoles = []; $scope.selectedClientRoles = [];
$http.post(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/clients/' + $scope.targetClient.id, $http.post(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/clients/' + $scope.targetClient.id,
roles).then(function () { $scope.selectedClientRolesToAdd).then(function () {
updateClientRoles(); updateClientRoles();
$scope.selectedClientRolesToAdd = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
$scope.deleteClientRole = function() { $scope.deleteClientRole = function() {
var roles = $scope.selectedClientMappings; $scope.selectedClientMappingsToRemove = JSON.parse('[' + $scope.selectedClientMappings + ']');
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/clients/' + $scope.targetClient.id, $http.delete(authUrl + '/admin/realms/' + realm.realm + '/clients/' + client.id + '/scope-mappings/clients/' + $scope.targetClient.id,
{data : roles, headers : {"content-type" : "application/json"}}).then(function () { {data : $scope.selectedClientMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function () {
updateClientRoles(); updateClientRoles();
$scope.selectedClientMappingsToRemove = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
@ -2125,11 +2129,11 @@ module.controller('ClientClientScopesSetupCtrl', function($scope, realm, Realm,
} }
$scope.addDefaultClientScope = function () { $scope.addDefaultClientScope = function () {
$scope.selectedDefaultClientScopesToAdd = JSON.parse('[' + $scope.selectedDefaultClientScopes + ']');
toAdd = $scope.selectedDefaultClientScopesToAdd.length;
toAdd = $scope.selectedDefaultClientScopes.length; for (var i = 0; i < $scope.selectedDefaultClientScopesToAdd.length; i++) {
var currentScope = $scope.selectedDefaultClientScopesToAdd[i];
for (var i = 0; i < $scope.selectedDefaultClientScopes.length; i++) {
var currentScope = $scope.selectedDefaultClientScopes[i];
ClientDefaultClientScopes.update({ ClientDefaultClientScopes.update({
realm : realm.realm, realm : realm.realm,
@ -2143,14 +2147,15 @@ module.controller('ClientClientScopesSetupCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedDefaultClientScopesToAdd = [];
}; };
$scope.deleteDefaultClientScope = function () { $scope.deleteDefaultClientScope = function () {
$scope.selectedDefDefaultClientScopesToRemove = JSON.parse('[' + $scope.selectedDefDefaultClientScopes + ']');
toRemove = $scope.selectedDefDefaultClientScopesToRemove.length;
toRemove = $scope.selectedDefDefaultClientScopes.length; for (var i = 0; i < $scope.selectedDefDefaultClientScopesToRemove.length; i++) {
var currentScope = $scope.selectedDefDefaultClientScopesToRemove[i];
for (var i = 0; i < $scope.selectedDefDefaultClientScopes.length; i++) {
var currentScope = $scope.selectedDefDefaultClientScopes[i];
ClientDefaultClientScopes.remove({ ClientDefaultClientScopes.remove({
realm : realm.realm, realm : realm.realm,
@ -2164,14 +2169,15 @@ module.controller('ClientClientScopesSetupCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedDefDefaultClientScopesToRemove = [];
}; };
$scope.addOptionalClientScope = function () { $scope.addOptionalClientScope = function () {
$scope.selectedOptionalClientScopesToAdd = JSON.parse('[' + $scope.selectedOptionalClientScopes + ']');
toAdd = $scope.selectedOptionalClientScopesToAdd.length;
toAdd = $scope.selectedOptionalClientScopes.length; for (var i = 0; i < $scope.selectedOptionalClientScopesToAdd.length; i++) {
var currentScope = $scope.selectedOptionalClientScopesToAdd[i];
for (var i = 0; i < $scope.selectedOptionalClientScopes.length; i++) {
var currentScope = $scope.selectedOptionalClientScopes[i];
ClientOptionalClientScopes.update({ ClientOptionalClientScopes.update({
realm : realm.realm, realm : realm.realm,
@ -2188,11 +2194,11 @@ module.controller('ClientClientScopesSetupCtrl', function($scope, realm, Realm,
}; };
$scope.deleteOptionalClientScope = function () { $scope.deleteOptionalClientScope = function () {
$scope.selectedDefOptionalClientScopesToRemove = JSON.parse('[' + $scope.selectedDefOptionalClientScopes + ']');
toRemove = $scope.selectedDefOptionalClientScopesToRemove.length;
toRemove = $scope.selectedDefOptionalClientScopes.length; for (var i = 0; i < $scope.selectedDefOptionalClientScopesToRemove.length; i++) {
var currentScope = $scope.selectedDefOptionalClientScopesToRemove[i];
for (var i = 0; i < $scope.selectedDefOptionalClientScopes.length; i++) {
var currentScope = $scope.selectedDefOptionalClientScopes[i];
ClientOptionalClientScopes.remove({ ClientOptionalClientScopes.remove({
realm : realm.realm, realm : realm.realm,
@ -2206,13 +2212,14 @@ module.controller('ClientClientScopesSetupCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedDefOptionalClientScopesToRemove = [];
}; };
}); });
module.controller('ClientClientScopesEvaluateCtrl', function($scope, Realm, User, ClientEvaluateProtocolMappers, ClientEvaluateGrantedRoles, module.controller('ClientClientScopesEvaluateCtrl', function($scope, Realm, User, ClientEvaluateProtocolMappers, ClientEvaluateGrantedRoles,
ClientEvaluateNotGrantedRoles, ClientEvaluateGenerateExampleToken, realm, client, clients, clientScopes, serverInfo, ClientEvaluateNotGrantedRoles, ClientEvaluateGenerateExampleToken, realm, client, clients, clientScopes, serverInfo,
clientOptionalClientScopes, clientDefaultClientScopes, $route, $routeParams, $http, Notifications, $location) { ComponentUtils, clientOptionalClientScopes, clientDefaultClientScopes, $route, $routeParams, $http, Notifications, $location) {
console.log('ClientClientScopesEvaluateCtrl'); console.log('ClientClientScopesEvaluateCtrl');
@ -2279,37 +2286,38 @@ module.controller('ClientClientScopesEvaluateCtrl', function($scope, Realm, User
$scope.addAppliedClientScope = function () { $scope.addAppliedClientScope = function () {
$scope.selectedClientScopesToAdd = JSON.parse('[' + $scope.selectedClientScopes + ']');
for (var i = 0; i < $scope.selectedClientScopes.length; i++) { for (var i = 0; i < $scope.selectedClientScopesToAdd.length; i++) {
var currentScope = $scope.selectedClientScopes[i]; var currentScope = $scope.selectedClientScopesToAdd[i];
$scope.assignedClientScopes.push(currentScope); $scope.assignedClientScopes.push(currentScope);
var index = $scope.availableClientScopes.indexOf(currentScope); var index = ComponentUtils.findIndexById($scope.availableClientScopes, currentScope.id);
if (index > -1) { if (index > -1) {
$scope.availableClientScopes.splice(index, 1); $scope.availableClientScopes.splice(index, 1);
} }
} }
$scope.selectedClientScopes = []; $scope.selectedClientScopes = [];
$scope.selectedClientScopesToAdd = [];
updateState(); updateState();
}; };
$scope.deleteAppliedClientScope = function () { $scope.deleteAppliedClientScope = function () {
for (var i = 0; i < $scope.selectedDefClientScopes.length; i++) { $scope.selectedDefClientScopesToRemove = JSON.parse('[' + $scope.selectedDefClientScopes + ']');
var currentScope = $scope.selectedDefClientScopes[i]; for (var i = 0; i < $scope.selectedDefClientScopesToRemove.length; i++) {
var currentScope = $scope.selectedDefClientScopesToRemove[i];
$scope.availableClientScopes.push(currentScope); $scope.availableClientScopes.push(currentScope);
var index = $scope.assignedClientScopes.indexOf(currentScope); var index = ComponentUtils.findIndexById($scope.assignedClientScopes, currentScope.id);
if (index > -1) { if (index > -1) {
$scope.assignedClientScopes.splice(index, 1); $scope.assignedClientScopes.splice(index, 1);
} }
} }
$scope.selectedDefClientScopes = []; $scope.selectedDefClientScopes = [];
$scope.selectedDefClientScopesToRemove = [];
updateState(); updateState();
}; };
@ -2538,11 +2546,11 @@ module.controller('ClientScopesRealmDefaultCtrl', function($scope, realm, Realm,
} }
$scope.addDefaultClientScope = function () { $scope.addDefaultClientScope = function () {
$scope.selectedDefaultClientScopesToAdd = JSON.parse('[' + $scope.selectedDefaultClientScopes + ']');
toAdd = $scope.selectedDefaultClientScopesToAdd.length;
toAdd = $scope.selectedDefaultClientScopes.length; for (var i = 0; i < $scope.selectedDefaultClientScopesToAdd.length; i++) {
var currentScope = $scope.selectedDefaultClientScopesToAdd[i];
for (var i = 0; i < $scope.selectedDefaultClientScopes.length; i++) {
var currentScope = $scope.selectedDefaultClientScopes[i];
RealmDefaultClientScopes.update({ RealmDefaultClientScopes.update({
realm : realm.realm, realm : realm.realm,
@ -2556,14 +2564,15 @@ module.controller('ClientScopesRealmDefaultCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedDefaultClientScopesToAdd = [];
}; };
$scope.deleteDefaultClientScope = function () { $scope.deleteDefaultClientScope = function () {
$scope.selectedDefDefaultClientScopesToRemove = JSON.parse('[' + $scope.selectedDefDefaultClientScopes + ']');
toRemove = $scope.selectedDefDefaultClientScopesToRemove.length;
toRemove = $scope.selectedDefDefaultClientScopes.length; for (var i = 0; i < $scope.selectedDefDefaultClientScopesToRemove.length; i++) {
var currentScope = $scope.selectedDefDefaultClientScopesToRemove[i];
for (var i = 0; i < $scope.selectedDefDefaultClientScopes.length; i++) {
var currentScope = $scope.selectedDefDefaultClientScopes[i];
RealmDefaultClientScopes.remove({ RealmDefaultClientScopes.remove({
realm : realm.realm, realm : realm.realm,
@ -2576,14 +2585,15 @@ module.controller('ClientScopesRealmDefaultCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedDefDefaultClientScopesToRemove = [];
}; };
$scope.addOptionalClientScope = function () { $scope.addOptionalClientScope = function () {
$scope.selectedOptionalClientScopesToAdd = JSON.parse('[' + $scope.selectedOptionalClientScopes + ']');
toAdd = $scope.selectedOptionalClientScopesToAdd.length;
toAdd = $scope.selectedOptionalClientScopes.length; for (var i = 0; i < $scope.selectedOptionalClientScopesToAdd.length; i++) {
var currentScope = $scope.selectedOptionalClientScopesToAdd[i];
for (var i = 0; i < $scope.selectedOptionalClientScopes.length; i++) {
var currentScope = $scope.selectedOptionalClientScopes[i];
RealmOptionalClientScopes.update({ RealmOptionalClientScopes.update({
realm : realm.realm, realm : realm.realm,
@ -2597,14 +2607,15 @@ module.controller('ClientScopesRealmDefaultCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedOptionalClientScopesToAdd = [];
}; };
$scope.deleteOptionalClientScope = function () { $scope.deleteOptionalClientScope = function () {
$scope.selectedDefOptionalClientScopesToRemove = JSON.parse('[' + $scope.selectedDefOptionalClientScopes + ']');
toRemove = $scope.selectedDefOptionalClientScopesToRemove.length;
toRemove = $scope.selectedDefOptionalClientScopes.length; for (var i = 0; i < $scope.selectedDefOptionalClientScopesToRemove.length; i++) {
var currentScope = $scope.selectedDefOptionalClientScopesToRemove[i];
for (var i = 0; i < $scope.selectedDefOptionalClientScopes.length; i++) {
var currentScope = $scope.selectedDefOptionalClientScopes[i];
RealmOptionalClientScopes.remove({ RealmOptionalClientScopes.remove({
realm : realm.realm, realm : realm.realm,
@ -2617,6 +2628,7 @@ module.controller('ClientScopesRealmDefaultCtrl', function($scope, realm, Realm,
} }
}); });
} }
$scope.selectedDefOptionalClientScopesToRemove = [];
}; };
}); });
@ -3015,41 +3027,45 @@ module.controller('ClientScopeScopeMappingCtrl', function($scope, $http, realm,
}; };
$scope.addRealmRole = function() { $scope.addRealmRole = function() {
var roles = $scope.selectedRealmRoles; $scope.selectedRealmRolesToAdd = JSON.parse('[' + $scope.selectedRealmRoles + ']');
$scope.selectedRealmRoles = []; $scope.selectedRealmRoles = [];
$http.post(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/realm', $http.post(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/realm',
roles).then(function() { $scope.selectedRealmRolesToAdd).then(function() {
updateScopeRealmRoles(); updateScopeRealmRoles();
$scope.selectedRealmRolesToAdd = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
$scope.deleteRealmRole = function() { $scope.deleteRealmRole = function() {
var roles = $scope.selectedRealmMappings; $scope.selectedRealmMappingsToRemove = JSON.parse('[' + $scope.selectedRealmMappings + ']');
$scope.selectedRealmMappings = []; $scope.selectedRealmMappings = [];
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/realm', $http.delete(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/realm',
{data : roles, headers : {"content-type" : "application/json"}}).then(function () { {data : $scope.selectedRealmMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function () {
updateScopeRealmRoles(); updateScopeRealmRoles();
$scope.selectedRealmMappingsToRemove = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
$scope.addClientRole = function() { $scope.addClientRole = function() {
var roles = $scope.selectedClientRoles; $scope.selectedClientRolesToAdd = JSON.parse('[' + $scope.selectedClientRoles + ']');
$scope.selectedClientRoles = []; $scope.selectedClientRoles = [];
$http.post(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/clients/' + $scope.targetClient.id, $http.post(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/clients/' + $scope.targetClient.id,
roles).then(function () { $scope.selectedClientRolesToAdd).then(function () {
updateScopeClientRoles(); updateScopeClientRoles();
$scope.selectedClientRolesToAdd = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };
$scope.deleteClientRole = function() { $scope.deleteClientRole = function() {
var roles = $scope.selectedClientMappings; $scope.selectedClientMappingsToRemove = JSON.parse('[' + $scope.selectedClientMappings + ']');
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/clients/' + $scope.targetClient.id, $http.delete(authUrl + '/admin/realms/' + realm.realm + '/client-scopes/' + clientScope.id + '/scope-mappings/clients/' + $scope.targetClient.id,
{data : roles, headers : {"content-type" : "application/json"}}).then(function () { {data : $scope.selectedClientMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function () {
updateScopeClientRoles(); updateScopeClientRoles();
$scope.selectedClientMappingsToRemove = [];
Notifications.success("Scope mappings updated."); Notifications.success("Scope mappings updated.");
}); });
}; };

View file

@ -313,10 +313,10 @@ module.controller('GroupRoleMappingCtrl', function($scope, $http, realm, group,
$scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.addRealmRole = function() { $scope.addRealmRole = function() {
var roles = $scope.selectedRealmRoles; $scope.selectedRealmRolesToAdd = JSON.parse('[' + $scope.selectedRealmRoles + ']');
$scope.selectedRealmRoles = []; $scope.selectedRealmRoles = [];
$http.post(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/realm', $http.post(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/realm',
roles).then(function() { $scope.selectedRealmRolesToAdd).then(function() {
$scope.realmMappings = GroupRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmMappings = GroupRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
@ -330,14 +330,16 @@ module.controller('GroupRoleMappingCtrl', function($scope, $http, realm, group,
$scope.selectedClientRoles = []; $scope.selectedClientRoles = [];
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
} }
$scope.selectedRealmRolesToAdd = [];
Notifications.success("Role mappings updated."); Notifications.success("Role mappings updated.");
}); });
}; };
$scope.deleteRealmRole = function() { $scope.deleteRealmRole = function() {
$scope.selectedRealmMappingsToRemove = JSON.parse('[' + $scope.selectedRealmMappings + ']');
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/realm', $http.delete(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/realm',
{data : $scope.selectedRealmMappings, headers : {"content-type" : "application/json"}}).then(function() { {data : $scope.selectedRealmMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function() {
$scope.realmMappings = GroupRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmMappings = GroupRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
@ -351,13 +353,15 @@ module.controller('GroupRoleMappingCtrl', function($scope, $http, realm, group,
$scope.selectedClientRoles = []; $scope.selectedClientRoles = [];
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
} }
$scope.selectedRealmMappingsToRemove = [];
Notifications.success("Role mappings updated."); Notifications.success("Role mappings updated.");
}); });
}; };
$scope.addClientRole = function() { $scope.addClientRole = function() {
$scope.selectedClientRolesToAdd = JSON.parse('[' + $scope.selectedClientRoles + ']');
$http.post(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/clients/' + $scope.targetClient.id, $http.post(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/clients/' + $scope.targetClient.id,
$scope.selectedClientRoles).then(function() { $scope.selectedClientRolesToAdd).then(function() {
$scope.clientMappings = GroupClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id}); $scope.clientMappings = GroupClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id});
$scope.clientRoles = GroupAvailableClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id}); $scope.clientRoles = GroupAvailableClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id});
$scope.clientComposite = GroupCompositeClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id}); $scope.clientComposite = GroupCompositeClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id});
@ -365,13 +369,15 @@ module.controller('GroupRoleMappingCtrl', function($scope, $http, realm, group,
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
$scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.selectedClientRolesToAdd = [];
Notifications.success("Role mappings updated."); Notifications.success("Role mappings updated.");
}); });
}; };
$scope.deleteClientRole = function() { $scope.deleteClientRole = function() {
$scope.selectedClientMappingsToRemove = JSON.parse('[' + $scope.selectedClientMappings + ']');
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/clients/' + $scope.targetClient.id, $http.delete(authUrl + '/admin/realms/' + realm.realm + '/groups/' + group.id + '/role-mappings/clients/' + $scope.targetClient.id,
{data : $scope.selectedClientMappings, headers : {"content-type" : "application/json"}}).then(function() { {data : $scope.selectedClientMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function() {
$scope.clientMappings = GroupClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id}); $scope.clientMappings = GroupClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id});
$scope.clientRoles = GroupAvailableClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id}); $scope.clientRoles = GroupAvailableClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id});
$scope.clientComposite = GroupCompositeClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id}); $scope.clientComposite = GroupCompositeClientRoleMapping.query({realm : realm.realm, groupId : group.id, client : $scope.targetClient.id});
@ -379,6 +385,7 @@ module.controller('GroupRoleMappingCtrl', function($scope, $http, realm, group,
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
$scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmComposite = GroupCompositeRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id}); $scope.realmRoles = GroupAvailableRealmRoleMapping.query({realm : realm.realm, groupId : group.id});
$scope.selectedClientMappingsToRemove = [];
Notifications.success("Role mappings updated."); Notifications.success("Role mappings updated.");
}); });
}; };

View file

@ -1461,7 +1461,7 @@ module.controller('RoleListCtrl', function($scope, $route, Dialog, Notifications
module.controller('RoleDetailCtrl', function($scope, realm, role, roles, clients, module.controller('RoleDetailCtrl', function($scope, realm, role, roles, clients,
Role, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites, Role, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites,
$http, $location, Dialog, Notifications, RealmRoleRemover) { $http, $location, Dialog, Notifications, RealmRoleRemover, ComponentUtils) {
$scope.realm = realm; $scope.realm = realm;
$scope.role = angular.copy(role); $scope.role = angular.copy(role);
$scope.create = !role.name; $scope.create = !role.name;
@ -1530,7 +1530,7 @@ module.controller('RoleDetailCtrl', function($scope, realm, role, roles, clients
roleControl($scope, realm, role, roles, clients, roleControl($scope, realm, role, roles, clients,
ClientRole, RoleById, RoleRealmComposites, RoleClientComposites, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites,
$http, $location, Notifications, Dialog); $http, $location, Notifications, Dialog, ComponentUtils);
}); });
module.controller('RealmSMTPSettingsCtrl', function($scope, Current, Realm, realm, $http, $location, Dialog, Notifications, RealmSMTPConnectionTester) { module.controller('RealmSMTPSettingsCtrl', function($scope, Current, Realm, realm, $http, $location, Dialog, Notifications, RealmSMTPConnectionTester) {

View file

@ -20,10 +20,10 @@ module.controller('UserRoleMappingCtrl', function($scope, $http, realm, user, cl
$scope.realmComposite = CompositeRealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmComposite = CompositeRealmRoleMapping.query({realm : realm.realm, userId : user.id});
$scope.addRealmRole = function() { $scope.addRealmRole = function() {
var roles = $scope.selectedRealmRoles; $scope.realmRolesToAdd = JSON.parse('[' + $scope.selectedRealmRoles + ']');
$scope.selectedRealmRoles = []; $scope.selectedRealmRoles = [];
$http.post(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/realm', $http.post(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/realm',
roles).then(function() { $scope.realmRolesToAdd).then(function() {
$scope.realmMappings = RealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmMappings = RealmRoleMapping.query({realm : realm.realm, userId : user.id});
$scope.realmRoles = AvailableRealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmRoles = AvailableRealmRoleMapping.query({realm : realm.realm, userId : user.id});
$scope.realmComposite = CompositeRealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmComposite = CompositeRealmRoleMapping.query({realm : realm.realm, userId : user.id});
@ -43,8 +43,9 @@ module.controller('UserRoleMappingCtrl', function($scope, $http, realm, user, cl
}; };
$scope.deleteRealmRole = function() { $scope.deleteRealmRole = function() {
$scope.realmRolesToRemove = JSON.parse('[' + $scope.selectedRealmMappings + ']');
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/realm', $http.delete(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/realm',
{data : $scope.selectedRealmMappings, headers : {"content-type" : "application/json"}}).then(function() { {data : $scope.realmRolesToRemove, headers : {"content-type" : "application/json"}}).then(function() {
$scope.realmMappings = RealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmMappings = RealmRoleMapping.query({realm : realm.realm, userId : user.id});
$scope.realmRoles = AvailableRealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmRoles = AvailableRealmRoleMapping.query({realm : realm.realm, userId : user.id});
$scope.realmComposite = CompositeRealmRoleMapping.query({realm : realm.realm, userId : user.id}); $scope.realmComposite = CompositeRealmRoleMapping.query({realm : realm.realm, userId : user.id});
@ -63,8 +64,9 @@ module.controller('UserRoleMappingCtrl', function($scope, $http, realm, user, cl
}; };
$scope.addClientRole = function() { $scope.addClientRole = function() {
$scope.clientRolesToAdd = JSON.parse('[' + $scope.selectedClientRoles + ']');
$http.post(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/clients/' + $scope.targetClient.id, $http.post(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/clients/' + $scope.targetClient.id,
$scope.selectedClientRoles).then(function() { $scope.clientRolesToAdd).then(function() {
$scope.clientMappings = ClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id}); $scope.clientMappings = ClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id});
$scope.clientRoles = AvailableClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id}); $scope.clientRoles = AvailableClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id});
$scope.clientComposite = CompositeClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id}); $scope.clientComposite = CompositeClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id});
@ -77,8 +79,9 @@ module.controller('UserRoleMappingCtrl', function($scope, $http, realm, user, cl
}; };
$scope.deleteClientRole = function() { $scope.deleteClientRole = function() {
$scope.clientRolesToRemove = JSON.parse('[' + $scope.selectedClientMappings + ']');
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/clients/' + $scope.targetClient.id, $http.delete(authUrl + '/admin/realms/' + realm.realm + '/users/' + user.id + '/role-mappings/clients/' + $scope.targetClient.id,
{data : $scope.selectedClientMappings, headers : {"content-type" : "application/json"}}).then(function() { {data : $scope.clientRolesToRemove, headers : {"content-type" : "application/json"}}).then(function() {
$scope.clientMappings = ClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id}); $scope.clientMappings = ClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id});
$scope.clientRoles = AvailableClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id}); $scope.clientRoles = AvailableClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id});
$scope.clientComposite = CompositeClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id}); $scope.clientComposite = CompositeClientRoleMapping.query({realm : realm.realm, userId : user.id, client : $scope.targetClient.id});

View file

@ -196,6 +196,13 @@ module.factory('ComponentUtils', function() {
var utils = {}; var utils = {};
utils.findIndexById = function(array, id) {
for (var i = 0; i < array.length; i++) {
if (array[i].id === id) return i;
}
return -1;
}
utils.addLastEmptyValueToMultivaluedLists = function(properties, config) { utils.addLastEmptyValueToMultivaluedLists = function(properties, config) {
if (!properties) { if (!properties) {
return; return;
@ -761,7 +768,7 @@ module.factory('RoleClientComposites', function($resource) {
function roleControl($scope, realm, role, roles, clients, function roleControl($scope, realm, role, roles, clients,
ClientRole, RoleById, RoleRealmComposites, RoleClientComposites, ClientRole, RoleById, RoleRealmComposites, RoleClientComposites,
$http, $location, Notifications, Dialog) { $http, $location, Notifications, Dialog, ComponentUtils) {
$scope.$watch(function () { $scope.$watch(function () {
return $location.path(); return $location.path();
@ -833,68 +840,76 @@ function roleControl($scope, realm, role, roles, clients,
$scope.addRealmRole = function() { $scope.addRealmRole = function() {
$scope.compositeSwitchDisabled=true; $scope.compositeSwitchDisabled=true;
$scope.selectedRealmRolesToAdd = JSON.parse('[' + $scope.selectedRealmRoles + ']');
$http.post(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites', $http.post(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites',
$scope.selectedRealmRoles).then(function() { $scope.selectedRealmRolesToAdd).then(function() {
for (var i = 0; i < $scope.selectedRealmRoles.length; i++) { for (var i = 0; i < $scope.selectedRealmRolesToAdd.length; i++) {
var role = $scope.selectedRealmRoles[i]; var role = $scope.selectedRealmRolesToAdd[i];
var idx = $scope.realmRoles.indexOf($scope.selectedRealmRoles[i]); var idx = ComponentUtils.findIndexById($scope.realmRoles, role.id);
if (idx != -1) { if (idx != -1) {
$scope.realmRoles.splice(idx, 1); $scope.realmRoles.splice(idx, 1);
$scope.realmMappings.push(role); $scope.realmMappings.push(role);
} }
} }
$scope.selectedRealmRoles = []; $scope.selectedRealmRoles = [];
$scope.selectedRealmRolesToAdd = [];
Notifications.success("Role added to composite."); Notifications.success("Role added to composite.");
}); });
}; };
$scope.deleteRealmRole = function() { $scope.deleteRealmRole = function() {
$scope.compositeSwitchDisabled=true; $scope.compositeSwitchDisabled=true;
$scope.selectedRealmMappingsToRemove = JSON.parse('[' + $scope.selectedRealmMappings + ']');
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites', $http.delete(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites',
{data : $scope.selectedRealmMappings, headers : {"content-type" : "application/json"}}).then(function() { {data : $scope.selectedRealmMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function() {
for (var i = 0; i < $scope.selectedRealmMappings.length; i++) { for (var i = 0; i < $scope.selectedRealmMappingsToRemove.length; i++) {
var role = $scope.selectedRealmMappings[i]; var role = $scope.selectedRealmMappingsToRemove[i];
var idx = $scope.realmMappings.indexOf($scope.selectedRealmMappings[i]); var idx = ComponentUtils.findIndexById($scope.realmMappings, role.id);
if (idx != -1) { if (idx != -1) {
$scope.realmMappings.splice(idx, 1); $scope.realmMappings.splice(idx, 1);
$scope.realmRoles.push(role); $scope.realmRoles.push(role);
} }
} }
$scope.selectedRealmMappings = []; $scope.selectedRealmMappings = [];
$scope.selectedRealmMappingsToRemove = [];
Notifications.success("Role removed from composite."); Notifications.success("Role removed from composite.");
}); });
}; };
$scope.addClientRole = function() { $scope.addClientRole = function() {
$scope.compositeSwitchDisabled=true; $scope.compositeSwitchDisabled=true;
$scope.selectedClientRolesToAdd = JSON.parse('[' + $scope.selectedClientRoles + ']');
$http.post(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites', $http.post(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites',
$scope.selectedClientRoles).then(function() { $scope.selectedClientRolesToAdd).then(function() {
for (var i = 0; i < $scope.selectedClientRoles.length; i++) { for (var i = 0; i < $scope.selectedClientRolesToAdd.length; i++) {
var role = $scope.selectedClientRoles[i]; var role = $scope.selectedClientRolesToAdd[i];
var idx = $scope.clientRoles.indexOf($scope.selectedClientRoles[i]); var idx = ComponentUtils.findIndexById($scope.clientRoles, role.id);
if (idx != -1) { if (idx != -1) {
$scope.clientRoles.splice(idx, 1); $scope.clientRoles.splice(idx, 1);
$scope.clientMappings.push(role); $scope.clientMappings.push(role);
} }
} }
$scope.selectedClientRoles = []; $scope.selectedClientRoles = [];
$scope.selectedClientRolesToAdd = [];
Notifications.success("Client role added."); Notifications.success("Client role added.");
}); });
}; };
$scope.deleteClientRole = function() { $scope.deleteClientRole = function() {
$scope.compositeSwitchDisabled=true; $scope.compositeSwitchDisabled=true;
$scope.selectedClientMappingsToRemove = JSON.parse('[' + $scope.selectedClientMappings + ']');
$http.delete(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites', $http.delete(authUrl + '/admin/realms/' + realm.realm + '/roles-by-id/' + role.id + '/composites',
{data : $scope.selectedClientMappings, headers : {"content-type" : "application/json"}}).then(function() { {data : $scope.selectedClientMappingsToRemove, headers : {"content-type" : "application/json"}}).then(function() {
for (var i = 0; i < $scope.selectedClientMappings.length; i++) { for (var i = 0; i < $scope.selectedClientMappingsToRemove.length; i++) {
var role = $scope.selectedClientMappings[i]; var role = $scope.selectedClientMappingsToRemove[i];
var idx = $scope.clientMappings.indexOf($scope.selectedClientMappings[i]); var idx = ComponentUtils.findIndexById($scope.clientMappings, role.id);
if (idx != -1) { if (idx != -1) {
$scope.clientMappings.splice(idx, 1); $scope.clientMappings.splice(idx, 1);
$scope.clientRoles.push(role); $scope.clientRoles.push(role);
} }
} }
$scope.selectedClientMappings = []; $scope.selectedClientMappings = [];
$scope.selectedClientMappingsToRemove = [];
Notifications.success("Client role removed."); Notifications.success("Client role removed.");
}); });
}; };

View file

@ -63,10 +63,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'composite.available-realm-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'composite.available-realm-roles.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -75,10 +77,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned">{{:: 'associated-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'associated-roles' | translate}}</label>
<kc-tooltip>{{:: 'composite.associated-realm-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'composite.associated-realm-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -102,10 +106,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -114,10 +120,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned-client">{{:: 'associated-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'associated-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.associated-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.associated-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}

View file

@ -30,10 +30,12 @@
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'scope.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'scope.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -42,10 +44,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -54,10 +58,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}} </label> <label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}} </label>
<kc-tooltip>{{:: 'realm.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'realm.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="realm-composite" class="form-control" multiple size=5 <select id="realm-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in realmComposite | orderBy:'name'"> <option ng-repeat="r in realmComposite | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -78,10 +84,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'assign.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'assign.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -90,10 +98,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -102,10 +112,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="client-composite" class="form-control" multiple size=5 <select id="client-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in clientComposite | orderBy:'name'"> <option ng-repeat="r in clientComposite | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>

View file

@ -19,10 +19,12 @@
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'scope.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'scope.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -31,10 +33,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -43,10 +47,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}} </label> <label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}} </label>
<kc-tooltip>{{:: 'realm.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'realm.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="realm-composite" class="form-control" multiple size=5 <select id="realm-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in realmComposite | orderBy:'name'"> <option ng-repeat="r in realmComposite | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -67,10 +73,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'assign.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'assign.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -79,10 +87,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -91,10 +101,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="client-composite" class="form-control" multiple size=5 <select id="client-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in clientComposite | orderBy:'name'"> <option ng-repeat="r in clientComposite | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>

View file

@ -55,10 +55,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available">{{:: 'client-scopes.evaluate.scopes.available' | translate}}</label> <label class="control-label" for="available">{{:: 'client-scopes.evaluate.scopes.available' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.evaluate.scopes.available.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.scopes.available.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientScopes" ng-model="selectedClientScopes">
ng-options="r.name for r in availableClientScopes | orderBy:'toString()'"> <option ng-repeat="r in availableClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addAppliedClientScope()"> <button ng-disabled="selectedClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addAppliedClientScope()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -67,10 +70,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned">{{:: 'client-scopes.evaluate.scopes.assigned' | translate}}</label> <label class="control-label" for="assigned">{{:: 'client-scopes.evaluate.scopes.assigned' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.evaluate.scopes.assigned.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.scopes.assigned.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefClientScopes" ng-model="selectedDefClientScopes">
ng-options="r.name for r in assignedClientScopes | orderBy:'toString()'"> <option ng-repeat="r in assignedClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteAppliedClientScope()"> <button ng-disabled="selectedDefClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteAppliedClientScope()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -79,10 +85,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned">{{:: 'client-scopes.evaluate.scopes.effective' | translate}}</label> <label class="control-label" for="assigned">{{:: 'client-scopes.evaluate.scopes.effective' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.evaluate.scopes.effective.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.scopes.effective.tooltip' | translate}}</kc-tooltip>
<select id="effective" class="form-control" multiple size=5 <select id="effective" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in effectiveClientScopes | orderBy:'toString()'"> <option ng-repeat="r in effectiveClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -169,23 +178,29 @@
<label class="col-md-2 control-label" class="control-label">{{:: 'realm-roles' | translate}}</label> <label class="col-md-2 control-label" class="control-label">{{:: 'realm-roles' | translate}}</label>
<div class="col-md-10"> <div class="col-md-10">
<div class="row"> <div class="row">
<div class="col-md-3"> <div class="col-md-4">
<label class="control-label" for="available-realm-roles">{{:: 'client-scopes.evaluate.not-granted-roles' | translate}}</label> <label class="control-label" for="available-realm-roles">{{:: 'client-scopes.evaluate.not-granted-roles' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.evaluate.not-granted-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.not-granted-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-realm-roles" class="form-control" multiple size="5" <select id="available-realm-roles" class="form-control overflow-select" multiple size="5"
disabled="true" disabled="true"
ng-model="dummymodel1" ng-model="dummymodel1">
ng-options="r.name for r in notGrantedRealmRoles | orderBy:'name'"> <option ng-repeat="r in notGrantedRealmRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
<div class="col-md-3"> <div class="col-md-4">
<label class="control-label" for="realm-composite">{{:: 'client-scopes.evaluate.granted-realm-effective-roles' | translate}} </label> <label class="control-label" for="realm-composite">{{:: 'client-scopes.evaluate.granted-realm-effective-roles' | translate}} </label>
<kc-tooltip>{{:: 'client-scopes.evaluate.granted-realm-effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.granted-realm-effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="realm-composite" class="form-control" multiple size=5 <select id="realm-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel2" ng-model="dummymodel2">
ng-options="r.name for r in grantedRealmRoles | orderBy:'name'"> <option ng-repeat="r in grantedRealmRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -203,22 +218,28 @@
<div class="col-md-4"><span class="text-muted">{{:: 'select-client-roles.tooltip' | translate}}</span></div> <div class="col-md-4"><span class="text-muted">{{:: 'select-client-roles.tooltip' | translate}}</span></div>
</div> </div>
<div class="row" data-ng-show="targetClient"> <div class="row" data-ng-show="targetClient">
<div class="col-md-3"> <div class="col-md-4">
<label class="control-label" for="available-client">{{:: 'client-scopes.evaluate.not-granted-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'client-scopes.evaluate.not-granted-roles' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.evaluate.not-granted-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.not-granted-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in notGrantedClientRoles | orderBy:'name'"> <option ng-repeat="r in notGrantedClientRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
<div class="col-md-3"> <div class="col-md-4">
<label class="control-label" for="client-composite">{{:: 'client-scopes.evaluate.granted-client-effective-roles' | translate}}</label> <label class="control-label" for="client-composite">{{:: 'client-scopes.evaluate.granted-client-effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.evaluate.granted-realm-effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.evaluate.granted-realm-effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="client-composite" class="form-control" multiple size=5 <select id="client-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in grantedClientRoles | orderBy:'name'"> <option ng-repeat="r in grantedClientRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>

View file

@ -25,10 +25,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available">{{:: 'default-client-scopes.default.available' | translate}}</label> <label class="control-label" for="available">{{:: 'default-client-scopes.default.available' | translate}}</label>
<kc-tooltip>{{:: 'default-client-scopes.default.available.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'default-client-scopes.default.available.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefaultClientScopes" ng-model="selectedDefaultClientScopes">
ng-options="r.name for r in availableClientScopes | orderBy:'toString()'"> <option ng-repeat="r in availableClientScopes | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addDefaultClientScope()"> <button ng-disabled="selectedDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addDefaultClientScope()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -37,10 +39,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned">{{:: 'default-client-scopes.default.assigned' | translate}}</label> <label class="control-label" for="assigned">{{:: 'default-client-scopes.default.assigned' | translate}}</label>
<kc-tooltip>{{:: 'default-client-scopes.default.assigned.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'default-client-scopes.default.assigned.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefDefaultClientScopes" ng-model="selectedDefDefaultClientScopes">
ng-options="r.name for r in realmDefaultClientScopes | orderBy:'toString()'"> <option ng-repeat="r in realmDefaultClientScopes | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteDefaultClientScope()"> <button ng-disabled="selectedDefDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteDefaultClientScope()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -59,10 +63,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available-opt">{{:: 'default-client-scopes.optional.available' | translate}}</label> <label class="control-label" for="available-opt">{{:: 'default-client-scopes.optional.available' | translate}}</label>
<kc-tooltip>{{:: 'default-client-scopes.optional.available.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'default-client-scopes.optional.available.tooltip' | translate}}</kc-tooltip>
<select id="available-opt" class="form-control" multiple size="5" <select id="available-opt" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedOptionalClientScopes" ng-model="selectedOptionalClientScopes">
ng-options="r.name for r in availableClientScopes | orderBy:'toString()'"> <option ng-repeat="r in availableClientScopes | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addOptionalClientScope()"> <button ng-disabled="selectedOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addOptionalClientScope()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -71,10 +77,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned-opt">{{:: 'default-client-scopes.optional.assigned' | translate}}</label> <label class="control-label" for="assigned-opt">{{:: 'default-client-scopes.optional.assigned' | translate}}</label>
<kc-tooltip>{{:: 'default-client-scopes.optional.assigned.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'default-client-scopes.optional.assigned.tooltip' | translate}}</kc-tooltip>
<select id="assigned-opt" class="form-control" multiple size=5 <select id="assigned-opt" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefOptionalClientScopes" ng-model="selectedDefOptionalClientScopes">
ng-options="r.name for r in realmOptionalClientScopes | orderBy:'toString()'"> <option ng-repeat="r in realmOptionalClientScopes | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteOptionalClientScope()"> <button ng-disabled="selectedDefOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteOptionalClientScope()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}

View file

@ -45,10 +45,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available">{{:: 'client-scopes.default.available' | translate}}</label> <label class="control-label" for="available">{{:: 'client-scopes.default.available' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.default.available.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.default.available.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefaultClientScopes" ng-model="selectedDefaultClientScopes">
ng-options="r.name for r in availableClientScopes | orderBy:'toString()'"> <option ng-repeat="r in availableClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addDefaultClientScope()"> <button ng-disabled="selectedDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addDefaultClientScope()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -57,10 +60,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned">{{:: 'client-scopes.default.assigned' | translate}}</label> <label class="control-label" for="assigned">{{:: 'client-scopes.default.assigned' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.default.assigned.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.default.assigned.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefDefaultClientScopes" ng-model="selectedDefDefaultClientScopes">
ng-options="r.name for r in clientDefaultClientScopes | orderBy:'toString()'"> <option ng-repeat="r in clientDefaultClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteDefaultClientScope()"> <button ng-disabled="selectedDefDefaultClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteDefaultClientScope()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -79,10 +85,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available-opt">{{:: 'client-scopes.optional.available' | translate}}</label> <label class="control-label" for="available-opt">{{:: 'client-scopes.optional.available' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.optional.available.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.optional.available.tooltip' | translate}}</kc-tooltip>
<select id="available-opt" class="form-control" multiple size="5" <select id="available-opt" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedOptionalClientScopes" ng-model="selectedOptionalClientScopes">
ng-options="r.name for r in availableClientScopes | orderBy:'toString()'"> <option ng-repeat="r in availableClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addOptionalClientScope()"> <button ng-disabled="selectedOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="addOptionalClientScope()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -91,10 +100,13 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned-opt">{{:: 'client-scopes.optional.assigned' | translate}}</label> <label class="control-label" for="assigned-opt">{{:: 'client-scopes.optional.assigned' | translate}}</label>
<kc-tooltip>{{:: 'client-scopes.optional.assigned.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-scopes.optional.assigned.tooltip' | translate}}</kc-tooltip>
<select id="assigned-opt" class="form-control" multiple size=5 <select id="assigned-opt" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedDefOptionalClientScopes" ng-model="selectedDefOptionalClientScopes">
ng-options="r.name for r in clientOptionalClientScopes | orderBy:'toString()'"> <option ng-repeat="r in clientOptionalClientScopes | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedDefOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteOptionalClientScope()"> <button ng-disabled="selectedDefOptionalClientScopes.length == 0" class="btn btn-default" type="submit" ng-click="deleteOptionalClientScope()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}

View file

@ -19,10 +19,13 @@
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'service-account.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'service-account.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -31,10 +34,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'service-account.assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'service-account.assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -43,10 +49,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}} </label> <label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}} </label>
<kc-tooltip>{{:: 'realm.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'realm.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="realm-composite" class="form-control" multiple size=5 <select id="realm-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in realmComposite | orderBy:'name'"> <option ng-repeat="r in realmComposite | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -67,10 +76,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'assign.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'assign.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -79,10 +91,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -91,10 +106,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'client.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="client-composite" class="form-control" multiple size=5 <select id="client-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in clientComposite | orderBy:'name'"> <option ng-repeat="r in clientComposite | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>

View file

@ -14,10 +14,12 @@
<div class="row"> <div class="row">
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" ng-disabled="c.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" ng-disabled="c.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-right"></i>
@ -27,10 +29,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'group.assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'group.assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -39,10 +43,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'group.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'group.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="realm-composite" class="form-control" multiple size=5 <select id="realm-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in realmComposite | orderBy:'name'"> <option ng-repeat="r in realmComposite | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -62,10 +68,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'group.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'group.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -74,10 +82,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'group.assigned-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'group.assigned-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -86,10 +96,12 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'group.effective-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'group.effective-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="client-composite" class="form-control" multiple size=5 <select id="client-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in clientComposite | orderBy:'name'"> <option ng-repeat="r in clientComposite | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>

View file

@ -14,10 +14,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'default.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'default.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r for r in availableRealmRoles | orderBy:'toString()'"> <option ng-repeat="r in availableRealmRoles | orderBy:'toString()'" value="{{r}}" title="{{r.toString()}}">
{{r.toString()}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmDefaultRole()"> <button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmDefaultRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -26,10 +28,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned">{{:: 'realm-default-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'realm-default-roles' | translate}}</label>
<kc-tooltip>{{:: 'realm-default-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'realm-default-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmDefRoles" ng-model="selectedRealmDefRoles">
ng-options="r for r in realm.defaultRoles | orderBy:'toString()'"> <option ng-repeat="r in realm.defaultRoles | orderBy:'toString()'" value="{{r}}" title="{{r.toString()}}">
{{r.toString()}}
</option>
</select> </select>
<button ng-disabled="selectedRealmDefRoles.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmDefaultRole()"> <button ng-disabled="selectedRealmDefRoles.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmDefaultRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -52,10 +56,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'default.available-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'default.available-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r for r in availableClientRoles | orderBy:'toString()'"> <option ng-repeat="r in availableClientRoles | orderBy:'toString()'" value="{{r}}" title="{{r.toString()}}">
{{r.toString()}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientDefaultRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientDefaultRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -64,10 +70,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned-client">{{:: 'client-default-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'client-default-roles' | translate}}</label>
<kc-tooltip>{{:: 'client-default-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'client-default-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientDefRoles" ng-model="selectedClientDefRoles">
ng-options="r for r in client.defaultRoles | orderBy:'toString()'"> <option ng-repeat="r in client.defaultRoles | orderBy:'toString()'" value="{{r}}" title="{{r.toString()}}">
{{r.toString()}}
</option>
</select> </select>
<button ng-disabled="selectedClientDefRoles.length == 0" class="btn btn-default" type="submit" ng-click="rmClientDefaultRole()"> <button ng-disabled="selectedClientDefRoles.length == 0" class="btn btn-default" type="submit" ng-click="rmClientDefaultRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}

View file

@ -58,10 +58,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label">{{:: 'available-roles' | translate}}</label> <label class="control-label">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'composite.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'composite.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -70,10 +72,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label">{{:: 'associated-roles' | translate}}</label> <label class="control-label">{{:: 'associated-roles' | translate}}</label>
<kc-tooltip>{{:: 'composite.associated-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'composite.associated-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -97,10 +101,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'composite.available-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'composite.available-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-right"></i>
@ -109,10 +115,12 @@
<div class="col-md-4"> <div class="col-md-4">
<label class="control-label" for="assigned-client">{{:: 'associated-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'associated-roles' | translate}}</label>
<kc-tooltip>{{:: 'composite.associated-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'composite.associated-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'" value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-left"></i> {{:: 'remove-selected' | translate}}

View file

@ -14,10 +14,13 @@
<div class="row"> <div class="row">
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available">{{:: 'available-roles' | translate}}</label>
<select id="available" class="form-control" multiple size="5" <select id="available" class="form-control overflow-select" multiple size="5" realmMappings
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmRoles" ng-model="selectedRealmRoles">
ng-options="r.name for r in realmRoles | orderBy:'name'"> <option ng-repeat="r in realmRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmRoles.length == 0" ng-disabled="c.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()"> <button ng-disabled="selectedRealmRoles.length == 0" ng-disabled="c.length == 0" class="btn btn-default" type="submit" ng-click="addRealmRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-right"></i>
@ -27,10 +30,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'user.assigned-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'user.assigned-roles.tooltip' | translate}}</kc-tooltip>
<select id="assigned" class="form-control" multiple size=5 <select id="assigned" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedRealmMappings" ng-model="selectedRealmMappings">
ng-options="r.name for r in realmMappings | orderBy:'name'"> <option ng-repeat="r in realmMappings | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()"> <button ng-disabled="selectedRealmMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteRealmRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -39,10 +45,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="realm-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'user.effective-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'user.effective-roles.tooltip' | translate}}</kc-tooltip>
<select id="realm-composite" class="form-control" multiple size=5 <select id="realm-composite" class="form-control overflow-select" multiple size="5"
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in realmComposite | orderBy:'name'"> <option ng-repeat="r in realmComposite | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>
@ -62,10 +71,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label> <label class="control-label" for="available-client">{{:: 'available-roles' | translate}}</label>
<kc-tooltip>{{:: 'user.available-roles.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'user.available-roles.tooltip' | translate}}</kc-tooltip>
<select id="available-client" class="form-control" multiple size="5" <select id="available-client" class="form-control overflow-select" multiple size="5"
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientRoles" ng-model="selectedClientRoles">
ng-options="r.name for r in clientRoles | orderBy:'name'"> <option ng-repeat="r in clientRoles | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()"> <button ng-disabled="selectedClientRoles.length == 0" class="btn btn-default" type="submit" ng-click="addClientRole()">
{{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i> {{:: 'add-selected' | translate}} <i class="fa fa-angle-double-right"></i>
@ -74,10 +86,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label> <label class="control-label" for="assigned-client">{{:: 'assigned-roles' | translate}}</label>
<kc-tooltip>{{:: 'user.assigned-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'user.assigned-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="assigned-client" class="form-control" multiple size=5 <select id="assigned-client" class="form-control overflow-select" multiple size=5
ng-multiple="true" ng-multiple="true"
ng-model="selectedClientMappings" ng-model="selectedClientMappings">
ng-options="r.name for r in clientMappings | orderBy:'name'"> <option ng-repeat="r in clientMappings | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
<button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()"> <button ng-disabled="selectedClientMappings.length == 0" class="btn btn-default" type="submit" ng-click="deleteClientRole()">
<i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}} <i class="fa fa-angle-double-left"></i> {{:: 'remove-selected' | translate}}
@ -86,10 +101,13 @@
<div class="col-md-3"> <div class="col-md-3">
<label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label> <label class="control-label" for="client-composite">{{:: 'effective-roles' | translate}}</label>
<kc-tooltip>{{:: 'user.effective-roles-client.tooltip' | translate}}</kc-tooltip> <kc-tooltip>{{:: 'user.effective-roles-client.tooltip' | translate}}</kc-tooltip>
<select id="client-composite" class="form-control" multiple size=5 <select id="client-composite" class="form-control overflow-select" multiple size=5
disabled="true" disabled="true"
ng-model="dummymodel" ng-model="dummymodel">
ng-options="r.name for r in clientComposite | orderBy:'name'"> <option ng-repeat="r in clientComposite | orderBy:'name'"
value="{{r}}" title="{{r.name}}">
{{r.name}}
</option>
</select> </select>
</div> </div>
</div> </div>

View file

@ -190,6 +190,11 @@ th.w-40 {
height: 26px; height: 26px;
} }
/*********** html select ********/
.overflow-select {
overflow: auto;
}
/*********** New Menu ***********/ /*********** New Menu ***********/