Réalisation finale
This commit is contained in:
64
templates/contribution/edit.html.twig
Normal file
64
templates/contribution/edit.html.twig
Normal file
@@ -0,0 +1,64 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block title %}Modifier Contribution{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<div class="d-flex justify-content-between align-items-center mb-4">
|
||||
<h1>Modifier Contribution</h1>
|
||||
<div>
|
||||
<a href="{{ path('app_contribution_show', {'id': contribution.id}) }}" class="btn btn-info">
|
||||
<i class="fas fa-eye"></i> Voir
|
||||
</a>
|
||||
<a href="{{ path('app_contribution_index') }}" class="btn btn-secondary">
|
||||
<i class="fas fa-arrow-left"></i> Retour à la liste
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
{{ form_start(form) }}
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.membre) }}
|
||||
{{ form_widget(form.membre) }}
|
||||
{{ form_errors(form.membre) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.projet) }}
|
||||
{{ form_widget(form.projet) }}
|
||||
{{ form_errors(form.projet) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.dateContribution) }}
|
||||
{{ form_widget(form.dateContribution) }}
|
||||
{{ form_errors(form.dateContribution) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.duree) }}
|
||||
{{ form_widget(form.duree) }}
|
||||
{{ form_errors(form.duree) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.commentaire) }}
|
||||
{{ form_widget(form.commentaire) }}
|
||||
{{ form_errors(form.commentaire) }}
|
||||
</div>
|
||||
|
||||
<div class="d-flex gap-2">
|
||||
<button type="submit" class="btn btn-success">
|
||||
<i class="fas fa-save"></i> Enregistrer
|
||||
</button>
|
||||
<a href="{{ path('app_contribution_index') }}" class="btn btn-secondary">Annuler</a>
|
||||
</div>
|
||||
{{ form_end(form) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
52
templates/contribution/index.html.twig
Normal file
52
templates/contribution/index.html.twig
Normal file
@@ -0,0 +1,52 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block title %}Contributions{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<div class="d-flex justify-content-between align-items-center mb-4">
|
||||
<h1>Contributions</h1>
|
||||
<a href="{{ path('app_contribution_new') }}" class="btn btn-success">
|
||||
<i class="fas fa-plus"></i> Nouvelle Contribution
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Id</th>
|
||||
<th>Membre</th>
|
||||
<th>Projet</th>
|
||||
<th>Date</th>
|
||||
<th>Durée</th>
|
||||
<th>Commentaire</th>
|
||||
<th>Actions</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for contribution in contributions %}
|
||||
<tr>
|
||||
<td>{{ contribution.id }}</td>
|
||||
<td>{{ contribution.membre }}</td>
|
||||
<td>{{ contribution.projet.nom }}</td>
|
||||
<td>{{ contribution.dateContribution|date('d/m/Y') }}</td>
|
||||
<td>{{ contribution.dureeFormatee }}</td>
|
||||
<td>{{ contribution.commentaire|default('')|slice(0, 50) }}{% if contribution.commentaire|length > 50 %}...{% endif %}</td>
|
||||
<td>
|
||||
<a href="{{ path('app_contribution_show', {'id': contribution.id}) }}" class="btn btn-sm btn-info">
|
||||
<i class="fas fa-eye"></i> Voir
|
||||
</a>
|
||||
<a href="{{ path('app_contribution_edit', {'id': contribution.id}) }}" class="btn btn-sm btn-warning">
|
||||
<i class="fas fa-edit"></i> Modifier
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td colspan="7" class="text-center">Aucune contribution trouvée</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{% endblock %}
|
||||
59
templates/contribution/new.html.twig
Normal file
59
templates/contribution/new.html.twig
Normal file
@@ -0,0 +1,59 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block title %}Nouvelle Contribution{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<div class="d-flex justify-content-between align-items-center mb-4">
|
||||
<h1>Nouvelle Contribution</h1>
|
||||
<a href="{{ path('app_contribution_index') }}" class="btn btn-secondary">
|
||||
<i class="fas fa-arrow-left"></i> Retour à la liste
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
{{ form_start(form) }}
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.membre) }}
|
||||
{{ form_widget(form.membre) }}
|
||||
{{ form_errors(form.membre) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.projet) }}
|
||||
{{ form_widget(form.projet) }}
|
||||
{{ form_errors(form.projet) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.dateContribution) }}
|
||||
{{ form_widget(form.dateContribution) }}
|
||||
{{ form_errors(form.dateContribution) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.duree) }}
|
||||
{{ form_widget(form.duree) }}
|
||||
{{ form_errors(form.duree) }}
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
{{ form_label(form.commentaire) }}
|
||||
{{ form_widget(form.commentaire) }}
|
||||
{{ form_errors(form.commentaire) }}
|
||||
</div>
|
||||
|
||||
<div class="d-flex gap-2">
|
||||
<button type="submit" class="btn btn-success">
|
||||
<i class="fas fa-save"></i> Créer
|
||||
</button>
|
||||
<a href="{{ path('app_contribution_index') }}" class="btn btn-secondary">Annuler</a>
|
||||
</div>
|
||||
{{ form_end(form) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
117
templates/contribution/show.html.twig
Normal file
117
templates/contribution/show.html.twig
Normal file
@@ -0,0 +1,117 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block title %}Contribution - {{ contribution.membre }}{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<div class="d-flex justify-content-between align-items-center mb-4">
|
||||
<h1>Contribution</h1>
|
||||
<div>
|
||||
<a href="{{ path('app_contribution_edit', {'id': contribution.id}) }}" class="btn btn-warning">
|
||||
<i class="fas fa-edit"></i> Modifier
|
||||
</a>
|
||||
<a href="{{ path('app_contribution_index') }}" class="btn btn-secondary">
|
||||
<i class="fas fa-arrow-left"></i> Retour à la liste
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title mb-0">Informations générales</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<p><strong>ID :</strong> {{ contribution.id }}</p>
|
||||
<p><strong>Membre :</strong>
|
||||
<a href="{{ path('app_membre_show', {'id': contribution.membre.id}) }}">
|
||||
{{ contribution.membre }}
|
||||
</a>
|
||||
</p>
|
||||
<p><strong>Projet :</strong>
|
||||
<a href="{{ path('app_projet_show', {'id': contribution.projet.id}) }}">
|
||||
{{ contribution.projet.nom }}
|
||||
</a>
|
||||
</p>
|
||||
<p><strong>Date :</strong> {{ contribution.dateContribution|date('d/m/Y') }}</p>
|
||||
<p><strong>Durée :</strong> {{ contribution.dureeFormatee }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title mb-0">Commentaire</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% if contribution.commentaire %}
|
||||
<p>{{ contribution.commentaire }}</p>
|
||||
{% else %}
|
||||
<p class="text-muted">Aucun commentaire</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% if contribution.contribIas|length > 0 %}
|
||||
<div class="row mt-4">
|
||||
<div class="col-12">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title mb-0">Évaluations IA</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-sm">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Assistant IA</th>
|
||||
<th>Pertinence</th>
|
||||
<th>Temps</th>
|
||||
<th>Moyenne</th>
|
||||
<th>Commentaire</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for contrib_ia in contribution.contribIas %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{{ path('app_assistant_ia_show', {'id': contrib_ia.assistantIa.id}) }}">
|
||||
{{ contrib_ia.assistantIa.nom }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
{% if contrib_ia.evaluationPertinence %}
|
||||
{{ contrib_ia.libellePertinence }}
|
||||
{% else %}
|
||||
<span class="text-muted">Non évalué</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
{% if contrib_ia.evaluationTemps %}
|
||||
{{ contrib_ia.libelleTemps }}
|
||||
{% else %}
|
||||
<span class="text-muted">Non évalué</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
{% if contrib_ia.moyenneEvaluation %}
|
||||
{{ contrib_ia.moyenneEvaluation }}/5
|
||||
{% else %}
|
||||
<span class="text-muted">Non évalué</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>{{ contrib_ia.commentaire|default('') }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user