Upgrades in OpenERP 6.1 as compared to 6.0.x

Here are some of the changes to be kept in mind while switching to this improved and smarter version. This is for developers switching to 6.1 version from 6.0.x-

View:

  • The web is integrated in server, so we just have to start the server and web automatically starts at http://localhost:8069 by default.
  • By defaut the session of web does not time out just like in GTK client
  • Unlike in 6.0.x, one2many field does not save in database even if Save & New or Save & Close button is clicked. To actually Save it in database, one have to click on main Save button of parent object.
  • If a menu is right clicked to open in new tab or window it does not open that menu. Rather it takes you to the home screen.
  • Remembers the last database accessed. This removes the pain of selecting the right database each time you log in, specially when you have multiple test databases.

Coding:

  • Now, one menu cannot be clicked to open an action and also to open its child menus. If a menu has child menus, then it cannot have action assigned to it.
  • many2many declaration is simplified. The relation name and relation columns need not be specified explicitly. Only this is enough- ‘invoice_ids’: fields.many2many(‘account.invoice’,string=’Invoices’)
  • For circular reference, there is no need to split classes in two. Example taken from OpenERP 6.1 Release Notes- In v6.0, we used to write the following code:

    class res_groups(osv.osv):

    _name = ‘res.groups’

    _columns = {

    ‘name’: fields.char(‘Name’),

    }

    res_groups()


    class res_users(osv.osv):

    _name = ‘res.users’

    _columns = {

    ‘name’: fields.char(‘Name’),

    ‘group_ids’: fields.many2many(‘Groups’, ‘res.groups’),

    }

    res_users()


    class res_groups2(osv.osv):

    _inherit= ‘res.groups’

    _columns = {

    ‘user_ids’: fields.many2many(‘Users’, ‘res.users’),

    }

    res_groups2()


    As of 6.1, this code can be reduced to:

    class res_groups(osv.osv):

    _name = ‘res.groups’

    _columns = {

    ‘name’: fields.char(‘Name’),

    ‘user_ids’: fields.many2many(‘Users’, ‘res.users’),

    }

    class res_users(osv.osv):

    _name = ‘res.users’

    _columns = {

    ‘name’: fields.char(‘Name’),

    ‘group_ids’: fields.many2many(‘Groups’, ‘res.groups’),

    }

  • The debug mode can be turned on by simply appending ?debug to the OpenERP URL.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s