diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_item.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_item.html.twig index 76c61407d..2a6dea8a1 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_item.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_item.html.twig @@ -5,7 +5,8 @@ # - displayAction: [true|false] default: false # - displayFontSmall: [true|false] default: false #} -
+

@@ -111,8 +112,9 @@

{% if displayContent is not defined or displayContent == 'short' %} -
- {% include 'ChillPersonBundle:AccompanyingCourseWork:_objectifs_results_evaluations.html.twig' with { +
+ {% include '@ChillPerson/AccompanyingCourseWork/_objectifs_results_evaluations.html.twig' with { 'displayContent': displayContent } %}
@@ -121,42 +123,43 @@ {% if displayContent is not defined or displayContent == 'short' %}
- {% import '@ChillPerson/AccompanyingCourseWork/_macros.html.twig' as macro %} + {% import '@ChillPerson/AccompanyingCourseWork/_macros.html.twig' as macro %}
{{ macro.metadata(w) }}
{% if displayAction is defined and displayAction == true %} -
    +
      + {% if displayNotification is defined and displayNotification == true %} +
    • + -
    • - - - -
    • -
    • {{ macro.workflowButton(w) }}
    • -
    • - -
    • - {% if is_granted('CHILL_MAIN_ACCOMPANYING_PERIOD_WORK_UPDATE', w) %} + + + {% endif %} +
    • {{ macro.workflowButton(w) }}
    • -
    • - {% endif %} - {% if is_granted('CHILL_MAIN_ACCOMPANYING_PERIOD_WORK_DELETE', w) %} -
    • - -
    • - {% endif %} -
    + {% if is_granted('CHILL_MAIN_ACCOMPANYING_PERIOD_WORK_UPDATE', w) %} +
  • + +
  • + {% endif %} + {% if is_granted('CHILL_MAIN_ACCOMPANYING_PERIOD_WORK_DELETE', w) %} +
  • + +
  • + {% endif %} +
{% endif %}
{% endif %} @@ -164,47 +167,50 @@
{# - # This is for 'long' version of content - # Note: this include is wrapped in a flex-table container. - # We start by closing the flex-table so we can add more. - # At the end we leave the last flex-table open, as it will be closed in the container. +# This is for 'long' version of content +# Note: this include is wrapped in a flex-table container. +# We start by closing the flex-table so we can add more. +# At the end we leave the last flex-table open, as it will be closed in the container. #} {% if displayContent is defined and displayContent == 'long' %} +
+ +{% if w.results|length > 0 or w.goals|length > 0 or w.accompanyingPeriodWorkEvaluations|length > 0 %} +

{{ 'Dispositifs' }}

+ +
{# new flex-table wrapper #} +
+ {% include 'ChillPersonBundle:AccompanyingCourseWork:_objectifs_results_evaluations.html.twig' with { + 'displayContent': displayContent + } %} +
+{% endif %} - {% if w.results|length > 0 or w.goals|length > 0 or w.accompanyingPeriodWorkEvaluations|length > 0 %} -

{{ 'Dispositifs' }}

+

{{ 'Comments'|trans }}

-
{# new flex-table wrapper #} -
- {% include 'ChillPersonBundle:AccompanyingCourseWork:_objectifs_results_evaluations.html.twig' with { - 'displayContent': displayContent - } %} -
+
+
+

Public

+ {% if w.note is not empty %} +
+ {{ w.note|chill_entity_render_box({'metadata': true }) }} +
+ {% else %} + {{ 'No comment associated'|trans }} + {% endif %} +
+ {% if w.privateComment.hasCommentForUser(app.user) %} +
+

Privé

+
+ {{ w.privateComment.commentForUser(app.user)|chill_markdown_to_html }} +
{% endif %} - -

{{ 'Comments'|trans }}

- -
-
-

Public

- {% if w.note is not empty %} -
- {{ w.note|chill_entity_render_box({'metadata': true }) }} -
- {% else %} - {{ 'No comment associated'|trans }} - {% endif %} -
- {% if w.privateComment.hasCommentForUser(app.user) %} -
-

Privé

-
- {{ w.privateComment.commentForUser(app.user)|chill_markdown_to_html }} -
-
- {% endif %} {# Here flex-table stay open ! read above #} -{% endif %} + {% endif %} diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_objectifs_results_evaluations.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_objectifs_results_evaluations.html.twig index 4f5d36230..e66dde463 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_objectifs_results_evaluations.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/_objectifs_results_evaluations.html.twig @@ -118,9 +118,15 @@ {% endif %} {% endif %} + + + {% if recordAction is defined %} + {{ recordAction }} + {% endif %} + {% if displayContent is defined and displayContent == 'long' %} {% if e.comment is not empty %} @@ -136,9 +142,9 @@ {{ d.title }} {{ mm.mimeIcon(d.storedObject.type) }} - - - + + + {{ d.storedObject|chill_document_button_group(d.title, is_granted('CHILL_MAIN_ACCOMPANYING_PERIOD_WORK_UPDATE', w), {'small': true}) }} {% endfor %} diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/index.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/index.html.twig index 9214bd30d..ab1989f63 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/index.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/index.html.twig @@ -26,7 +26,8 @@ 'displayAction': true, 'displayContent': 'short', 'displayFontSmall': true, - 'itemBlocClass': '' + 'itemBlocClass': '', + 'displayNotification': true } %} {% endfor %}
diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/show.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/show.html.twig index 73b871260..96b47e6c9 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/show.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/show.html.twig @@ -43,10 +43,10 @@ {% else %} diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showEvaluationDocumentInNotification.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showEvaluationDocumentInNotification.html.twig index f4c9c1bf7..6d5d22a7d 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showEvaluationDocumentInNotification.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showEvaluationDocumentInNotification.html.twig @@ -1,8 +1,17 @@ {% macro recordAction(document) %} -
  • - -
  • + {% import "@ChillDocStore/Macro/macro_mimeicon.html.twig" as mm %} +
    + + + + + + + +
    {{ document.title }}{{ mm.mimeIcon(document.storedObject.type) }}
    +
    {% endmacro %} {% if document is not null %} diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showInNotification.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showInNotification.html.twig index 4ee561381..9b06e306c 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showInNotification.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourseWork/showInNotification.html.twig @@ -1,7 +1,8 @@ {% macro recordAction(work) %}
  • - +
  • {% endmacro %} {% if work is not null %} @@ -12,6 +13,7 @@ 'displayAction': true, 'displayContent': 'short', 'displayFontSmall': true, + 'displayNotification:':true, 'w': work } %} {% else %}