diff options
| author | Frédéric van der Essen <fva@openerp.com> | 2012-09-27 15:29:42 +0200 |
|---|---|---|
| committer | Frédéric van der Essen <fva@openerp.com> | 2012-09-27 15:29:42 +0200 |
| commit | 1322cd1a3deccba742e4ffa2397028cd4f84b26b (patch) | |
| tree | a5ed37d005f9b7152916f89c49ab31e0ea6791eb /addons/google_map/google_map_launch.py | |
| parent | cf5385a5a8f4f355d8455cbc3aa436d034cce0a5 (diff) | |
| parent | 994fe31313ce8d51c45cf7396e936dccccfc304a (diff) | |
[MERGE] from trunk
bzr revid: fva@openerp.com-20120927132942-853bb3uptrp1x55d
Diffstat (limited to 'addons/google_map/google_map_launch.py')
| -rw-r--r-- | addons/google_map/google_map_launch.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/addons/google_map/google_map_launch.py b/addons/google_map/google_map_launch.py index 8ee9a16fb0a..f3ac20ac734 100644 --- a/addons/google_map/google_map_launch.py +++ b/addons/google_map/google_map_launch.py @@ -25,8 +25,7 @@ class launch_map(osv.osv): _inherit = "res.partner" def open_map(self, cr, uid, ids, context=None): - address_obj= self.pool.get('res.partner') - partner = address_obj.browse(cr, uid, ids, context=context)[0] + partner = self.browse(cr, uid, ids, context=context)[0] url="http://maps.google.com/maps?oi=map&q=" if partner.street: url+=partner.street.replace(' ','+') @@ -39,9 +38,9 @@ class launch_map(osv.osv): if partner.zip: url+='+'+partner.zip.replace(' ','+') return { - 'type': 'ir.actions.act_url', - 'url':url, - 'target': 'new' + 'type': 'ir.actions.act_url', + 'url':url, + 'target': 'new' } launch_map() |
