I just discovered the osv.Model init() and view_init() functions, which are really useful for some of the things I want to do. However, I'd like to be able to have my custom module come pre-loaded with some data when it's installed (or upgraded/reloaded). Is there a function that would allow this, similar to how init() lets me do things on module initialization?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Contabilidad
- Inventario
- PoS
- Project
- MRP
Se marcó esta pregunta
1
Responder
3817
Vistas
You can load data when the module is installed/upgraded/reloaded with xml files in the module itself. These files need to be declared in the __openerp__.py file, in the data section
Hope this helps,
¿Le interesa esta conversación? ¡Participe en ella!
Cree una cuenta para poder utilizar funciones exclusivas e interactuar con la comunidad.
Inscribirse