fix missing div in accompanying course work list

This commit is contained in:
Julien Fastré 2021-06-28 23:48:06 +02:00 committed by nobohan
parent 0135f5184e
commit 2688c0f0ce
3 changed files with 81 additions and 76 deletions

View File

@ -222,90 +222,94 @@
<h2>{{ 'Social actions'|trans }}</h2>
{% for w in works %}
<div class="item">
<div class="title">
<h2 class="action_title">
{{ w.socialAction|chill_entity_render_box({ 'no-badge': false }) }}
</h2>
</div>
<div class="timeline">
<ul class="timeline">
<li class="completed">
<div class="date">
<span>{{ w.createdAt|format_date('long') }}</span>
</div>
<div class="label">
<span>{{ 'accompanying_course_work.create_date'|trans }}</span>
</div>
</li>
<li class="completed">
<div class="date">
<span>{{ w.startDate|format_date('long') }}</span>
</div>
<div class="label">
<span>{{ 'accompanying_course_work.start_date'|trans }}</span>
</div>
</li>
<li class="{%if date(w.endDate) < date('now') %}completed{% endif %}">
<div class="date">
<span>{{ w.endDate|format_date('long') }}</span>
</div>
<div class="label">
<span>{{ 'accompanying_course_work.end_date'|trans }}</span>
</div>
</li>
</ul>
</div>
{% if w.results|length > 0 %}
<div class="objective_results objective_results__without-objectives">
<div class="obj without_objective">
<p class="title_label">{{ 'accompanying_course_work.goal'|trans }}</p>
<p class="chill-no-data-statement">{{ 'accompanying_course_work.results without objective'|trans }}</p>
</div>
<div class="res results">
<p class="title_label">{{ 'accompanying_course_work.results'|trans }}</p>
<ul class="result_list">
{% for r in w.results %}
<li class="badge badge-primary">{{ r.title|localize_translatable_string }}</li>
{% endfor %}
</ul>
</div>
<div id="accompanying_course_work_list">
{% for w in works %}
<div class="item">
<div class="title">
<h2 class="action_title">
{{ w.socialAction|chill_entity_render_box({ 'no-badge': false }) }}
</h2>
</div>
{% endif %}
{% if w.goals|length > 0 %}
{% for g in w.goals %}
<div class="objective_results objective_results--with-objectives">
<div class="objective obj">
<div class="timeline">
<ul class="timeline">
<li class="completed">
<div class="date">
<span>{{ w.createdAt|format_date('long') }}</span>
</div>
<div class="label">
<span>{{ 'accompanying_course_work.create_date'|trans }}</span>
</div>
</li>
<li class="completed">
<div class="date">
<span>{{ w.startDate|format_date('long') }}</span>
</div>
<div class="label">
<span>{{ 'accompanying_course_work.start_date'|trans }}</span>
</div>
</li>
<li class="{%if date(w.endDate) < date('now') %}completed{% endif %}">
<div class="date">
<span>{{ w.endDate|format_date('long') }}</span>
</div>
<div class="label">
<span>{{ 'accompanying_course_work.end_date'|trans }}</span>
</div>
</li>
</ul>
</div>
{% if w.results|length > 0 %}
<div class="objective_results objective_results__without-objectives">
<div class="obj without_objective">
<p class="title_label">{{ 'accompanying_course_work.goal'|trans }}</p>
<h3 class="goal_title">{{ g.goal.title|localize_translatable_string }}</h3>
<p class="chill-no-data-statement">{{ 'accompanying_course_work.results without objective'|trans }}</p>
</div>
<div class="results res">
{% if g.results|length == 0 %}
<p class="title_label">{{ 'accompanying_course_work.results'|trans }}</p>
<p class="chill-no-data-statement">{{ 'accompanying_course_work.no_results'|trans }}</p>
{% else %}
<p class="title_label">{{ 'accompanying_course_work.results'|trans }}</p>
<ul class="result_list">
{% for r in g.results %}
<li class="badge badge-primary">{{ r.title|localize_translatable_string }}</li>
{% endfor %}
</ul>
{% endif %}
<div class="res results">
<p class="title_label">{{ 'accompanying_course_work.results'|trans }}</p>
<ul class="result_list">
{% for r in w.results %}
<li class="badge badge-primary">{{ r.title|localize_translatable_string }}</li>
{% endfor %}
</ul>
</div>
</div>
{% endfor %}
{% endif %}
{% endif %}
<div class="updatedBy">
{{ 'Last updated by'|trans}}: {{ w.updatedBy|chill_entity_render_box }}, {{ w.updatedAt|format_datetime('long', 'short') }}
</div>
{% if w.goals|length > 0 %}
{% for g in w.goals %}
<div class="objective_results objective_results--with-objectives">
<div class="objective obj">
<p class="title_label">{{ 'accompanying_course_work.goal'|trans }}</p>
<h3 class="goal_title">{{ g.goal.title|localize_translatable_string }}</h3>
</div>
<div class="results res">
{% if g.results|length == 0 %}
<p class="title_label">{{ 'accompanying_course_work.results'|trans }}</p>
<p class="chill-no-data-statement">{{ 'accompanying_course_work.no_results'|trans }}</p>
{% else %}
<p class="title_label">{{ 'accompanying_course_work.results'|trans }}</p>
<ul class="result_list">
{% for r in g.results %}
<li class="badge badge-primary">{{ r.title|localize_translatable_string }}</li>
{% endfor %}
</ul>
{% endif %}
</div>
</div>
{% endfor %}
{% endif %}
<div class="updatedBy">
{{ 'Last updated by'|trans}}: {{ w.updatedBy|chill_entity_render_box }}, {{ w.updatedAt|format_datetime('long', 'short') }}
</div>
</div>
{% else %}
<p class="chill-no-data-statement">{{ 'accompanying_course_work.Any work'|trans }}</p>
{% endfor %}
</div>
{% endfor %}
{% block contentActivity %}

View File

@ -102,7 +102,7 @@
</div>
</div>
{% else %}
<p class="chill-no-data-statement">{{ 'accompanying_course_work.No work'|trans }}</p>
<p class="chill-no-data-statement">{{ 'accompanying_course_work.Any work'|trans }}</p>
{% endfor %}
</div>

View File

@ -357,4 +357,5 @@ accompanying_course_work:
no_results: Aucun résultat - orientation
results: Résultats - orientations
goal: Objectif - motif - dispositif
Any work: Aucune action d'accompagnement