diff --git a/sources/AppBundle/Controller/Admin/Accounting/Invoice/ListInvoiceAction.php b/sources/AppBundle/Controller/Admin/Accounting/Invoice/ListInvoiceAction.php index d6f7a1cb1..469b9f29f 100644 --- a/sources/AppBundle/Controller/Admin/Accounting/Invoice/ListInvoiceAction.php +++ b/sources/AppBundle/Controller/Admin/Accounting/Invoice/ListInvoiceAction.php @@ -4,6 +4,7 @@ namespace AppBundle\Controller\Admin\Accounting\Invoice; +use Afup\Site\Utils\Vat; use AppBundle\Accounting\Form\InvoicingPeriodType; use AppBundle\Accounting\InvoicingPaymentStatus; use AppBundle\Accounting\Model\Invoicing; @@ -52,6 +53,7 @@ public function __invoke(Request $request): Response 'direction' => $direction, 'sort' => $sort, 'totalHt' => $totalHt, + 'isSubjectedToVat' => Vat::isSubjectedToVat($period->getEndDate()), ])); } } diff --git a/sources/AppBundle/Controller/Admin/Accounting/Quotation/ListQuotationAction.php b/sources/AppBundle/Controller/Admin/Accounting/Quotation/ListQuotationAction.php index 14b40ec0d..34218afc5 100644 --- a/sources/AppBundle/Controller/Admin/Accounting/Quotation/ListQuotationAction.php +++ b/sources/AppBundle/Controller/Admin/Accounting/Quotation/ListQuotationAction.php @@ -4,6 +4,7 @@ namespace AppBundle\Controller\Admin\Accounting\Quotation; +use Afup\Site\Utils\Vat; use AppBundle\Accounting\Form\InvoicingPeriodType; use AppBundle\Accounting\Model\Repository\InvoicingRepository; use AppBundle\Accounting\Model\Repository\InvoicingPeriodRepository; @@ -38,6 +39,7 @@ public function __invoke(Request $request): Response 'formPeriod' => $formPeriod->createView(), 'direction' => $direction, 'sort' => $sort, + 'isSubjectedToVat' => Vat::isSubjectedToVat($period->getEndDate()), ])); } } diff --git a/templates/admin/accounting/invoice/list.html.twig b/templates/admin/accounting/invoice/list.html.twig index 98eeb84d1..2ab9cc79c 100644 --- a/templates/admin/accounting/invoice/list.html.twig +++ b/templates/admin/accounting/invoice/list.html.twig @@ -17,7 +17,6 @@ - - + - - + + {% for line in lines %} - @@ -91,7 +91,7 @@
Année Date @@ -29,17 +28,18 @@ VilleNumero factureNuméro facture Référence clientEtat paiementPrixÉtat paiement + Montant{% if isSubjectedToVat %} HT{% endif %} +
{{ line.quotationDate|date('Y') }} {{ line.quotationDate|format_date('short') }} {{ line.company }} {{ line.city }}
- Total facturé en HT sur cette période : {{ totalHt|number_format(2, ',', ' ') }} € + Total facturé {% if isSubjectedToVat %}en HT{% endif %} sur cette période : {{ totalHt|number_format(2, ',', ' ') }} €
{% else %}
diff --git a/templates/admin/accounting/quotation/list.html.twig b/templates/admin/accounting/quotation/list.html.twig index 9a112d3d0..f470fcf96 100644 --- a/templates/admin/accounting/quotation/list.html.twig +++ b/templates/admin/accounting/quotation/list.html.twig @@ -31,8 +31,10 @@ Ville Ref client - Numero devis - Prix + Numéro devis + + Montant{% if isSubjectedToVat %} HT{% endif %} + Facturé ?   @@ -42,7 +44,7 @@ {{ line.quotationDate|format_date('short') }} {{ line.company }} - {{ line.city }} + {{ line.city }} {{ line.refClt1 }} {{ line.quotationNumber }} {{ line.price|number_format(2, ',', ' ') }}