mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 12:39:25 +01:00
Don't take away default action's onExecute, even if it does have children
This commit is contained in:
parent
e36a7b17e3
commit
42272cf2e2
@ -713,11 +713,15 @@ class etemplate_widget_nextmatch extends etemplate_widget
|
|||||||
if ($action['children'])
|
if ($action['children'])
|
||||||
{
|
{
|
||||||
static $inherit_attrs = array('url','popup','nm_action','onExecute','type','egw_open','allowOnMultiple','confirm','confirm_multiple');
|
static $inherit_attrs = array('url','popup','nm_action','onExecute','type','egw_open','allowOnMultiple','confirm','confirm_multiple');
|
||||||
|
$inherit_keys = array_flip($inherit_attrs);
|
||||||
$action['children'] = self::egw_actions($action['children'], $template_name, $action['prefix'], $action_links, $max_length,
|
$action['children'] = self::egw_actions($action['children'], $template_name, $action['prefix'], $action_links, $max_length,
|
||||||
array_intersect_key($action, array_flip($inherit_attrs)));
|
array_intersect_key($action, $inherit_keys));
|
||||||
|
|
||||||
unset($action['prefix']);
|
unset($action['prefix']);
|
||||||
$action = array_diff_key($action, array_flip($inherit_attrs));
|
|
||||||
|
// Allow default actions to keep their onExecute
|
||||||
|
if($action['default']) unset($inherit_keys['onExecute']);
|
||||||
|
$action = array_diff_key($action, $inherit_keys);
|
||||||
}
|
}
|
||||||
|
|
||||||
// link or popup action
|
// link or popup action
|
||||||
|
Loading…
Reference in New Issue
Block a user