[IMP] Use database uuid as client_id for OpenERP oauth provider

bzr revid: fme@openerp.com-20121002141302-dblh6j4eiwikmdoz
This commit is contained in:
Fabien Meghazi 2012-10-02 16:13:02 +02:00
parent 01611481a5
commit bb8a62a3b4
2 changed files with 7 additions and 0 deletions

View File

@ -34,6 +34,7 @@ Allow users to login through Google OAuth2.
'depends': ['base', 'web', 'base_setup'],
'data': [
'auth_oauth_data.xml',
'auth_oauth_data.yml',
'auth_oauth_view.xml',
'security/ir.model.access.csv'
],

View File

@ -0,0 +1,6 @@
-
Use database uuid as client_id for OpenERP oauth provider
-
!python {model: ir.config_parameter}: |
oauth = self.pool.get('auth.oauth.provider')
oauth.write(cr, uid, [ref('provider_openerp')], {'client_id': self.get_param(cr, uid, 'database.uuid')})