mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 23:23:51 +00:00
controller + template made to list confirmed parcours for a specific user
This commit is contained in:
@@ -0,0 +1,80 @@
|
||||
{% extends 'ChillMainBundle::layout.html.twig' %}
|
||||
|
||||
{% block title "Liste de parcours à réassigner" %}
|
||||
|
||||
{% block js %}
|
||||
{{ encore_entry_script_tags('mod_set_referrer') }}
|
||||
{% endblock %}
|
||||
|
||||
{% block css %}
|
||||
{{ encore_entry_link_tags('mod_set_referrer') }}
|
||||
{% endblock %}
|
||||
|
||||
{# {% macro period_meta(period) %}
|
||||
{% if is_granted('CHILL_PERSON_ACCOMPANYING_PERIOD_UPDATE', period) %}
|
||||
<div class="item-col item-meta">
|
||||
{% set job_id = null %}
|
||||
{% if period.job is defined %}
|
||||
{% set job_id = period.job.id %}
|
||||
{% endif %}
|
||||
<span
|
||||
data-set-referrer-app="data-set-referrer-app"
|
||||
data-set-referrer-accompanying-period-id="{{ period.id }}"
|
||||
data-set-referrer-job-id="{{ job_id }}"
|
||||
></span>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endmacro %} #}
|
||||
|
||||
{% macro period_actions(period) %}
|
||||
{% if is_granted('CHILL_PERSON_ACCOMPANYING_PERIOD_SEE', period) %}
|
||||
<li>
|
||||
<a href="{{ chill_path_add_return_path('chill_person_accompanying_course_index', {'accompanying_period_id': period.id}) }}" class="btn btn-show"></a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% import _self as m %}
|
||||
|
||||
{% block content %}
|
||||
<div class="col-10">
|
||||
<h1>{{ block('title') }}</h1>
|
||||
|
||||
{{ form_start(form) }}
|
||||
<div class="row filter-box" style="padding: 2rem 2rem 2rem 0;">
|
||||
<div class="col-md-6" style="display: flex; justify-content: space-between;">
|
||||
{{ form_label(form.user ) }}
|
||||
{{ form_widget(form.user, {'attr': {'class': 'select2'}}) }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ul class="record_actions">
|
||||
<li>
|
||||
<button type="submit" class="btn btn-save change-icon">
|
||||
<i class="fa fa-filter"></i> Filtrer
|
||||
</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
{{ form_end(form) }}
|
||||
|
||||
{% if form.user.vars.value is empty %}
|
||||
<p class="chill-no-data-statement">Choisissez un référent pour afficher ses parcours.</p>
|
||||
{% elseif periods|length == 0 and form.user.vars.value is not empty %}
|
||||
<p class="chill-no-data-statement">Aucun parcour à réassigner pour cet utilisateur.</p>
|
||||
{% else %}
|
||||
<p><span class="badge rounded-pill bg-primary">Amount of</span> parcours à réassigner (calculé ce jour à {{ null|format_time('medium') }})</p>
|
||||
|
||||
<div class="flex-table">
|
||||
{% for period in periods %}
|
||||
{% include '@ChillPerson/AccompanyingPeriod/_list_item.html.twig' with {'period': period,
|
||||
'recordAction': m.period_actions(period) } %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{# {{ chill_pagination(paginator) }} #}
|
||||
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
Reference in New Issue
Block a user