You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
628 B

  1. Makes available in Odoo 8 the `shell` server command available for Odoo 9.
  2. To have this feature available this module just need to be in the
  3. addons path. To use it, in a terminal window run:
  4. $ ./odoo.py shell -d <dbname>
  5. This will initialize a server instance and then jump into a Pyhton
  6. interactive shell, with full access to the Odoo API.
  7. Example session:
  8. >>> self
  9. res.users(1,)
  10. >>> self.name
  11. u'Administrator'
  12. >>> self._name
  13. 'res.users'
  14. >>> self.env
  15. <openerp.api.Environment object at 0xb3f4f52c>
  16. >>> self.env['res.partner'].search([('name', 'like', 'Ag')])
  17. res.partner(7, 51)