restart via API allows to copy description (#782)
This commit is contained in:
@@ -219,7 +219,7 @@
|
||||
{% endif %}
|
||||
|
||||
{% if timesheet.end and is_granted('start', timesheet) %}
|
||||
{% set actions = actions|merge({'repeat': path('timesheet_start', {'id' : timesheet.id})}) %}
|
||||
{% set actions = actions|merge({'repeat': {'url': path('restart_timesheet', {'id' : timesheet.id}), 'class': 'api-link', 'attr': {'data-payload': '{"copy": "all"}', 'data-event': 'kimai.timesheetStart kimai.timesheetUpdate', 'data-method': 'PATCH', 'data-msg-error': 'timesheet.start.error', 'data-msg-success': 'timesheet.start.success'}}}) %}
|
||||
{% endif %}
|
||||
|
||||
{% if is_granted('edit', timesheet) %}
|
||||
@@ -274,7 +274,7 @@
|
||||
{% endif %}
|
||||
|
||||
{% if timesheet.end and is_granted('start', timesheet) %}
|
||||
{% set actions = actions|merge({'repeat': path('timesheet_start', {'id' : timesheet.id})}) %}
|
||||
{% set actions = actions|merge({'repeat': {'url': path('restart_timesheet', {'id' : timesheet.id}), 'class': 'api-link', 'attr': {'data-payload': '{"copy": "all"}', 'data-event': 'kimai.timesheetStart kimai.timesheetUpdate', 'data-method': 'PATCH', 'data-msg-error': 'timesheet.start.error', 'data-msg-success': 'timesheet.start.success'}}}) %}
|
||||
{% endif %}
|
||||
|
||||
{% if is_granted('edit', timesheet) %}
|
||||
|
||||
@@ -253,8 +253,8 @@
|
||||
target="{{ target }}"
|
||||
{%- endif -%}
|
||||
{%- if attr is not empty -%}
|
||||
{%- for name, value in attr -%}
|
||||
{{ name }}="{{ value }}"
|
||||
{%- for name, value in attr %}
|
||||
{{- ' ' ~ name }}={% if '"' in value %}'{{ value|raw }}'{% else %}"{{ value|raw }}"{% endif %}
|
||||
{%- endfor -%}
|
||||
{%- endif -%}
|
||||
>{% if title is not null %}{{ title }}{% else %}{{ macro.icon(icon) }}{% endif %}</a>
|
||||
|
||||
Reference in New Issue
Block a user