feat: ajout onglet Contrats dans la sidebar admin
- Lien Contrats dans la sidebar (entre Clients et Facturation) - Controller ContratController avec route /admin/contrats - Template placeholder avec description du flow futur: creer contrat -> signer -> creation espace client auto Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
19
src/Controller/Admin/ContratController.php
Normal file
19
src/Controller/Admin/ContratController.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
|
||||
namespace App\Controller\Admin;
|
||||
|
||||
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Routing\Attribute\Route;
|
||||
use Symfony\Component\Security\Http\Attribute\IsGranted;
|
||||
|
||||
#[Route('/admin/contrats', name: 'app_admin_contrats_')]
|
||||
#[IsGranted('ROLE_EMPLOYE')]
|
||||
class ContratController extends AbstractController
|
||||
{
|
||||
#[Route('', name: 'index')]
|
||||
public function index(): Response
|
||||
{
|
||||
return $this->render('admin/contrats/index.html.twig');
|
||||
}
|
||||
}
|
||||
@@ -49,6 +49,10 @@
|
||||
<svg class="w-4 h-4 flex-shrink-0" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 20h5v-2a3 3 0 00-5.356-1.857M17 20H7m10 0v-2c0-.656-.126-1.283-.356-1.857M7 20H2v-2a3 3 0 015.356-1.857M7 20v-2c0-.656.126-1.283.356-1.857m0 0a5.002 5.002 0 019.288 0M15 7a3 3 0 11-6 0 3 3 0 016 0z"/></svg>
|
||||
Clients
|
||||
</a>
|
||||
<a href="{{ path('app_admin_contrats_index') }}" class="sidebar-nav-item {{ current_route starts with 'app_admin_contrats' ? 'active' : '' }}">
|
||||
<svg class="w-4 h-4 flex-shrink-0" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"/></svg>
|
||||
Contrats
|
||||
</a>
|
||||
<a href="{{ path('app_admin_facturation_index') }}" class="sidebar-nav-item {{ current_route starts with 'app_admin_facturation' ? 'active' : '' }}">
|
||||
<svg class="w-4 h-4 flex-shrink-0" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 14l6-6m-5.5.5h.01m4.99 5h.01M19 21V5a2 2 0 00-2-2H7a2 2 0 00-2 2v16l3.5-2 3.5 2 3.5-2 3.5 2z"/></svg>
|
||||
Facturation
|
||||
|
||||
26
templates/admin/contrats/index.html.twig
Normal file
26
templates/admin/contrats/index.html.twig
Normal file
@@ -0,0 +1,26 @@
|
||||
{% extends 'admin/_layout.html.twig' %}
|
||||
|
||||
{% block title %}Contrats - Association E-Cosplay{% endblock %}
|
||||
|
||||
{% block admin_content %}
|
||||
<div class="page-container">
|
||||
<div class="flex items-center justify-between mb-6">
|
||||
<h1 class="text-2xl font-bold heading-page">Contrats</h1>
|
||||
</div>
|
||||
|
||||
{% for type, messages in app.flashes %}
|
||||
{% for message in messages %}
|
||||
<div class="mb-4 p-4 glass font-medium text-sm {{ type == 'success' ? 'border-green-300 text-green-800' : 'border-red-300 text-red-800' }}">{{ message }}</div>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
|
||||
<div class="glass p-12 text-center">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="h-16 w-16 mx-auto mb-4 text-gray-300" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="1">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" d="M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z" />
|
||||
</svg>
|
||||
<p class="text-gray-400 font-bold uppercase text-sm tracking-wider mb-2">Contrats</p>
|
||||
<p class="text-gray-300 text-xs">Cette section sera disponible prochainement.</p>
|
||||
<p class="text-gray-300 text-xs mt-1">Creez un contrat, faites-le signer, puis l'espace client sera cree automatiquement.</p>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user