Odoo 11 Module File Structure

/addon/[your module name]


[ __init__.py ]

The Python code is loaded by the __init__.py files, where the .py files and code
subdirectories are imported. Subdirectories containing code Python, in turn, need
their own __init__.py


[ __manifest__.py ] (before  ODOO 10  the file called __openerp__.py  in odoo)

An Odoo module is a directory containing code files and other assets. The directory name used is the module’s technical name. The name key in the module manifest is its title.

The __manifest__.py file is the module manifest. It contains a Python dictionary with information about the module, the modules it depends on, and the data files that it will load.


[ static/description/… ]

To add an icon for the module, choose a PNG image to use and copy it to static/description/icon.png.


[ Creating module ]

Odoo provides a mechanism to help set up a new module, odoo-bin has a subcommand scaffold to create an empty module:


odoo-bin scaffold <module name> <where to put it>


$ sudo /opt/odoo/odoo/odoo-bin scaffold mymodule /opt/odoo/odoo/addon/ 
(in my example odoo installation path is different)

local_offerevent_note March 27, 2018

account_box Anshuman Sharma


Leave a Reply

Your email address will not be published. Required fields are marked *