duplicate projects with all settings (#1465)

This commit is contained in:
Kevin Papst
2020-02-13 16:47:20 +01:00
committed by GitHub
parent 057c824e9f
commit c67617262f
34 changed files with 383 additions and 180 deletions

View File

@@ -27,6 +27,7 @@
{% set class = 'modal-ajax-form' %}
{% endif %}
{% set actions = actions|merge({'edit': {'url': path('admin_project_edit', {'id': project.id}), 'class': class}}) %}
{% set actions = actions|merge({'copy': {'url': path('admin_project_duplicate', {'id': project.id})}}) %}
{% endif %}
{% if is_granted('permissions', project) %}
{% set class = '' %}
@@ -47,7 +48,7 @@
{% if is_granted('create_activity') and project.visible and project.customer.visible %}
{% set actions = actions|merge({'create-activity': path('admin_activity_create_with_project', {'project': project.id})}) %}
{% endif %}
{% if view == 'index' and is_granted('delete', project) %}
{% if (view == 'index' or view == 'custom') and is_granted('delete', project) %}
{% set actions = actions|merge({'trash': {'url': path('admin_project_delete', {'id': project.id}), 'class': 'modal-ajax-form'}}) %}
{% endif %}
{% endif %}