Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
Hi Odoo developers,
First of all, I'm a newbie in Odoo 8 development, but after I had read all tutorials and something in the Reference section from the Odoo developers webpage, I feel that the Odoo framework is not well documented and only a few simple examples are provided.
Secondly, If I study the source code of the core modules in Odoo (eg. Events) I can't understand a lot of things. Where should I look for to understand this?.
Also, in my opinion, the code in models (.py files) and xml files doesn't have many comments to understand it. How to know the execution flow whether there are a lot of files involved in the process?.
Also, many modules in Odoo 8 are implemented using the OpenERP v7 framework. Then, apart from studying the Odoo 8 framework, I have to study the OpenERP v7 framework too. It's annoying.
If a want to develop a new module in Odoo 8 extending the capabilities of a module incorporated in Odoo, I have to know how it works the OpenERP framework to understand the source code of the extended module.
Thirdly, where is it explained the arquitecture of the files from the Odoo core. A few hours ago, I guessed that a method to resize images exists in tools module, but I don't understand neither how it works nor the arguments to pass it.
Where is this kinds of things documented?.
It's only mi personal opinion as a newbie, but I think that, when a developer is a novice in something, having a good documentation and a well-documented source code is absolutely necessary to implement advanced functionalities.
And my question. How did you learn to do complicated things to develop modules in Odoo 8?.
About 7 months ago I was in the position where you are now and I would like to share my knowledge / opinion on this, since this costed me a lot of time.
As for the documentation, you're absolutely right. There is (very) little good documentation and the documentation that is available is about basic subjects that we could figure out anyway. More advanced documentation isn't really there, except for a very broad description. That being sad, you will absolutely miss good documentation for Odoo but you also learn to work with it and figure it out yourself while you advance.
The best way to understand the source code and learn how Odoo works is to dive in. Activate your technical features and tinker around with things. Look at on_change events, domains, button events,.. and try to find them. You will find that everything has a structure in Odoo and that a lot in Odoo works with inheritance. There are sadly very little comments on code so you really have to figure things out yourself..
As for a lot of the modules being coded in V7 API and not in V8, you're correct, this is true. Odoo is slowly migrating its modules from the V7 API to V8 but this takes time. Current developers in Odoo use a lot of the V7 API since there is little documentation and there are barely any samples. When you look a bit further you'll find out that most of the things in V7 and V8 API are pretty common though. Especially for creating fields/models. If you can learn the API for V8 directly but if you're new and still need to learn a lot you'll find a lot more samples in V7 API.
The Odoo arquitechture isn't really very well explained anywhere but the most important things are explained here. There is in fact a tool to resize images and I've written a guide about how to use it on this blog article.
While there isn't a lot of good documentation (atleast not from Odoo itself) Stephen wrote a thread which contains a lot of blogs and guides, which you can find here. I personally learned a lot by simply looking at existing modules and tracking where everything goes. When you have technical features activated you can see which field is in which module and which model it uses. There can be an on_change, which then shows the exact name of the function and from there on you can find the rest of the code. In my blog I try to create tutorials which explain more technical things in detail, to make it easier for new beginners so perhaps this can help you too. You can find my blog at http://www.odoo.yenthevg.com/.
I hope this answer helps you in a good way and that you've learned something from it. Best of luck!
Maybe you already found out where the official documentation is, but maybe other people reading this post didn't... As you say, the documentation is very poor, but in terms of making a new module it's not so bad if you search well. Here you have the official documentation I use for both API's. This is the Old Api Documentation I use. And this is the New Api Documentation, it is a general documentation for Odoo 8 I use.
Anyway, you're very right about that it is very hard to dive into the source code, because the OpenERP core documentation is just null... But diving this forum and trying things into a test enviroment will make you understand a little bit.
I don't know if you know this, but if you want to track the modules,actions, fields, methods... from OpenERP, you can click on top right corner of the screen (over your user's name) -> about Odoo -> Activate developer's mode. This will let you know the names of the fields in the database (and the modules code) as you get your pointers over them. Also, with technical features activated under the Permissions of the user you can access to Settings -> Technical -> Database Structure that is very useful to see the classes fields... And some other things that maybe will interest you at some point.
Hope it helped!
I am also very new to Odoo and through the video subscription http://www.odooclass.com/ (ERP7) and Odoo development Essentials book by Daniel Reis I got a good feel for creating modules. This is also a fantastic place to get help and support. Another useful site is https://www.odoo.com/documentation/8.0/tutorials.html. It give a good understanding of Odoo 8.
None of these will get you up to expert level quickly but there are a very good start.
Hope it helps
Core modules are poorly documented. When your goal is to add some functionalities to an existing module, it can be very hard to follow the data processing. My advice : use an IDE with all the odoo code loaded, because you'll have to do a search on each function, button, view,... name you'll find. I learned almost everything I know that way.
About This Community
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 5/12/15, 10:22 PM|
|Seen: 4917 times|
|Last updated: 12/27/15, 5:39 PM|