Community: CMS / eCommerce Experts mailing list archives
expert-website@mail.odoo.com
Browse archives
Is Odoo storing .pyc files somewhere unusual?
How does the website module apply themes to specific pages/sections?
How do I dump the data from a model?
by
Darrel
If I use self.pool.get('model').browse(ID) I get a model object which also seems to automatically load the relationships. How do I dump all of the key/value pairs of just the data from the database from that returned model object? If I use vars() on the object, it returns literally hundreds of things, because it dumps all of the models various helper functions. I also found get_fields(), which dumps a lot of schema information, but none of the data (and it's not very readable for something with a lot of relationships like product_product). What I want is to see the fields and data so I can better understand the actual data in the business objects. Is there a helper method somewhere in osv.Model which does this? Darrel