{% extends 'dashboard/base.twig' %} {% block title %}Catalogue Devis{% endblock %} {% block title_header %}Gestion des Devis & Offres{% endblock %} {% block actions %}
Nouveau Devis
{% endblock %} {% block body %}
{% for quote in quotes %} {# RÉFÉRENCE #} {# CLIENT #} {# DATE #} {# STATUT DYNAMIQUE #} {# MONTANT #} {# ACTIONS #} {% else %} {% endfor %}
Référence Client Date Statut Total HT Actions
{{ quote.ref|default('DEV-' ~ quote.id|upper) }} ID: #{{ quote.id }}
{{ quote.customer.surname|upper }} {{ quote.customer.name }} {{ quote.customer.phone|default(quote.customer.email) }}
{{ quote.createa|date('d/m/Y') }} {% set statusClasses = { 'draft': 'text-slate-400 bg-slate-500/10 border-slate-500/20', 'created_waitsign': 'text-amber-400 bg-amber-500/10 border-amber-500/20', 'refusée': 'text-rose-400 bg-rose-500/10 border-rose-500/20', 'signed': 'text-emerald-400 bg-emerald-500/10 border-emerald-500/20', 'signée': 'text-emerald-400 bg-emerald-500/10 border-emerald-500/20' } %} {% set statusLabels = { 'draft': 'Brouillon', 'created_waitsign': 'Attente Signature', 'refusée': 'Refusé', 'signed': 'Signé', 'signée': 'Signé' } %} {% set currentStatus = quote.state|lower %} {% if currentStatus == 'created_waitsign' %} {% elseif currentStatus == 'signed' or currentStatus == 'signée' %} {% endif %} {{ statusLabels[currentStatus] ?? currentStatus }} {{ (quote|totalQuoto)|number_format(2, ',', ' ') }}€
{# Renvoyer lien de signature #} {% if quote.state == "created_waitsign" and quote.state == "wait-send" %} {% endif %} {# Modifier : Interdit si signé #} {% if quote.state != "signed" and quote.state != "signée" %} {% endif %} {# PDF Conditionnel #} {% if quote.state == "signed" or quote.state == "signée" %} {# PDF Signé #} {# Certificat Audit #} Créer le contrat {% else %} {# PDF Brouillon #} {% endif %} {# Delete : Interdit si signé #} {% if quote.state != "signed" and quote.state != "signée" %} {% else %}
{% endif %}

Aucun devis trouvé

{# PAGINATION #} {% if quotes.getTotalItemCount is defined and quotes.getTotalItemCount > quotes.getItemNumberPerPage %}
{{ knp_pagination_render(quotes) }}
{% endif %} {% endblock %}