{% extends "@ChillMain/layout.html.twig" %} {% block title 'notification.show notification from %sender%'|trans( { '%sender%': notification.sender|chill_entity_render_string } ) ~ ' ' ~ notification.title %} {% block js %} {{ parent() }} {{ encore_entry_script_tags('mod_notification_toggle_read_status') }} {% endblock %} {% block css %} {{ parent() }} {{ encore_entry_link_tags('mod_notification_toggle_read_status') }} {% endblock %} {% import '@ChillPerson/AccompanyingCourse/Comment/macro_showItem.html.twig' as m %} {% macro recordAction(comment) %} {% if is_granted('CHILL_MAIN_NOTIFICATION_COMMENT_EDIT', comment) %}
  • {% endif %} {% endmacro %} {% block content %}

    {{ 'notification.Notification'|trans }}

    {% include 'ChillMainBundle:Notification:_list_item.html.twig' with { 'data': { 'template': handler.getTemplate(notification), 'template_data': handler.getTemplateData(notification) }, 'action_button': false, 'full_content': true } %}

    {{ 'notification.comments_list'|trans }}

    {% if notification.comments|length > 0 %}
    {% for comment in notification.comments %} {% if editedCommentForm is null or editedCommentId != comment.id %} {{ m.show_comment(comment, { 'recordAction': _self.recordAction(comment) }) }} {% else %}
    {{ form_start(editedCommentForm) }} {{ form_errors(editedCommentForm) }} {{ form_widget(editedCommentForm.content) }} {{ form_end(editedCommentForm) }}
    {% endif %} {% endfor %}
    {% endif %} {% if appendCommentForm is not null %}

    {{ 'Write a new comment'|trans }}

    {{ form_start(appendCommentForm) }} {{ form_errors(appendCommentForm) }} {{ form_widget(appendCommentForm.content) }}
    {{ form_end(appendCommentForm) }}
    {% endif %}
    {% endblock content %}