About the Odoo base Models
In the previous chapters, we had the chance to create new Models, such as the Book model, but we also made use of the already existing Models, such as the Partner Model, provided by Odoo out of the box. We will have here a basic introduction to these built-in models.
At the core of Odoo, we have the
base add-on module. It provides the essential features needed for Odoo apps. Then, we have a set of built-in add-on modules, providing the official apps and features made available with the standard product.
The base module provides two kinds of Models:
- Information Repository,
ir.*models - Resources,
res.*models
The Information Repository is used to store data needed by Odoo to know how to work as an application, such as Menus, Views, Models, Actions, and so on. The data we find in the
Technical menu is usually stored in information repository models. Some relevant examples are these:ir.actions.act_windowfor Windows Actionsir.ui.menufor Menu Itemsir.ui.viewfor Viewsir.modelfor Modelsir.model.fieldsfor Model Fieldsir.model.datafor XML IDs
The resources contain basic data about the world, which can be useful for applications in general. These are the more important resource models:
res.partnerfor business partners, such as customers, suppliers, and so on, and addressesres.companyfor company datares.currencyfor currenciesres.countryfor countriesres.usersfor application usersres.groupsfor application security groups
This should provide you with useful context to better understand where the models come from whenever you come across them in the future.
Comments
Post a Comment