Commit a76bf353 authored by Côme Chilliet's avatar Côme Chilliet
Browse files

Fixes #2166 Fixed semantic of plDescription

parent 32c26838
...@@ -297,8 +297,12 @@ class acl extends plugin ...@@ -297,8 +297,12 @@ class acl extends plugin
'plDescription' => _('Manage access control lists'), 'plDescription' => _('Manage access control lists'),
'plSelfModify' => FALSE, 'plSelfModify' => FALSE,
'plPriority' => 0, 'plPriority' => 0,
'plCategory' => array('acl' => array('description' => _('ACL').' & '._('ACL roles'), 'plCategory' => array(
'objectClass' => array('gosaAcl','gosaRole'))), 'acl' => array(
'description' => _('ACL').' & '._('ACL roles'),
'objectClass' => array('gosaAcl','gosaRole')
)
),
'plObjectType' => array(), 'plObjectType' => array(),
'plProvidedAcls' => array() 'plProvidedAcls' => array()
......
...@@ -1121,7 +1121,6 @@ class config { ...@@ -1121,7 +1121,6 @@ class config {
} }
array_unshift($this->data['TABS'][$tabclass], $entry); array_unshift($this->data['TABS'][$tabclass], $entry);
} }
} }
} elseif (class_available($class) && is_subclass_of($class, 'simpleService')) { } elseif (class_available($class) && is_subclass_of($class, 'simpleService')) {
@DEBUG (DEBUG_TRACE, __LINE__, __FUNCTION__, __FILE__, $class, "Adding service"); @DEBUG (DEBUG_TRACE, __LINE__, __FUNCTION__, __FILE__, $class, "Adding service");
......
...@@ -246,23 +246,23 @@ class management ...@@ -246,23 +246,23 @@ class management
} }
if (in_array_ics('plInfo', get_class_methods(get_class($this)))) { if (in_array_ics('plInfo', get_class_methods(get_class($this)))) {
$plInfos = $this->plInfo(); $plInfos = $this->plInfo();
$plDescription = $plInfos['plDescription']; $plTitle = $plInfos['plTitle'];
$plIcon = $plInfos['plIcon']; $plIcon = $plInfos['plIcon'];
} else { } else {
$plDescription = $this->plDescription; $plTitle = $this->plDescription;
$plIcon = $this->plIcon; $plIcon = $this->plIcon;
} }
if (!preg_match('/^geticon/', $plIcon)) { if (!preg_match('/^geticon/', $plIcon)) {
$plIcon = get_template_path($plIcon); $plIcon = get_template_path($plIcon);
} }
if (get_object_info() != "") { if (get_object_info() != '') {
$display = print_header($plIcon, _($plDescription), $display = print_header($plIcon, _($plTitle),
'<img alt="" class="center" src="geticon.php?context=status&amp;icon=object-locked&amp;size=16"/>'. '<img alt="" class="center" src="geticon.php?context=status&amp;icon=object-locked&amp;size=16"/>'.
LDAP::fix(get_object_info())); LDAP::fix(get_object_info()));
} else { } else {
$display = print_header($plIcon, _($plDescription)); $display = print_header($plIcon, _($plTitle));
} }
return $display; return $display;
} }
......
...@@ -139,6 +139,9 @@ class pluglist { ...@@ -139,6 +139,9 @@ class pluglist {
if (!isset($infos['plCategory'])) { if (!isset($infos['plCategory'])) {
$infos['plCategory'] = array(); $infos['plCategory'] = array();
} }
if (!isset($infos['plTitle'])) {
$infos['plTitle'] = $infos['plShortName'];
}
$infos['plForeignRefs'] = array(); $infos['plForeignRefs'] = array();
$infos['INDEX'] = $index; $infos['INDEX'] = $index;
$this->info[$cname] = $infos; $this->info[$cname] = $infos;
......
...@@ -749,7 +749,7 @@ class simplePlugin extends plugin ...@@ -749,7 +749,7 @@ class simplePlugin extends plugin
$plInfo = pluglist::pluginInfos($classname); $plInfo = pluglist::pluginInfos($classname);
$plIcon = (isset($plInfo['plIcon'])?$plInfo['plIcon']:"plugin.png"); $plIcon = (isset($plInfo['plIcon'])?$plInfo['plIcon']:"plugin.png");
$plHeadline = $plInfo['plShortName']; $plHeadline = $plInfo['plTitle'];
if (($tabs !== FALSE) && ($tabclass === FALSE)) { if (($tabs !== FALSE) && ($tabclass === FALSE)) {
$key = key($plInfo['plObjectType']); $key = key($plInfo['plObjectType']);
if (is_numeric($key)) { if (is_numeric($key)) {
......
...@@ -25,6 +25,7 @@ class dashboard extends simplePlugin ...@@ -25,6 +25,7 @@ class dashboard extends simplePlugin
{ {
return array( return array(
'plShortName' => _('Dashboard'), 'plShortName' => _('Dashboard'),
'plTitle' => _('Dashboard'),
'plDescription' => _('Statistics and various informations'), 'plDescription' => _('Statistics and various informations'),
'plIcon' => 'geticon.php?context=applications&icon=utilities-system-monitor&size=48', 'plIcon' => 'geticon.php?context=applications&icon=utilities-system-monitor&size=48',
'plObjectType' => array('dashboard' => array('name' => _('Dashboard'))), 'plObjectType' => array('dashboard' => array('name' => _('Dashboard'))),
......
...@@ -36,7 +36,8 @@ class aclManagement extends simpleManagement ...@@ -36,7 +36,8 @@ class aclManagement extends simpleManagement
{ {
return array( return array(
'plShortName' => _('ACL assignments'), 'plShortName' => _('ACL assignments'),
'plDescription' => _('Access control list management'), 'plTitle' => _('ACL assignments management'),
'plDescription' => _('Manage ACL roles assignments to users'),
'plIcon' => 'geticon.php?context=categories&icon=acl&size=48', 'plIcon' => 'geticon.php?context=categories&icon=acl&size=48',
'plSection' => 'accounts', 'plSection' => 'accounts',
'plPriority' => 28, 'plPriority' => 28,
......
...@@ -32,7 +32,8 @@ class aclRoleManagement extends simpleManagement ...@@ -32,7 +32,8 @@ class aclRoleManagement extends simpleManagement
{ {
return array( return array(
'plShortName' => _('ACL roles'), 'plShortName' => _('ACL roles'),
'plDescription' => _('ACL roles management'), 'plTitle' => _('ACL roles management'),
'plDescription' => _('Manage ACL roles'),
'plIcon' => 'geticon.php?context=categories&icon=acl&size=48', 'plIcon' => 'geticon.php?context=categories&icon=acl&size=48',
'plSection' => 'accounts', 'plSection' => 'accounts',
'plPriority' => 27, 'plPriority' => 27,
......
...@@ -32,7 +32,8 @@ class departmentManagement extends simpleManagement ...@@ -32,7 +32,8 @@ class departmentManagement extends simpleManagement
{ {
return array( return array(
'plShortName' => _('Departments'), 'plShortName' => _('Departments'),
'plDescription' => _('Manage departments'), 'plTitle' => _('Manage departments'),
'plDescription' => _('Manage departments, countries, domain components, domains, localities and organization nodes,'),
'plIcon' => 'geticon.php?context=places&icon=folder&size=48', 'plIcon' => 'geticon.php?context=places&icon=folder&size=48',
'plSection' => array('accounts' => array('name' => _('Users and groups'), 'priority' => 0)), 'plSection' => array('accounts' => array('name' => _('Users and groups'), 'priority' => 0)),
'plPriority' => 0, 'plPriority' => 0,
...@@ -62,7 +63,6 @@ class departmentManagement extends simpleManagement ...@@ -62,7 +63,6 @@ class departmentManagement extends simpleManagement
$this->refreshDeps(); $this->refreshDeps();
} }
function refreshDeps() function refreshDeps()
{ {
global $config, $ui; global $config, $ui;
...@@ -74,7 +74,6 @@ class departmentManagement extends simpleManagement ...@@ -74,7 +74,6 @@ class departmentManagement extends simpleManagement
$headpage->refreshBasesList(); $headpage->refreshBasesList();
} }
// An action handler which enables to switch into deparmtment by clicking the names. // An action handler which enables to switch into deparmtment by clicking the names.
function openEntry($action, $entry) function openEntry($action, $entry)
{ {
......
...@@ -29,7 +29,8 @@ class groupManagement extends simpleManagement ...@@ -29,7 +29,8 @@ class groupManagement extends simpleManagement
{ {
return array( return array(
'plShortName' => _('Groups and roles'), 'plShortName' => _('Groups and roles'),
'plDescription' => _('Manage groups and roles'), 'plTitle' => _('Manage groups and roles'),
'plDescription' => _('Allows you to manage object groups, POSIX groups and roles'),
'plIcon' => 'geticon.php?context=types&icon=resource-group&size=48', 'plIcon' => 'geticon.php?context=types&icon=resource-group&size=48',
'plSection' => 'accounts', 'plSection' => 'accounts',
'plManages' => array('ogroup', 'group', 'role'), 'plManages' => array('ogroup', 'group', 'role'),
...@@ -84,14 +85,14 @@ class groupManagement extends simpleManagement ...@@ -84,14 +85,14 @@ class groupManagement extends simpleManagement
if ($grouptab->is_this_account($attrs)) { if ($grouptab->is_this_account($attrs)) {
$infos = pluglist::pluginInfos($class); $infos = pluglist::pluginInfos($class);
if (isset($infos['plSmallIcon'])) { if (isset($infos['plSmallIcon'])) {
$result .= "<input class='center' type='image' src='".htmlentities($infos['plSmallIcon'], ENT_COMPAT, 'UTF-8')."' ". $result .= '<input class="center" type="image" src="'.htmlentities($infos['plSmallIcon'], ENT_COMPAT, 'UTF-8').'" '.
"alt='".$infos['plShortName']."' title='".$infos['plShortName']."' ". 'alt="'.$infos['plTitle'].'" title="'.$infos['plTitle'].'" '.
"name='listing_edit_tab_".$class."_$row' style='padding:1px'/>"; 'name="listing_edit_tab_'.$class.'_'.$row.'" style="padding:1px"/>';
} else { } else {
@DEBUG (DEBUG_TRACE, __LINE__, __FUNCTION__, __FILE__, $infos['plShortName']." ($class)", 'No icon for'); @DEBUG (DEBUG_TRACE, __LINE__, __FUNCTION__, __FILE__, $infos['plShortName']." ($class)", 'No icon for');
} }
} else { } else {
$result .= "<img src='images/empty.png' alt=' ' class='center optional $class' style='padding:1px'>"; $result .= '<img src="images/empty.png" alt=" " class="center optional '.$class.'" style="padding:1px"/>';
} }
} }
} }
......
...@@ -40,7 +40,8 @@ class userManagement extends simpleManagement ...@@ -40,7 +40,8 @@ class userManagement extends simpleManagement
{ {
return array( return array(
'plShortName' => _('Users'), 'plShortName' => _('Users'),
'plDescription' => _('Manage users'), 'plTitle' => _('Manage users'),
'plDescription' => _('Manage user accounts and their properties'),
'plIcon' => 'geticon.php?context=types&icon=user&size=48', 'plIcon' => 'geticon.php?context=types&icon=user&size=48',
'plSection' => 'accounts', 'plSection' => 'accounts',
'plManages' => array('user'), 'plManages' => array('user'),
......
...@@ -55,7 +55,8 @@ class configInLdap extends simplePlugin ...@@ -55,7 +55,8 @@ class configInLdap extends simplePlugin
{ {
return array( return array(
'plShortName' => _('Configuration'), 'plShortName' => _('Configuration'),
'plDescription' => _('FusionDirectory configuration'), 'plTitle' => _('FusionDirectory configuration'),
'plDescription' => _('Configuration screen of FusionDirectory'),
'plIcon' => 'geticon.php?context=categories&icon=settings&size=48', 'plIcon' => 'geticon.php?context=categories&icon=settings&size=48',
'plObjectType' => array( 'plObjectType' => array(
'configuration' => array( 'configuration' => array(
......
...@@ -200,11 +200,11 @@ class setup ...@@ -200,11 +200,11 @@ class setup
$step->update_strings(); $step->update_strings();
$s_title = $step->get_title(); $s_short_name = $step->get_short_name();
$s_info = $step->get_small_info(); $s_description = $step->get_description();
$b_active = $step->is_active(); $b_active = $step->is_active();
$b_enabled = $step->is_enabled(); $b_enabled = $step->is_enabled();
$b_completed = $step->is_completed(); $b_completed = $step->is_completed();
if ($b_completed) { if ($b_completed) {
$s = '<img src="geticon.php?context=status&amp;icon=task-complete&amp;size=16" alt="'._('Completed').'" class="center optional"/>&nbsp;'; $s = '<img src="geticon.php?context=status&amp;icon=task-complete&amp;size=16" alt="'._('Completed').'" class="center optional"/>&nbsp;';
...@@ -214,19 +214,19 @@ class setup ...@@ -214,19 +214,19 @@ class setup
if ($b_enabled) { if ($b_enabled) {
if ($b_active) { if ($b_active) {
$str .= '<li class="menuitem menucurrent" title="'.$s_info.'">'; $str .= '<li class="menuitem menucurrent" title="'.$s_description.'">';
$str .= '<a class="navigation_title">'.$s.$s_title.'</a>'; $str .= '<a class="navigation_title">'.$s.$s_short_name.'</a>';
$str .= '<a class="navigation_info">'.$s_info.'</a>'; $str .= '<a class="navigation_info">'.$s_description.'</a>';
$str .= '</li>'; $str .= '</li>';
} else { } else {
$str .= '<li class="menuitem" title="'.$s_info.'">'; $str .= '<li class="menuitem" title="'.$s_description.'">';
$str .= '<a onClick="document.mainform.setup_goto_step.value=\''.$key.'\';document.mainform.submit();" $str .= '<a onClick="document.mainform.setup_goto_step.value=\''.$key.'\';document.mainform.submit();"
class="navigation_title">'.$s.$s_title.'</a>'; class="navigation_title">'.$s.$s_short_name.'</a>';
$str .= '</li>'; $str .= '</li>';
} }
} else { } else {
$str .= '<li class="menuitem disabled" title="'.$s_info.'">'; $str .= '<li class="menuitem disabled" title="'.$s_description.'">';
$str .= '<a class="navigation_title">'.$s.$s_title.'</a>'; $str .= '<a class="navigation_title">'.$s.$s_short_name.'</a>';
$str .= '</li>'; $str .= '</li>';
} }
} }
...@@ -259,7 +259,7 @@ class setup ...@@ -259,7 +259,7 @@ class setup
/* Create header entry */ /* Create header entry */
function get_header_text() function get_header_text()
{ {
return $this->o_steps[$this->i_current]->get_long_title(); return $this->o_steps[$this->i_current]->get_title();
} }
/* Create header entry */ /* Create header entry */
......
...@@ -21,14 +21,14 @@ ...@@ -21,14 +21,14 @@
class setupStep extends simplePlugin class setupStep extends simplePlugin
{ {
protected $s_title = "Still undefined"; protected $s_short_name = 'Still undefined';
protected $s_title_long = "Still undefined"; protected $s_title = 'Still undefined';
protected $s_info = "Still undefined"; protected $s_description = 'Still undefined';
var $is_active = FALSE; var $is_active = FALSE;
var $is_enabled = FALSE; var $is_enabled = FALSE;
var $is_completed = FALSE; var $is_completed = FALSE;
var $header_image = ""; var $header_image = '';
static function getAttributesInfo() static function getAttributesInfo()
{ {
...@@ -47,19 +47,19 @@ class setupStep extends simplePlugin ...@@ -47,19 +47,19 @@ class setupStep extends simplePlugin
die('abstract method'); die('abstract method');
} }
function get_title() function get_short_name()
{ {
return $this->s_title; return $this->s_short_name;
} }
function get_long_title() function get_title()
{ {
return $this->s_title_long; return $this->s_title;
} }
function get_small_info() function get_description()
{ {
return $this->s_info; return $this->s_description;
} }
function is_active() function is_active()
......
...@@ -45,9 +45,9 @@ class Step_Checks extends setupStep ...@@ -45,9 +45,9 @@ class Step_Checks extends setupStep
function update_strings() function update_strings()
{ {
$this->s_title = _("Installation check"); $this->s_short_name = _('Installation check');
$this->s_title_long = _("Installation check"); $this->s_title = _('Installation check');
$this->s_info = _("Basic checks for PHP compatibility and extensions"); $this->s_description = _('Basic checks for PHP compatibility and extensions');
} }
/* Execute and display template */ /* Execute and display template */
......
...@@ -28,10 +28,10 @@ class Step_Config_before_init extends setupStep ...@@ -28,10 +28,10 @@ class Step_Config_before_init extends setupStep
$config->current['BASE'] = ''; $config->current['BASE'] = '';
} }
$infos = configInLdap::plInfo(); $infos = configInLdap::plInfo();
$this->header_image = $infos['plIcon']; $this->header_image = $infos['plIcon'];
$this->s_title = $infos['plShortName']; $this->s_short_name = $infos['plShortName'];
$this->s_title_long = $infos['plDescription']; $this->s_title = $infos['plTitle'];
$this->s_info = $infos['plDescription']; $this->s_description = $infos['plDescription'];
} }
} }
...@@ -64,19 +64,19 @@ class Step_Config extends configInLdap ...@@ -64,19 +64,19 @@ class Step_Config extends configInLdap
$this->header_image = $infos['plIcon']; $this->header_image = $infos['plIcon'];
} }
function get_title() function get_short_name()
{ {
$infos = parent::plInfo(); $infos = parent::plInfo();
return $infos['plShortName']; return $infos['plTitle'];
} }
function get_long_title() function get_title()
{ {
$infos = parent::plInfo(); $infos = parent::plInfo();
return $infos['plDescription']; return $infos['plDescription'];
} }
function get_small_info() function get_description()
{ {
$infos = parent::plInfo(); $infos = parent::plInfo();
return $infos['plDescription']; return $infos['plDescription'];
......
...@@ -37,9 +37,9 @@ class Step_Finish extends setupStep ...@@ -37,9 +37,9 @@ class Step_Finish extends setupStep
function update_strings() function update_strings()
{ {
$this->s_title = _('Finish'); $this->s_short_name = _('Finish');
$this->s_info = _('Write configuration file'); $this->s_title = _('Finish - write the configuration file');
$this->s_title_long = _('Finish - write the configuration file'); $this->s_description = _('Write configuration file');
} }
function get_conf_data() function get_conf_data()
......
...@@ -56,10 +56,10 @@ class Step_Language extends setupStep ...@@ -56,10 +56,10 @@ class Step_Language extends setupStep
function update_strings() function update_strings()
{ {
$this->s_title = _("Language setup"); $this->s_short_name = _('Language setup');
$this->s_title_long = _("Language setup"); $this->s_title = _('Language setup');
$this->s_info = _("This step allows you to select your preferred language."); $this->s_description = _('This step allows you to select your preferred language.');
$this->msg = _('At this point, you can select the site wide default language. Choosing "automatic" will use the language requested by the browser. This setting can be overriden per user.'); $this->msg = _('At this point, you can select the site wide default language. Choosing "automatic" will use the language requested by the browser. This setting can be overriden per user.');
} }
function execute() function execute()
......
...@@ -104,9 +104,9 @@ class Step_Ldap extends setupStep ...@@ -104,9 +104,9 @@ class Step_Ldap extends setupStep
function update_strings() function update_strings()
{ {
$this->s_title = _("LDAP setup"); $this->s_short_name = _('LDAP setup');
$this->s_title_long = _("LDAP connection setup"); $this->s_title = _('LDAP connection setup');
$this->s_info = _("This dialog performs the basic configuration of the LDAP connectivity for FusionDirectory."); $this->s_description = _('This dialog performs the basic configuration of the LDAP connectivity for FusionDirectory.');
} }
function update_base_choices() function update_base_choices()
......
...@@ -220,9 +220,9 @@ class Step_Migrate extends setupStep ...@@ -220,9 +220,9 @@ class Step_Migrate extends setupStep
function update_strings() function update_strings()
{ {
$this->s_title = _("LDAP inspection"); $this->s_short_name = _('LDAP inspection');
$this->s_title_long = _("LDAP inspection"); $this->s_title = _('LDAP inspection');
$this->s_info = _("Analyze your current LDAP for FusionDirectory compatibility"); $this->s_description = _('Analyze your current LDAP for FusionDirectory compatibility');
} }
function fill_defaultRoles() function fill_defaultRoles()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment