resume page: move notify button in masonry bloc and notification list below in content

This commit is contained in:
Mathieu Jaumotte 2022-01-28 15:21:44 +01:00
parent 2c57eab4d2
commit 7f41f14959
2 changed files with 29 additions and 12 deletions

View File

@ -1,4 +1,4 @@
<h1 class="mt-5">{{ 'notification.Notifications'|trans }}</h1>
<h1 class="mt-5"><a id="notification-list"></a>{{ 'notification.Notifications'|trans }}</h1>
<div class="flex-table accordion accordion-flush" id="notification-fold">
{% for notification in notifications %}

View File

@ -184,7 +184,26 @@
</div>
</div>
{% endif %}
<div class="mbloc col col-sm-6 col-lg-4">
<div class="notification-counter">
<h4 class="item-key">{{ 'notification.Notifications'|trans }}</h4>
{% set notif_counter = chill_count_notifications('Chill\\PersonBundle\\Entity\\AccompanyingPeriod', accompanyingCourse.id) %}
{% if notif_counter.total > 0 %}
<div class="my-2">
<a href="#notification-list">
{{ chill_counter_notifications('Chill\\PersonBundle\\Entity\\AccompanyingPeriod', accompanyingCourse.id) }}
</a>
</div>
{% endif %}
<div class="d-grid gap-2">
<a class="btn btn-misc" href="{{ chill_path_add_return_path('chill_main_notification_create', {'entityClass': 'Chill\\PersonBundle\\Entity\\AccompanyingPeriod', 'entityId': accompanyingCourse.id}) }}">
<i class="fa fa-paper-plane fa-fw"></i>
{{ 'notification.Notify'|trans }}
</a>
</div>
</div>
</div>
</div>
<div class="social-actions my-4">
@ -210,18 +229,16 @@
{% include 'ChillActivityBundle:Activity:list_recent.html.twig' with { 'context': 'accompanyingCourse', 'no_action': true } %}
</div>
{% endblock %}
<div class="notification notification-list">
{% set notifications = chill_list_notifications('Chill\\PersonBundle\\Entity\\AccompanyingPeriod', accompanyingCourse.id) %}
{% if notifications is not empty %}
{{ notifications|raw }}
{% endif %}
</div>
</div>
{% endblock %}
{% block block_post_menu %}
<div class="post-menu pt-4">
<div class="d-grid gap-2">
<a class="btn btn-primary" href="{{ chill_path_add_return_path('chill_main_notification_create', {'entityClass': 'Chill\\PersonBundle\\Entity\\AccompanyingPeriod', 'entityId': accompanyingCourse.id}) }}">
<i class="fa fa-paper-plane fa-fw"></i>
{{ 'notification.Notify'|trans }}
</a>
</div>
{{ chill_list_notifications('Chill\\PersonBundle\\Entity\\AccompanyingPeriod', accompanyingCourse.id) }}
</div>
<div class="post-menu pt-4"></div>
{% endblock %}