Odoo Help


This community 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.


What is better way to add new functionality or change current ?

on 10/29/13, 12:07 PM 777 views

Is _inherit the best way to make changes in functionality ?

When using _inherit some time to change some small thing in view or logic i need to write a lot of code around... it's slowly

May be if i need to make big changes in system it's better to change sources directly and every time when sources updated merge with it?


Daniel Reis

--Daniel Reis--
| 6 7 9
Lisbon, Portugal
--Daniel Reis--

Author of the "Odoo Development Essentials" book.

Applications Manager at Securitas Portugal

Github: https://github.com/dreispt

Twitter; @reis_pt

Daniel Reis
On 10/29/13, 6:27 PM

In some cases, if your are so large, or your functionality so specific, that is "transfigures" the purpose and functionality of the standard module, it will be best to build it from scratch.

You will need to evaluate carefully, and it can be a hard decision. I suggest to ask yourself: if I make the changes on top on an existing module, and at some point the client wants to also use the original functionality it offered, will it be practical to still do so? If the answer is yes, extend the existing module, if it's no, build a new one.

In general, you should try your best to leverage and build on top of existing functionality. Never, I repeat, never, change sources directly. Always use inheritance. It might look slow at first, but you will get more robust and future proof modules.

Changes made directly to source code:

  • Don't automatically survive to product version upgrades
  • Are a lot harder to migrate to later product versions
  • In general are not considered good practices, and so will not be accepted for community contributions

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)


Asked: 10/29/13, 12:07 PM
Seen: 777 times
Last updated: 3/16/15, 8:10 AM