Files
ninedad/templates/home/home.html.twig
2025-08-05 22:37:43 +02:00

38 lines
1.3 KiB
Twig

{% extends 'base.html.twig' %}
{%block body%}
<h2>Projets</h2>
<a href="{{ path('app_user_project_submit') }}" class="btn btn-success mb-3">Ajouter</a>
<div class='d-flex flex-wrap' style='justify-content: left'>
{% for project in projects %}
{% if is_granted('VIEW', project) %}
<div class='card' style='width:300px; margin-right:10px;'>
<div class='card-header d-flex justify-content-between align-items-center'>
<h5>{{project.title}}</h5>
<div>
<a href="{{ path("app_user_project_view",{id:project.id}) }}" class="btn btn-secondary btn-sm"><i class="fas fa-eye"></i></a>
</div>
</div>
<div class='card-body'>
{{project.summary|nl2br}}
</div>
<div class='card-footer'>
<small><em>
<b>Statut</b> = {{ project.status }}<br>
<b>Propriétaires</b> =
{%for user in project.users%}
{{loop.first ? user.username : ' - '~user.username}}
{%endfor%}
</em></small>
</div>
</div>
{% endif %}
{% endfor %}
</div>
{%endblock%}