[IMP] res.users: added default photo (base/images/photo.png)

bzr revid: tde@openerp.com-20120221085606-h5wufginyq4su9sw
This commit is contained in:
Thibault Delavallée 2012-02-21 09:56:06 +01:00
parent ecdd172763
commit 2388c019f1
1 changed files with 5 additions and 0 deletions

View File

@ -353,9 +353,14 @@ class users(osv.osv):
pass
return result
def _get_photo(self, cr, uid, context=None):
photo_path = openerp.modules.get_module_resource('base','images','photo.png')
return open(photo_path, 'rb').read().encode('base64')
_defaults = {
'password' : '',
'context_lang': 'en_US',
'photo': _get_photo,
'active' : True,
'menu_id': _get_menu,
'company_id': _get_company,