Try harder for nextmatch template name so it can be passed to hooks. If it can't be found in value, look in original attributes.

This commit is contained in:
nathangray 2021-04-19 10:42:48 -06:00
parent 50b4067299
commit 51f9177634

View File

@ -506,7 +506,7 @@ class Nextmatch extends Etemplate\Widget
if($key == 'actions' && !isset($value['actions'][0]))
{
$value['action_links'] = array();
$template_name = isset($value['template']) ? $value['template'] : '';
$template_name = $value['template'] ?: $template->attrs['template'] ?: '';
if (!is_array($value['action_links'])) $value['action_links'] = array();
$value['actions'] = self::egw_actions($value['actions'], $template_name, '', $value['action_links']);
}