BASE: use read instead of browse

bzr revid: ced-362a7ba78599f67a4595f1f25b1ff1b3ea9f05ae
This commit is contained in:
ced
2007-06-18 10:21:27 +00:00
parent e39807ae86
commit 6385382d4a
+1 -1
View File
@@ -41,7 +41,7 @@ class ir_default(osv.osv):
'company_id': fields.many2one('res.company','Company')
}
_defaults = {
'company_id': lambda self, cr, uid, context: self.pool.get('res.users').browse(cr, uid, uid, context=context).company_id.id,
'company_id': lambda self, cr, uid, context: self.pool.get('res.users').read(cr, uid, uid, ['company_id'], context=context)['company_id'],
}
ir_default()