Notification: add a counter for notifications

This commit is contained in:
2022-01-04 16:44:01 +01:00
parent 5bb5468198
commit 3a207b2c5d
12 changed files with 211 additions and 29 deletions

View File

@@ -60,15 +60,29 @@
{% if not notification.isReadBy(app.user) %}
<div class="badge bg-danger">{{ 'notification.is_unread'|trans }}</div>
{% endif %}
{% if notification.isSystem %}
<div class="badge bg-chill-green">{{ 'notification.is_system'|trans }}</div>
{% endif %}
</h2>
</div>
<div class="item-row">
<div class="item-col">
{% if step == 'inbox' %}
{{ 'notification.from'|trans }}: {{ notification.sender|chill_entity_render_string }}
{% if step == 'inbox' and not notification.isSystem %}
{{ 'notification.from'|trans }}: {{ notification.sender|chill_entity_render_string }}
{% else %}
&nbsp;
{% endif %}
</div>
<div class="item-col">{{ 'notification.adressees'|trans }}{% for a in notification.addressees %}{{ a|chill_entity_render_string }}{% if not loop.last %}, {% endif %}{% endfor %}</div>
<div class="item-col">{{ 'notification.adressees'|trans }}
<ul>
{% for a in notification.addressees %}
<li>
{{ a|chill_entity_render_string }}
</li>
{% endfor %}
</ul>
</div>
<div class="item-col">{{ notification.date|format_datetime('long', 'short') }}</div>
</div>
<div class="item-row">

View File

@@ -65,7 +65,7 @@
{% endfor %}
{% endif %}
{% if appendCommentForm is defined %}
{% if appendCommentForm is not null %}
<div>
{{ form_start(appendCommentForm) }}
{{ form_widget(appendCommentForm) }}