[FIX] website: helper google_map for res.company

bzr revid: chm@openerp.com-20131114090223-2gl6y7shh6f7fplm
This commit is contained in:
Christophe Matthieu 2013-11-14 10:02:23 +01:00
parent 471d9671e7
commit 8ae07d4cba
1 changed files with 2 additions and 2 deletions

View File

@ -548,10 +548,10 @@ class res_partner(osv.osv):
class res_company(osv.osv):
_inherit = "res.company"
def google_map_img(self, cr, uid, ids, zoom=8, width=298, height=298, context=None):
partner = self.browse(cr, openerp.SUPERUSER_ID, ids[0], context=context).parent_id
partner = self.browse(cr, openerp.SUPERUSER_ID, ids[0], context=context).partner_id
return partner and partner.google_map_img(zoom, width, height, context=context) or None
def google_map_link(self, cr, uid, ids, zoom=8, context=None):
partner = self.browse(cr, openerp.SUPERUSER_ID, ids[0], context=context).parent_id
partner = self.browse(cr, openerp.SUPERUSER_ID, ids[0], context=context).partner_id
return partner and partner.google_map_link(zoom, context=context) or None
class base_language_install(osv.osv):