Ir al contenido
Menú
Se marcó esta pregunta

Hi everyone,

I'm working on a custom module in Odoo 17 where I need to override the "Contact Us" page template (website.contactus). 

My goal is to add a custom block to the existing structure without disrupting the web editor's functionality. 

So far, my attempts have resulted in the page being edited, but most blocks from the web editor are locked ("No location to drop in"). 

Just replacing the existing title (h1) with the exact same code is enough to lock the blocks.


Here's an example of what I tried:

template id="contactus_override" inherit_id="website.contactus"
    xpath expr="//div[@id='wrap']/section//h1" position="replace"
        h1 Hello World! /h1
    /xpath
/template
The code is weird because I couldn't write it without it being processed

Has anyone faced a similar issue or can suggest a solution to keep the section editable while adding custom content?

Thanks in advance for your help!

*Edit*
It seems to be due to the class "oe_structure", when overriding a template, the original oe_structure does not seem to work anymore. I would still appreciate the help if someone has a solution. 

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
3
jun 24
3657
0
oct 24
620
0
ago 24
474
4
may 24
2526
1
may 24
1334