/
actions.html.twig
35 lines (30 loc) · 1.41 KB
/
actions.html.twig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
{% macro invoices(view) %}
{% import "macros/widgets.html.twig" as widgets %}
{% set event = actions(app.user, 'invoices', view) %}
{{ widgets.page_actions(event.actions) }}
{% endmacro %}
{% macro invoice(invoice, view) %}
{% import "macros/widgets.html.twig" as widgets %}
{% set event = actions(app.user, 'invoice', view, {'invoice': invoice, 'token': csrf_token('invoice.delete')}) %}
{{ widgets.table_actions(event.actions) }}
{% endmacro %}
{% macro invoice_listing(view, query) %}
{% import "macros/widgets.html.twig" as widgets %}
{% set event = actions(app.user, 'invoice_details', view, {'query': query}) %}
{{ widgets.page_actions(event.actions) }}
{% endmacro %}
{% macro invoice_upload(view) %}
{% import "macros/widgets.html.twig" as widgets %}
{% set event = actions(app.user, 'invoice_upload', view) %}
{{ widgets.page_actions(event.actions) }}
{% endmacro %}
{% macro invoice_templates(view) %}
{% import "macros/widgets.html.twig" as widgets %}
{% set event = actions(app.user, 'invoice_templates', view) %}
{{ widgets.page_actions(event.actions) }}
{% endmacro %}
{% macro invoice_template(template, view) %}
{% import "macros/widgets.html.twig" as widgets %}
{% set event = actions(app.user, 'invoice_template', view, {'template': template, 'token': csrf_token('invoice.delete_template')}) %}
{{ widgets.table_actions(event.actions) }}
{% endmacro %}