Added column LDAP role search query in LDAPConfiguration

This commit is contained in:
Ignacio Diaz Teijido 2011-06-28 17:13:15 +02:00 committed by Manuel Rego Casasnovas
parent 40a87d837f
commit 18f34651f9
4 changed files with 30 additions and 0 deletions

View file

@ -85,6 +85,8 @@ public class LDAPConfiguration extends BaseEntity {
private Map<String, List<String>> mapMatchingRoles = new HashMap<String, List<String>>();
private String ldapSearchQuery;
public String getLdapUserId() {
return ldapUserId;
}
@ -226,4 +228,18 @@ public class LDAPConfiguration extends BaseEntity {
this.mapMatchingRoles = mapMatchingRoles;
}
/**
* @return the ldapSearchQuery
*/
public String getLdapSearchQuery() {
return ldapSearchQuery;
}
/**
* @param ldapSearchQuery
* the ldapSearchQuery to set
*/
public void setLdapSearchQuery(String ldapSearchQuery) {
this.ldapSearchQuery = ldapSearchQuery;
}
}

View file

@ -148,5 +148,11 @@
<column name="ldap_role_property" type="VARCHAR(255)" />
</addColumn>
</changeSet>
<changeSet id="add-new-column-ldap-search-query" author="idiazt">
<comment>Add new column to store ldap role search query</comment>
<addColumn tableName="configuration">
<column name="ldap_search_query" type="VARCHAR(255)" />
</addColumn>
</changeSet>
</databaseChangeLog>

View file

@ -78,6 +78,7 @@
<property name="ldapSavePasswordsDB" column="ldap_save_password_db" not-null="true"/>
<property name="ldapAuthEnabled" column="ldap_auth_enabled" not-null="true"/>
<property name="ldapSaveRolesDB" column="ldap_save_roles_db" not-null="true"/>
<property name="ldapSearchQuery" column="ldap_search_query"/>
<list name="configurationRolesLdap" table="configuration_roles_ldap" lazy="false">
<key column="id_configuration" />

View file

@ -361,6 +361,13 @@
<label value="${i18n:__('Example: {0}', 'memberUid')}" />
</hbox>
</row>
<row>
<label value="${i18n:_('Role search query:')}" />
<hbox>
<textbox id="ldapSearchQuery" value="@{configurationController.ldapConfiguration.ldapSearchQuery}" width="300px"/>
<label value="${i18n:__('Example: {0}', 'uid=[@user_id],ou=groups,ou=people,dc=example,dc=org')}" />
</hbox>
</row>
</rows>
</grid>
<separator />