[FIX] res_user: de-duplicate usernames for warning msg about group deletion
bzr revid: odo@openerp.com-20110619130939-nnwi3u2ohl150mr6
This commit is contained in:
parent
dd1cefe446
commit
c46fa82418
|
@ -581,6 +581,7 @@ class groups2(osv.osv): ##FIXME: Is there a reason to inherit this object ?
|
|||
|
||||
if group_users:
|
||||
user_names = [user.name for user in self.pool.get('res.users').browse(cr, uid, group_users, context=context)]
|
||||
user_names = list(set(user_names))
|
||||
if len(user_names) >= 5:
|
||||
user_names = user_names[:5] + ['...']
|
||||
raise osv.except_osv(_('Warning !'),
|
||||
|
|
Loading…
Reference in New Issue