From: Thibault Delavallée Date: Wed, 20 Aug 2014 10:51:01 +0000 (+0200) Subject: [FIX] share: fixed crash when using the share wizard, linked to the new api. X-Git-Tag: 8.0.0~324 X-Git-Url: http://git.inspyration.org/?a=commitdiff_plain;h=9d50b4703358aa81abda46b2445da6ac44e6897c;p=odoo%2Fodoo.git [FIX] share: fixed crash when using the share wizard, linked to the new api. --- diff --git a/addons/share/wizard/share_wizard.py b/addons/share/wizard/share_wizard.py index 79511c8..4ce33e2 100644 --- a/addons/share/wizard/share_wizard.py +++ b/addons/share/wizard/share_wizard.py @@ -26,6 +26,7 @@ from openerp import SUPERUSER_ID import simplejson +from openerp import api from openerp import tools from openerp.osv import fields, osv from openerp.osv import expression @@ -82,6 +83,7 @@ class share_wizard(osv.TransientModel): values['name'] = action.name return super(share_wizard,self).create(cr, uid, values, context=context) + @api.cr_uid_ids_context def share_url_template(self, cr, uid, _ids, context=None): # NOTE: take _ids in parameter to allow usage through browse_record objects base_url = self.pool.get('ir.config_parameter').get_param(cr, uid, 'web.base.url', default='', context=context) @@ -103,7 +105,7 @@ class share_wizard(osv.TransientModel): return result def _generate_embedded_code(self, wizard, options=None): - cr, uid, context = self.env.args + cr, uid, context = wizard.env.args if options is None: options = {}