removed get_configDescriptions()
This commit is contained in:
parent
3733ea62de
commit
617eed52e3
|
@ -1,3 +1,11 @@
|
|||
??? 1.2.0
|
||||
- Samba: better handling of date values
|
||||
|
||||
Developers:
|
||||
API changes:
|
||||
- removed get_configDescription() from module interface
|
||||
|
||||
|
||||
01.11.2006 1.1.1
|
||||
- Lamdaemon: added test page (Tools -> Tests -> Lamdaemon test)
|
||||
- LAM Pro: Samba passwords can now be synchronized with Unix password
|
||||
|
@ -18,6 +26,7 @@
|
|||
- process_...() functions: returned messages are no longer grouped
|
||||
(e.g. return: array(array('INFO', 'headline', 'text'), array('INFO', 'headline2', 'text2')))
|
||||
|
||||
|
||||
10.08.2006 1.0.4
|
||||
- added Russian translation
|
||||
- Samba 3: added policies for domain objects
|
||||
|
|
|
@ -1,6 +1,23 @@
|
|||
Upgrade instructions:
|
||||
=====================
|
||||
|
||||
|
||||
1.1.x -> 1.2.0:
|
||||
===============
|
||||
|
||||
|
||||
Users:
|
||||
|
||||
No changes.
|
||||
|
||||
|
||||
Developers:
|
||||
|
||||
API changes:
|
||||
- removed get_configDescription() from module interface
|
||||
|
||||
|
||||
|
||||
1.0.4 -> 1.1.0:
|
||||
===============
|
||||
|
||||
|
@ -19,6 +36,7 @@ API changes:
|
|||
(e.g. return: array(array('INFO', 'headline', 'text'), array('INFO', 'headline2', 'text2')))
|
||||
|
||||
|
||||
|
||||
1.0.0 -> 1.0.2:
|
||||
===============
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -340,20 +340,6 @@ class baseModule {
|
|||
return $return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an array containing descriptions shown on configuration pages.
|
||||
*
|
||||
* The returned array has the format array('legend' => '...', descriptions => array('option1' => '...', ...)).
|
||||
* <br> The "legend" value is used as text for the fieldset, the descriptions are used when the configuration is printed.
|
||||
*
|
||||
* @return array configuration elements
|
||||
*/
|
||||
function get_configDescriptions() {
|
||||
$return = array('legend' => 'no description', 'descriptions' => array());
|
||||
if (isset($this->meta['config_descriptions'])) $return = $this->meta['config_descriptions'];
|
||||
return $return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks input values of module settings.
|
||||
*
|
||||
|
|
|
@ -309,32 +309,6 @@ function getConfigOptions($scopes) {
|
|||
return $return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a hash array (module name => descriptions) containing descriptions shown on configuration pages.
|
||||
*
|
||||
* The returned array has the format array('legend' => array('posixAccount' => '...', ...), descriptions => array('option1' => '...', ...)).
|
||||
* <br> The "legend" value is used as text for the fieldset, the descriptions are used when the configuration is printed.
|
||||
*
|
||||
* @return array configuration descriptions
|
||||
*/
|
||||
function getConfigDescriptions() {
|
||||
$return = array('legend' => array(), 'descriptions' => array());
|
||||
$modules = array();
|
||||
$types = $_SESSION['config']->get_ActiveTypes();
|
||||
for ($i = 0; $i < sizeof($types); $i++) {
|
||||
$modules = array_merge($modules, getAvailableModules($types[$i]));
|
||||
}
|
||||
$modules = array_merge(getAvailableModules('user'), getAvailableModules('group'), getAvailableModules('host'));
|
||||
$modules = array_values(array_unique($modules));
|
||||
for ($i = 0; $i < sizeof($modules); $i++) {
|
||||
$m = new $modules[$i]('none');
|
||||
$desc = $m->get_configDescriptions();
|
||||
$return['legend'][$modules[$i]] = $desc['legend'];
|
||||
$return['descriptions'] = array_merge($return['descriptions'], $desc['descriptions']);
|
||||
}
|
||||
return $return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the configuration options are valid
|
||||
*
|
||||
|
|
|
@ -140,19 +140,19 @@ class posixAccount extends baseModule {
|
|||
// configuration options
|
||||
$return['config_options']['user'] = array(
|
||||
array(
|
||||
0 => array('kind' => 'text', 'text' => '<b>' . _("Users") . ': </b>' . _('Minimum UID number') . ": "),
|
||||
0 => array('kind' => 'text', 'text' => '<b>' . _("Users") . ': </b>' . _('Minimum UID number') . "*: "),
|
||||
1 => array('kind' => 'input', 'name' => 'posixAccount_minUID', 'type' => 'text', 'size' => '10', 'maxlength' => '255'),
|
||||
2 => array('kind' => 'text', 'value' => ' '),
|
||||
3 => array('kind' => 'text', 'text' => _('Maximum UID number') . ": "),
|
||||
3 => array('kind' => 'text', 'text' => _('Maximum UID number') . "*: "),
|
||||
4 => array('kind' => 'input', 'name' => 'posixAccount_maxUID', 'type' => 'text', 'size' => '10', 'maxlength' => '255'),
|
||||
5 => array('kind' => 'help', 'value' => 'minMaxUser'))
|
||||
);
|
||||
$return['config_options']['host'] = array(
|
||||
array(
|
||||
0 => array('kind' => 'text', 'text' => '<b>' . _("Hosts") . ': </b>' . _('Minimum UID number') . ": "),
|
||||
0 => array('kind' => 'text', 'text' => '<b>' . _("Hosts") . ': </b>' . _('Minimum UID number') . "*: "),
|
||||
1 => array('kind' => 'input', 'name' => 'posixAccount_minMachine', 'type' => 'text', 'size' => '10', 'maxlength' => '255'),
|
||||
2 => array('kind' => 'text', 'value' => ' '),
|
||||
3 => array('kind' => 'text', 'text' => _('Maximum UID number') . ": "),
|
||||
3 => array('kind' => 'text', 'text' => _('Maximum UID number') . "*: "),
|
||||
4 => array('kind' => 'input', 'name' => 'posixAccount_maxMachine', 'type' => 'text', 'size' => '10', 'maxlength' => '255'),
|
||||
5 => array('kind' => 'help', 'value' => 'minMaxHost'))
|
||||
);
|
||||
|
@ -166,17 +166,6 @@ class posixAccount extends baseModule {
|
|||
4 => array('kind' => 'text', 'value' => ' '),
|
||||
5 => array('kind' => 'help', 'value' => 'pwdHash'))
|
||||
);
|
||||
// configuration descriptions
|
||||
$return['config_descriptions'] = array(
|
||||
'legend' => _("UID ranges for Unix accounts"),
|
||||
'descriptions' => array(
|
||||
'posixAccount_minUID' => _("Minimum UID number for Unix accounts (users)"),
|
||||
'posixAccount_maxUID' => _("Maximum UID number for Unix accounts (users)"),
|
||||
'posixAccount_minMachine' => _("Minimum UID number for Unix accounts (hosts)"),
|
||||
'posixAccount_maxMachine' => _("Maximum UID number for Unix accounts (hosts)"),
|
||||
'posixAccount_pwdHash' => _("Password hash type for Unix accounts"),
|
||||
)
|
||||
);
|
||||
// upload
|
||||
$return['upload_preDepends'] = array('inetOrgPerson');
|
||||
// user specific upload options
|
||||
|
|
|
@ -293,22 +293,13 @@ class posixGroup extends baseModule {
|
|||
// configuration options
|
||||
$return['config_options']['group'] = array(
|
||||
array(
|
||||
0 => array('kind' => 'text', 'text' => '<b>' . _('Minimum GID number') . " *: </b>"),
|
||||
0 => array('kind' => 'text', 'text' => '<b>' . _("Groups") . ': </b>' . _('Minimum GID number') . " *: "),
|
||||
1 => array('kind' => 'input', 'name' => 'posixGroup_minGID', 'type' => 'text', 'size' => '10', 'maxlength' => '255'),
|
||||
2 => array('kind' => 'text', 'value' => ' '),
|
||||
3 => array('kind' => 'text', 'text' => '<b>' . _('Maximum GID number') . " *: </b>"),
|
||||
3 => array('kind' => 'text', 'text' => _('Maximum GID number') . " *: "),
|
||||
4 => array('kind' => 'input', 'name' => 'posixGroup_maxGID', 'type' => 'text', 'size' => '10', 'maxlength' => '255'),
|
||||
5 => array('kind' => 'help', 'value' => 'minMaxGID'))
|
||||
);
|
||||
// configuration descriptions
|
||||
$return['config_descriptions'] = array(
|
||||
'legend' => _("GID ranges for Unix groups"),
|
||||
'descriptions' => array(
|
||||
'posixGroup_minGID' => _("Minimum GID number for Unix groups"),
|
||||
'posixGroup_maxGID' => _("Maximum GID number for Unix groups"),
|
||||
'posixAccount_pwdHash' => _("Password hash type for Unix groups"),
|
||||
)
|
||||
);
|
||||
// configuration checks
|
||||
$return['config_checks']['group']['posixGroup_minGID'] = array (
|
||||
'type' => 'ext_preg',
|
||||
|
|
|
@ -451,8 +451,6 @@ class sambaSamAccount extends baseModule {
|
|||
'descriptiveOptions' => true),
|
||||
2 => array('kind' => 'help', 'value' => 'timeZone'))
|
||||
);
|
||||
// configuration descriptions
|
||||
$return['config_descriptions'] = array('legend' => _("Samba 3 settings"), 'descriptions' => array());
|
||||
return $return;
|
||||
}
|
||||
|
||||
|
|
|
@ -194,7 +194,9 @@ echo ("<fieldset><legend><b>" . _("Account types and modules") . "</b></legend>"
|
|||
// Account modules
|
||||
$types = $conf->get_ActiveTypes();
|
||||
for ($i = 0; $i < sizeof($types); $i++) {
|
||||
echo "<b>" . getTypeAlias($types[$i]) . ": </b>" . implode(", ", $conf->get_AccountModules($types[$i])) . "<br>\n";
|
||||
$moduleNames = $conf->get_AccountModules($types[$i]);
|
||||
for ($m = 0; $m < sizeof($moduleNames); $m++) $moduleNames[$m] = getModuleAlias($moduleNames[$m], $types[$i]);
|
||||
echo "<b>" . getTypeAlias($types[$i]) . ": </b>" . implode(", ", $moduleNames) . "<br>\n";
|
||||
}
|
||||
echo "<br>\n";
|
||||
echo "<input tabindex=\"$tabindex\" type=\"submit\" name=\"edittypes\" value=\"" . _("Edit account types") . "\"> ";
|
||||
|
@ -223,8 +225,6 @@ for ($m = 0; $m < sizeof($types); $m++) {
|
|||
$options = getConfigOptions($scopes);
|
||||
// get current setting
|
||||
$old_options = $conf->get_moduleSettings();
|
||||
// get module descriptions
|
||||
$moduleDescriptions = getConfigDescriptions();
|
||||
|
||||
|
||||
// display module boxes
|
||||
|
@ -233,7 +233,7 @@ $_SESSION['conf_types'] = array();
|
|||
for ($i = 0; $i < sizeof($modules); $i++) {
|
||||
if (sizeof($options[$modules[$i]]) < 1) continue;
|
||||
echo "<fieldset>\n";
|
||||
echo "<legend><b>" . $moduleDescriptions['legend'][$modules[$i]] . "</b></legend>\n";
|
||||
echo "<legend><b>" . getModuleAlias($modules[$i], "none") . "</b></legend>\n";
|
||||
$configTypes = parseHtml($modules[$i], $options[$modules[$i]], $old_options, true, $tabindex, $tabindexLink, 'config');
|
||||
$_SESSION['conf_types'] = array_merge($configTypes, $_SESSION['conf_types']);
|
||||
echo "</fieldset>\n";
|
||||
|
|
|
@ -184,12 +184,12 @@ function config_showAccountModules($scope, $title) {
|
|||
if (in_array($selected[$i], $available)) { // selected modules must be available
|
||||
if (is_base_module($selected[$i], $scope)) { // mark base modules
|
||||
echo "<option value=\"" . $selected[$i] . "\">";
|
||||
echo $selected[$i] . "(" . getModuleAlias($selected[$i], $scope) . ")(*)";
|
||||
echo getModuleAlias($selected[$i], $scope) . "(" . $selected[$i] . ")(*)";
|
||||
echo "</option>\n";
|
||||
}
|
||||
else {
|
||||
echo "<option value=\"" . $selected[$i] . "\">";
|
||||
echo $selected[$i] . "(" . getModuleAlias($selected[$i], $scope) . ")";
|
||||
echo getModuleAlias($selected[$i], $scope) . "(" . $selected[$i] . ")";
|
||||
echo "</option>\n";
|
||||
}
|
||||
}
|
||||
|
@ -212,12 +212,12 @@ function config_showAccountModules($scope, $title) {
|
|||
if (! in_array($available[$i], $selected)) { // display non-selected modules
|
||||
if (is_base_module($available[$i], $scope)) { // mark base modules
|
||||
echo "<option value=\"" . $available[$i] . "\">";
|
||||
echo $available[$i] . "(" . getModuleAlias($available[$i], $scope) . ")(*)";
|
||||
echo getModuleAlias($available[$i], $scope) . "(" . $available[$i] . ")(*)";
|
||||
echo "</option>\n";
|
||||
}
|
||||
else {
|
||||
echo "<option value=\"" . $available[$i] . "\">";
|
||||
echo $available[$i] . "(" . getModuleAlias($available[$i], $scope) . ")";
|
||||
echo getModuleAlias($available[$i], $scope) . "(" . $available[$i] . ")";
|
||||
echo "</option>\n";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue