diff --git a/report/account_template.xml b/report/account_template.xml index dd5da6b535c38c619b5fb8e1455bec8273bdf6f5..fba7f7b241e19e49878f4ce5c29ff7ce5f8c5f26 100644 --- a/report/account_template.xml +++ b/report/account_template.xml @@ -193,7 +193,7 @@ </t> <t t-else=""> <div class="page"> - <div class="row mb32"> + <div class="row mb-5"> <div class="col-4"> <t t-if="o.producer_id.image_1920"> <img @@ -202,7 +202,7 @@ alt="Logo" /> </t> - <t t-else=""><h4 t-field="o.producer_id.name" /></t> + <t t-else=""><h4 class="text-center" t-field="o.producer_id.name" /></t> </div> <div class="col-8 text-center"> @@ -220,14 +220,14 @@ t-options="{'format': 'dd/MM/yyyy'}" /></span> </p> - <p>Adressée par voie électronique<br/> - Facture de consommation</p> + <span class="font-mini">Adressée par voie électronique<br/> + Facture de consommation</span> </div> </div> - <div class="row mt32 mb-5"> + <div class="row mt-5 mb-5"> <div class="col-4 grey-div "> - <h5 class="font-weight-bold mb-4 text-center">Vos références utiles</h5> + <h5 class="font-weight-bold mb-3 mt-2 text-center">Vos références utiles</h5> <p> <span class="font-weight-bold" @@ -246,10 +246,8 @@ <t t-if="o.consumer_id.vat"><span class="font-weight-bold" >N°TVA:</span><br /> - <span t-field="o.consumer_id.vat" /> + <span t-field="o.consumer_id.vat" /><br /> </t> - </p> - <p> <span class="font-weight-bold" >Point Référence Mesures (PRM-C):</span><br @@ -268,69 +266,61 @@ t-field="o.acc_delivery_id.city" /><br /></t> </p> - <div> - <p> - <span - class="text-center font-weight-bold" - >Référence de l'opération</span><br - /> - <span - class="font-weight-bold" - >Nom du producteur</span><br /> - <span t-field="o.producer_id.name" /><br /> - <span - class="font-weight-bold" - >Nom de l'opération</span><br /> - <span t-field="o.acc_operation_id.description" /><br /> - <span - class="font-weight-bold" - >Numéro ACC (2)</span><br /> - <span t-field="o.acc_operation_id.name" /><br /> - <span - class="font-weight-bold" - >Références Points d'Injection (PRM-I)</span><br /> - <t t-foreach="o.acc_operation_id.acc_injection_ids" t-as="inj"> - <span t-field="inj.name" /><br /> - </t> - <t t-if="o.producer_id.origine"> - <span - class="font-weight-bold" - >Origine</span><br /> - <span t-field="o.producer_id.origine"/><br/> - </t> - </p> - <h6 class="mt32 font-weight-bold">Pour répondre à vos questions</h6> - <p class="mb-4"> + <h5 class="font-weight-bold mb-3 mt-4 text-center">Référence de l'opération</h5> + <p> + <span + class="font-weight-bold" + >Nom du producteur</span><br /> + <span t-field="o.producer_id.name" /><br /> + <span + class="font-weight-bold" + >Nom de l'opération</span><br /> + <span t-field="o.acc_operation_id.description" /><br /> + <span + class="font-weight-bold" + >Numéro ACC (2)</span><br /> + <span t-field="o.acc_operation_id.name" /><br /> + <span + class="font-weight-bold" + >Références Points d'Injection (PRM-I)</span><br /> + <t t-foreach="o.acc_operation_id.acc_injection_ids" t-as="inj"> + <span t-field="inj.name" /><br /> + </t> + <t t-if="o.producer_id.origine"> <span class="font-weight-bold" - t-field="o.contact_invoice.name" - /><br /> - <span t-field="o.contact_invoice.street" /><br /> - <t t-if="o.contact_invoice.street2"><span - t-field="o.contact_invoice.street2" - /><br /></t> - <t t-if="o.contact_invoice.zip"> - <span t-field="o.contact_invoice.zip" /> - <span - t-field="o.contact_invoice.city" - /><br /></t> - <t t-if="o.contact_invoice.phone"> - <span t-field="o.contact_invoice.phone" /><br /> - </t> - <t t-if="o.contact_invoice.email"> - <span t-field="o.contact_invoice.email" /> - </t> - </p> - <p class="text-center font-italic mt-4"> - (2) ACC : Auto-Consommation Collective - </p> - </div> + >Origine</span><br /> + <span t-field="o.producer_id.origine"/><br/> + </t> + </p> + <h5 class="font-weight-bold mb-3 mt-4 text-center">Une question ?</h5> + <p class="mb-4"> + <span + class="font-weight-bold" + t-field="o.contact_invoice.name" + /><br /> + <span t-field="o.contact_invoice.street" /><br /> + <t t-if="o.contact_invoice.street2"><span + t-field="o.contact_invoice.street2" + /><br /></t> + <t t-if="o.contact_invoice.zip"> + <span t-field="o.contact_invoice.zip" /> - <span + t-field="o.contact_invoice.city" + /><br /></t> + <t t-if="o.contact_invoice.phone"> + <span t-field="o.contact_invoice.phone" /><br /> + </t> + <t t-if="o.contact_invoice.email"> + <span t-field="o.contact_invoice.email" /> + </t> + </p> </div> <div class="col-8"> <div class="text-right"> + <h5 + class="font-weight-bold" + >Coordonnées de facturation</h5> <p> - <span - class="text-center font-weight-bold" - >Coordonnées de facturation</span><br /> <span class="font-weight-bold" t-field="o.consumer_id.name" @@ -345,7 +335,7 @@ </p> </div> <div class="o_recap_table mt-4"> - <div class="text-center mb-4"> + <div class="text-center mb-3"> <h3 class="text-uppercase">Synthèse de votre facture</h3> <p class="font-italic">Détails en pages suivantes</p> <h4>Période de livraison concernée : <br/> @@ -360,11 +350,12 @@ </div> <table - class="table table-sm table-none o_main_table" + class="table table-sm table-none o_main_table mb-4" name="account_line_table" > <tr> - <td>Electricité autoconsommée</td> + <td><strong><h5 + >Electricité autoconsommée</h5></strong></td> <td class="text-right"> <span class="text-nowrap" @@ -410,6 +401,7 @@ <h4 t-field="o.amount_untaxed" /> </td> </tr> + <tr style=""> <t> <td><span @@ -427,8 +419,8 @@ </tr> </t> <tr> - <td><strong><h4 - >Total TTC (1)</h4></strong></td> + <td><strong><h5 + >Total TTC (1)</h5></strong></td> <td class="text-right"> <strong><h3 class="text-nowrap" @@ -439,16 +431,15 @@ </table> <t t-if="o.producer_id.acc_account_payment_ids"> - <div class="row mt-4"> + <div class="row mt-5"> <div class="col-12"> - <span + <h5 class="font-weight-bold" - >Modalités de paiement : </span><br - /> + >Modalités de paiement : </h5> + <h6>Référence facture : <t t-esc="o.name" /></h6> <ul t-foreach="o.producer_id.acc_account_payment_ids" t-as="acc_account_payment_id"> <li><span t-field="acc_account_payment_id.description"/></li> </ul> - <h6>Référence facture : <t t-esc="o.name" /></h6> </div> </div> <div class="row mt-5"> @@ -458,9 +449,6 @@ t-field="o.date_limit" t-options="{'format': 'dd/MM/yyyy'}" /></h5> - <p class="text-center font-italic mt-5" - >(1) Le total à payer correspond à l’électricité autoconsommée et à l'ACCISE. La contribution d’acheminement ("TURPE") est collectée par le fournisseur du complément d’électricité - </p> </div> </div> </t> @@ -470,7 +458,10 @@ </div> </div> <div class="row mt-3"> - <div class="col-12 font-italic"> + <div class="col-12 font-italic font-mini"> + <p class="mt-5"> + (1) Le total à payer correspond à l’électricité autoconsommée et à l'ACCISE - (2) ACC : Auto-Consommation Collective + </p> <span t-field="o.invoice_terms"/> </div> </div> @@ -485,29 +476,27 @@ alt="Logo" /> </t> - <t t-else=""><h4 t-field="o.producer_id.name" /></t> + <t t-else=""><h4 class="text-center" t-field="o.producer_id.name" /></t> </div> <div class="col-8"></div> </div> - <div class="row mt-4 "> - <div class="col-12"> - <div class="text-center text-uppercase mb-4"> - <h4>Votre facture en détail</h4> - <span - class="text-uppercase mb-4 " - >Autoconsommation Collective <t - t-esc="o.acc_operation_id.name" - /></span><br /> - </div> - + <div class="row mt-4 mb-5"> + <div class="col-12 text-center text-uppercase"> + <h4>Votre facture en détail</h4> + <span + class="text-uppercase " + >Autoconsommation Collective <t + t-esc="o.acc_operation_id.name" + /></span><br /> + <h5 class="font-weight-bold " t-field="injection.name"/> + </div> + </div> + <div class="row mt-5 "> + <div class="col-12 "> <!-- Table pour l'électricité locale--> - <h6 class="mt-4"> - <span - class="text-uppercase mt0 " - >Electricité locale - PRM-I : </span><span class="font-weight-bold"><t - t-esc="injection.name" - /></span></h6> + <h6 class="text-uppercase "> + Electricité locale</h6> <table class="table table-sm o_main_table" name="account_line_table" @@ -570,23 +559,26 @@ </td> </tr> </t> + <tr class="border-black o_total"> + <t t-if="o.is_tva"> + <td colspan="5">MONTANT TOTAL</td> + </t> + <t t-else=""> + <td colspan="3">MONTANT TOTAL</td> + </t> + <td class="text-center"> + <span + t-esc="current_subtotal" + t-options='{"widget": "monetary", "display_currency": o.currency_id}' + /> + </td> + </tr> </tbody> </table> - <h6 class="is-subtotal text-right"> - <strong class="mr-4">MONTANT TOTAL : </strong> - <span class="ml-4" - t-esc="current_subtotal" - t-options='{"widget": "monetary", "display_currency": o.currency_id}' - /> - </h6> <!-- Table pour les taxes TCFE--> - <h6 class="mt-4"> - <span - class="text-uppercase mt0 " - >ACCISE* - PRM-I : </span><span class="font-weight-bold"><t - t-esc="injection.name" - /></span><br /></h6> + <h6 class="mt-4 text-uppercase"> + ACCISE*</h6> <table class="table table-sm o_main_table" name="account_line_table" @@ -653,15 +645,22 @@ </t> <t t-else="" /> </t> + <tr class="border-black o_total"> + <t t-if="o.is_tva"> + <td colspan="5">MONTANT TOTAL</td> + </t> + <t t-else=""> + <td colspan="3">MONTANT TOTAL</td> + </t> + <td class="text-center"> + <span + t-esc="current_subtotal" + t-options='{"widget": "monetary", "display_currency": o.currency_id}' + /> + </td> + </tr> </tbody> </table> - <h6 class="is-subtotal text-right mb-5"> - <strong class="mr-4">MONTANT TOTAL : </strong> - <span class="ml-4" - t-esc="current_subtotal" - t-options='{"widget": "monetary", "display_currency": o.currency_id}' - /> - </h6> <p class="mt-5 font-italic"> <span t-field="o.invoice_terms_tax"/> </p> @@ -669,109 +668,116 @@ </div> </t> <!-- Partie pour les lignes de facture supplémentaires --> - <div class="row" style="page-break-before:always;"> - <div class="col-4"> - <t t-if="o.producer_id.image_1920"> - <img - t-att-src="image_data_uri(o.producer_id.image_1920)" - style="max-height: 80px;" - alt="Logo" - /> - </t> - <t t-else=""><h4 t-field="o.producer_id.name" /></t> + <t t-set="lines_sale" t-value="o.line_ids.filtered(lambda line: not line.acc_injection_id)" /> + <t t-if="lines_sale"> + <div class="row" style="page-break-before:always;"> + <div class="col-4"> + <t t-if="o.producer_id.image_1920"> + <img + t-att-src="image_data_uri(o.producer_id.image_1920)" + style="max-height: 80px;" + alt="Logo" + /> + </t> + <t t-else=""><h4 class="text-center" t-field="o.producer_id.name" /></t> + </div> + <div class="col-8"></div> </div> - <div class="col-8"></div> - </div> - - <div class="row mt-4 "> - <div class="col-12"> - <div class="text-center text-uppercase mb-4"> + <div class="row mt-4 mb-5"> + <div class="col-12 text-center text-uppercase"> <h4>Votre facture en détail</h4> <span - class="text-uppercase mb-4 " + class="text-uppercase " >Autoconsommation Collective <t t-esc="o.acc_operation_id.name" - /></span><br /> + /></span> </div> + </div> - <!-- Table les lignes spécifiques --> - <h6 class="mt-4"> - <span - class="text-uppercase mt0 " - >Frais divers / Régularisation</span></h6> - <table - class="table table-sm o_main_table" - name="account_line_table" - > - <thead> - <tr> - <th>Description</th> - <th class="text-center">Quantité</th> - <th class="text-center">Prix unitaire</th> - <t t-if="o.is_tva"> - <th class="text-center">Total HT</th> - <th class="text-center">TVA</th> - </t> - <th class="text-center">Total TTC</th> - </tr> - </thead> - <tbody> - <t t-set="current_subtotal" t-value="0"/> - <t t-set="lines_sale" t-value="o.line_ids.filtered(lambda line: not line.acc_injection_id)" /> - <t t-foreach="lines_sale" t-as="line"> - <t t-set="current_subtotal" t-value="current_subtotal + line.price_total_ttc"/> - <tr class=""> - <td> - <span - t-field="line.description" - t-options="{'widget': 'text'}" - /> - </td> - <td class="text-center"> - <span - class="text-nowrap" - t-field="line.quantity" - /><span> kWh</span> - </td> - <td class="text-center"> - <span - class="text-nowrap" - t-field="line.price_unit" - /><span> €/kWh</span> - </td> + <div class="row mt-5 "> + <div class="col-12"> + <!-- Table les lignes spécifiques --> + <h6>Frais divers / Régularisation</h6> + <table + class="table table-sm o_main_table" + name="account_line_table" + > + <thead> + <tr> + <th>Description</th> + <th class="text-center">Quantité</th> + <th class="text-center">Prix unitaire</th> <t t-if="o.is_tva"> + <th class="text-center">Total HT</th> + <th class="text-center">TVA</th> + </t> + <th class="text-center">Total TTC</th> + </tr> + </thead> + <tbody> + <t t-set="current_subtotal" t-value="0"/> + <t t-foreach="lines_sale" t-as="line"> + <t t-set="current_subtotal" t-value="current_subtotal + line.price_total_ttc"/> + <tr class=""> + <td> + <span + t-field="line.description" + t-options="{'widget': 'text'}" + /> + </td> <td class="text-center"> <span class="text-nowrap" - t-field="line.price_total" + t-field="line.quantity" /> </td> <td class="text-center"> <span class="text-nowrap" - t-field="line.tax_id.name" + t-field="line.price_unit" + /><span> €</span> + </td> + <t t-if="o.is_tva"> + <td class="text-center"> + <span + class="text-nowrap" + t-field="line.price_total" + /> + </td> + <td class="text-center"> + <span + class="text-nowrap" + t-field="line.tax_id.name" + /> + </td> + </t> + <td class="text-center"> + <span + class="text-nowrap" + t-field="line.price_total_ttc" /> </td> + </tr> + </t> + <tr class="border-black o_total"> + <t t-if="o.is_tva"> + <td colspan="5">MONTANT TOTAL</td> + </t> + <t t-else=""> + <td colspan="3">MONTANT TOTAL</td> </t> <td class="text-center"> <span - class="text-nowrap" - t-field="line.price_total_ttc" + t-esc="current_subtotal" + t-options='{"widget": "monetary", "display_currency": o.currency_id}' /> </td> </tr> - </t> - </tbody> - </table> - <h6 class="is-subtotal text-right"> - <strong class="mr-4">MONTANT TOTAL : </strong> - <span class="ml-4" - t-esc="current_subtotal" - t-options='{"widget": "monetary", "display_currency": o.currency_id}' - /> - </h6> + </tbody> + </table> + </div> </div> - </div> + </t> </div> </t> diff --git a/static/src/scss/style.scss b/static/src/scss/style.scss index 0f448ee99a3a2d165fae518681055fb26bf69a98..e6e9b36edeede4e98f286b2b49e5682ac52e9f22 100644 --- a/static/src/scss/style.scss +++ b/static/src/scss/style.scss @@ -21,14 +21,22 @@ } .table th, -.table td { + td { border-top: none !important; } +.table .border-black td, .border-black th { + border-top: 1px solid black !important; +} + .o_report_layout_boxed .font-italic{ font-style: italic !important; } +.o_report_layout_boxed .font-mini{ + font-size: 13px !important; +} + .page .bloc-header .col-4.grey-div , .o_report_layout_boxed .col-4.grey-div { background-color: #EFF0F1 !important;