Search Here

How to Create New Custom Model in Odoo

In this article you will learn what is a model and how to create a brand new model in Odoo. Before creating our first model in odoo, we need to know about model. 


What is Model in Odoo

A model is a python class that represent business entity (fields) that are stored in PostgreSQL database. In odoo all business entities are implemented as model or class. 


Model fields (class property) are defined as attributes or  column or fields in a database.


In the above code we have created a class named "AModel" and the name of model (table) is your..model.name. In this table we have many fields or columns such as name, image, counter etc. In simple words when we create fields in models, actually we create table and its fields or columns.



Our created model looks like the below screen shot.

How to create models in odoo

Post a Comment

0 Comments