added live filter

This commit is contained in:
Roland Gruber 2015-06-03 18:32:48 +00:00
parent 4d519247a3
commit 6702d53f26
1 changed files with 9 additions and 0 deletions

View File

@ -530,6 +530,14 @@ class windowsGroup extends baseModule {
$return = new htmlTable(); $return = new htmlTable();
// show list of possible new members // show list of possible new members
if (isset($_POST['form_subpage_' . get_class($this) . '_user_select']) && isset($_POST['type'])) { if (isset($_POST['form_subpage_' . get_class($this) . '_user_select']) && isset($_POST['type'])) {
$filterGroup = new htmlGroup();
$filterGroup->addElement(new htmlOutputText(_('Filter') . ' '));
$filter = new htmlInputField('windows_filter');
$filter->setFieldSize('5em');
$filter->setOnKeyUp('filterSelect(\'windows_filter\', \'members\', event);');
$filterGroup->addElement($filter);
$return->addElement($filterGroup, true);
$options = array(); $options = array();
$filter = get_ldap_filter($_POST['type']); $filter = get_ldap_filter($_POST['type']);
$entries = searchLDAPByFilter($filter, array('dn'), array($_POST['type'])); $entries = searchLDAPByFilter($filter, array('dn'), array($_POST['type']));
@ -552,6 +560,7 @@ class windowsGroup extends baseModule {
$membersSelect->setSortElements(false); $membersSelect->setSortElements(false);
$membersSelect->setTransformSingleSelect(false); $membersSelect->setTransformSingleSelect(false);
$return->addElement($membersSelect, true); $return->addElement($membersSelect, true);
$return->addVerticalSpace('10px');
$buttonTable = new htmlTable(); $buttonTable = new htmlTable();
$buttonTable->addElement(new htmlAccountPageButton(get_class($this), 'user', 'addMembers', _('Add'))); $buttonTable->addElement(new htmlAccountPageButton(get_class($this), 'user', 'addMembers', _('Add')));
$buttonTable->addElement(new htmlAccountPageButton(get_class($this), 'user', 'cancel', _('Cancel'))); $buttonTable->addElement(new htmlAccountPageButton(get_class($this), 'user', 'cancel', _('Cancel')));