Bugfix
bzr revid: pinky-23b8e1a1d8983446596a6a5bf01d48a95c395c11
This commit is contained in:
parent
7b5cc10937
commit
92001a3df8
|
@ -65,7 +65,7 @@ class account_invoice(osv.osv):
|
||||||
|
|
||||||
def _get_currency(self, cr, uid, context):
|
def _get_currency(self, cr, uid, context):
|
||||||
user = pooler.get_pool(cr.dbname).get('res.users').browse(cr, uid, [uid])[0]
|
user = pooler.get_pool(cr.dbname).get('res.users').browse(cr, uid, [uid])[0]
|
||||||
if user.company:
|
if user.company_id:
|
||||||
return user.company_id.currency_id.id
|
return user.company_id.currency_id.id
|
||||||
else:
|
else:
|
||||||
return pooler.get_pool(cr.dbname).get('res.currency').search(cr, uid, [('rate','=',1.0)])[0]
|
return pooler.get_pool(cr.dbname).get('res.currency').search(cr, uid, [('rate','=',1.0)])[0]
|
||||||
|
|
Loading…
Reference in New Issue