more extension points for plugins (#1904)

This commit is contained in:
Kevin Papst
2020-08-21 19:38:17 +02:00
committed by GitHub
parent 5c79e68c77
commit ede21fe46a
8 changed files with 26 additions and 14 deletions

View File

@@ -25,7 +25,7 @@
{{ widgets.page_actions(event.payload.actions) }}
{% endmacro %}
{% macro timesheet(timesheet, view) %}
{% macro timesheet(timesheet, view, options) %}
{%- apply spaceless -%}
{% import "macros/widgets.html.twig" as widgets %}
{% set actions = {} %}
@@ -61,7 +61,7 @@
{% endif %}
{% if view != 'index' %}
{% set actions = actions|merge({'back': path('timesheet')}) %}
{% set actions = actions|merge({'back': options.back|default(path('timesheet'))}) %}
{% endif %}
{% set event = trigger('actions.timesheet', {'actions': actions, 'view': view, 'timesheet': timesheet}) %}