1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-18 12:21:45 +02:00

Issue #55 - more handling of 'not a member of' user class

This commit is contained in:
SteveD
2013-02-03 18:29:11 +00:00
parent fecd0cb015
commit 724a648706
2 changed files with 16 additions and 9 deletions

View File

@@ -1078,6 +1078,9 @@ class e_form
// Callback for vetted_tree - Creates the option list for a selection box
function _uc_select_cb($treename, $classnum, $current_value, $nest_level)
{
$classIndex = abs($classnum); // Handle negative class values
$classSign = (substr($classnum, 0, 1) == '-') ? '-' : '';
if($classnum == e_UC_BLANK)
return $this->option(' ', '');
@@ -1097,9 +1100,10 @@ class e_form
$prefix = '  '.str_repeat('--', $nest_level - 1).'>';
$style = '';
}
return $this->option($prefix.$this->_uc->uc_get_classname($classnum), $classnum, ($current_value !== '' && in_array($classnum, $tmp)), array("style"=>"{$style}"))."\n";
return $this->option($prefix.$this->_uc->uc_get_classname($classnum), '{$classSign}{$classIndex}', ($current_value !== '' && in_array($classnum, $tmp)), array("style"=>"{$style}"))."\n";
}
function optgroup_open($label, $disabled = false)
{
return "<optgroup class='optgroup' label='{$label}'".($disabled ? " disabled='disabled'" : '').">";