diff --git a/templates/teamer/disposition/detail.html.twig b/templates/teamer/disposition/detail.html.twig index 865f5e7..5e42cf3 100644 --- a/templates/teamer/disposition/detail.html.twig +++ b/templates/teamer/disposition/detail.html.twig @@ -43,11 +43,28 @@ {% endfor %} {% endif %} + {# Upload contract #} {% if workflow_has_marked_place(disposition, 'new') %}

Honorarvertrag

+ + + {# Existing upload has been rejected #} + {% set contract = disposition.documentByType('contract') %} + {% if contract and contract.status == constant('App\\Entity\\Upload::STATUS_REJECTED') %} + {% include '_partials/_errorbox.html.twig' with { + 'message': 'Dein Honorarvertrag muss überarbeitet werden' + } %} + {% if contract.comment %} +
+ Begründung: {{ contract.comment|nl2br }} +
+ {% endif %} + {% endif %} + + {# New upload #} {% if workflow_can(disposition, 'upload_contract') %}
@@ -117,6 +134,19 @@
Wir prüfen das Dokument schnellstmöglich.
+ + {# Existing upload is being checked #} + {% set contract = disposition.documentByType('contract') %} + {% if contract and contract.status == constant('App\\Entity\\Upload::STATUS_PENDING') %} + {% include '_partials/_infobox.html.twig' with { + 'message': 'Dein Honorarvertrag befindet sich in Bearbeitung' + } %} + {% if contract.comment %} +
+ Begründung: {{ contract.comment|nl2br }} +
+ {% endif %} + {% endif %} {% endif %} {# Invoice uploaded #}