From f2df3a529fa995adaf9f7eea1a0244202e8f823f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Laporte?= <stephane.laporte@enercoop.org> Date: Wed, 30 Apr 2025 12:17:52 +0200 Subject: [PATCH] [CSS] sticky nav and filters --- templates/operation_templates_page.xml | 52 +++++++++++++++++++------- 1 file changed, 39 insertions(+), 13 deletions(-) diff --git a/templates/operation_templates_page.xml b/templates/operation_templates_page.xml index d56553b..99fe47c 100644 --- a/templates/operation_templates_page.xml +++ b/templates/operation_templates_page.xml @@ -2,7 +2,7 @@ <!-- Copyright 2021- Le Filament (https://le-filament.com) License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> <odoo> - <template id="layout_op" inherit_id="oacc_portal.layout_op"> + <template id="nav_menu_content" inherit_id="oacc_portal.nav_menu_content"> <xpath expr="//li[@id='menu-contact']" position="before"> <li class="nav-item" @@ -18,21 +18,47 @@ </xpath> </template> + <template id='sticky_nav_filters'> + <div + class="sticky-top pb-2 bg-white" + style="border-bottom: 1px solid rgb(244, 230, 236);" + > + <div class="d-block d-md-none"> + <t t-call="oacc_portal.nav_menu_sm" /> + </div> + <div class="container-fluid"> + <div class="row"> + <div class="col-12 text-center"> + <h3 class="mt-2 text-uppercase">Mes Factures Surplus</h3> + </div> + </div> + <div class="row"> + <div class="col-12"> + <div class="justify-content-between d-flex"> + </div> + </div> + </div> + </div> + </div> + </template> + <!-- Operation Document template --> <template id='operation_invoice_surplus' name="Operation Factures Surplus"> <t t-call="oacc_portal.layout_op"> - <div class="col-12 bg-white"> - <h3 class="text-center mt-2 text-uppercase">Mes Factures Surplus</h3> - <t t-if="invoices_surplus"> - <t t-set="invoices" t-value="invoices_surplus" /> - <t t-set="partner_label" t-value="'Acheteur de surplus'" /> - <t t-call="oacc_portal_account.operation_invoice_table" /> - </t> - <t t-else=""> - <p - class="pt-5" - >Il n'y a actuellement aucune facture de surplus sur cette opération.</p> - </t> + <div class="row"> + <t t-call="oacc_portal_account_surplus.sticky_nav_filters" /> + <div class="col-12"> + <t t-if="invoices_surplus"> + <t t-set="invoices" t-value="invoices_surplus" /> + <t t-set="partner_label" t-value="'Acheteur de surplus'" /> + <t t-call="oacc_portal_account.operation_invoice_table" /> + </t> + <t t-else=""> + <p + class="pt-5" + >Il n'y a actuellement aucune facture de surplus sur cette opération.</p> + </t> + </div> </div> </t> </template> -- GitLab