#365 Add works and activities counter

This commit is contained in:
juminet
2025-04-14 09:34:02 +00:00
committed by Julien Fastré
parent 1c1f418b18
commit 40e373a9c7
9 changed files with 92 additions and 13 deletions

View File

@@ -304,5 +304,14 @@ div#dashboards {
margin: 0;
}
}
div.count-item {
font-size: 3rem;
text-align: center;
}
div.count-item-label {
font-size: 90%;
font-variant: all-small-caps;
text-align: center;
}
}
}

View File

@@ -201,7 +201,7 @@
{% endif %}
{% if accompanyingCourse.step != 'DRAFT' %}
<div class="mbloc col col-sm-6 col-lg-4">
<div class="mbloc col col-sm-6 col-lg-8 col-xxl-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) %}
@@ -238,6 +238,31 @@
</div>
</div>
{% endif %}
{% if counters.activities > 0 %}
<div class="mbloc col col-sm-6 col-lg-4">
<div class="count-activities">
<div class="count-item">{{ counters.activities }}</div>
<div class="count-item-label">
{% if counters.activities == 1 %}
{{ 'Activity'|trans }}
{% else %}
{{ 'Activities'|trans }}
{% endif %}
</div>
</div>
</div>
{% endif %}
{% if counters.works > 0 %}
<div class="mbloc col col-sm-6 col-lg-4">
<div class="count-works">
<div class="count-item">{{ counters.openWorks }} / {{ counters.works }}</div>
<div class="count-item-label">{{ 'accompanying_course_work.On-going works over total'|trans }}</div>
</div>
</div>
{% endif %}
</div>
<div class="social-actions my-4">