mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-12-23 00:43:48 +01:00
Add helpInfo parameter for customActions
This commit is contained in:
parent
e76a25b22b
commit
002e83e1ab
4 changed files with 12 additions and 1 deletions
|
@ -9,6 +9,7 @@
|
|||
'action1' => array(
|
||||
'label' => '[label l'action]',
|
||||
'hideLabel' => '[booléen]',
|
||||
'helpInfo' => '[label d'aide]',
|
||||
'icon' => '[nom de l'icône de l'action]',
|
||||
'function' => '[fonction à exécuter]',
|
||||
'question_format' => '[LSformat de la question de confirmation]',
|
||||
|
@ -42,6 +43,13 @@
|
|||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term>helpInfo</term>
|
||||
<listitem>
|
||||
<simpara>Le label du message d'aide qui sera affiché au survole du bouton de l'action.</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term>icon</term>
|
||||
<listitem>
|
||||
|
|
|
@ -131,6 +131,7 @@ if (loadDir(LS_OBJECTS_DIR) && loadDir(LS_LOCAL_DIR.LS_OBJECTS_DIR)) {
|
|||
if (is_array($conf['customActions'])) {
|
||||
foreach($conf['customActions'] as $act) {
|
||||
add($act['label']);
|
||||
add($act['helpInfo']);
|
||||
add($act['question_format']);
|
||||
add($act['onSuccessMsgFormat']);
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<ul class='LSview-actions'>
|
||||
{foreach from=$LSview_actions item=item}
|
||||
{if is_array($item)}
|
||||
<li class='LSview-actions'><a href="{$item.url}" class="LSview-actions{if $item.class} {$item.class}{/if}" ><img src="{img name=$item.action}" alt="{$item.label}" title="{$item.label}" />{if !isset($item.hideLabel) || !$item.hideLabel} {$item.label}{/if}</a></li>
|
||||
<li class='LSview-actions'><a href="{$item.url}" class="LSview-actions{if $item.class} {$item.class|escape:"quotes"}{/if}{if $item.helpInfo || ($item.hideLabel && $item.label)} LStips{/if}" {if $item.helpInfo || ($item.hideLabel && $item.label)}title="{if $item.helpInfo}{$item.helpInfo|escape:"quotes"}{else}{$item.label|escape:"quotes"}{/if}"{/if}><img src="{img name=$item.action}" alt="{$item.label|escape:"quotes"}" title="{$item.label|escape:"quotes"}" />{if !isset($item.hideLabel) || !$item.hideLabel} {$item.label}{/if}</a></li>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</ul>
|
||||
|
|
|
@ -70,6 +70,7 @@ if(LSsession :: startLSsession()) {
|
|||
$LSview_actions[] = array (
|
||||
'label' => ((isset($config['label']))?__($config['label']):__($name)),
|
||||
'hideLabel' => ((isset($config['hideLabel']))?$config['hideLabel']:False),
|
||||
'helpInfo' => ((isset($config['helpInfo']))?__($config['helpInfo']):False),
|
||||
'url' => 'custom_action.php?LSobject='.$LSobject.'&dn='.urlencode($dn).'&customAction='.$name,
|
||||
'action' => ((isset($config['icon']))?$config['icon']:'generate'),
|
||||
'class' => 'LScustomActions'.(($config['noConfirmation'])?' LScustomActions_noConfirmation':'')
|
||||
|
@ -167,6 +168,7 @@ if(LSsession :: startLSsession()) {
|
|||
$LSview_actions[] = array (
|
||||
'label' => ((isset($config['label']))?__($config['label']):__($name)),
|
||||
'hideLabel' => ((isset($config['hideLabel']))?$config['hideLabel']:False),
|
||||
'helpInfo' => ((isset($config['helpInfo']))?__($config['helpInfo']):False),
|
||||
'url' => 'custom_search_action.php?LSobject='.$LSobject.'&customAction='.$name,
|
||||
'action' => ((isset($config['icon']))?$config['icon']:'generate'),
|
||||
'class' => 'LScustomActions'.(($config['noConfirmation'])?' LScustomActions_noConfirmation':'')
|
||||
|
|
Loading…
Reference in a new issue