Odoo Help


Xpath doesn't work anymore

Rémy Baron
on 6/7/16, 4:20 AM 550 views


I use <xpath> to edit my own invoice/saleorder look and it work correctly.

But when i try with the mrp_repair, nothing .. Any error, just the look of the order stay the same...

This is my view :

<template id="report_repair_document_ht" inherit_id="mrp_repair.report_mrprepairorder">

        <xpath expr="//div[@class='page']" position="replace">

                <div class="page">

                        My code                 




Thank you.

can you try going to the original view you want to edit on the front end user interface settings and add an extension view using the inherited views tab? This way you can avoid have to use the template tags and that reduces your space for error.

Alexander Soare
on 6/7/16, 6:24 AM
Rémy Baron
On 6/7/16, 5:45 AM

What is understood is, i have to tell the name of my view : "template id="..."

Then the view which i want edit : inherit_id="..."

Then where i want start to edit : xpath expr="..."

And how i want do it : position="..."

So I think my code is OK, and this form work correctly with another view so i don't understand why it doesn't work here ...

Alexander Soare
On 6/7/16, 5:26 AM

Why is the template tag outside of the xpath expression? I'm not sure if this is the problem here but I've found that the xpath should be the outermost tag. 

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 6/7/16, 4:20 AM
Seen: 550 times
Last updated: 6/7/16, 5:45 AM