[FIX] gamification: call _send_badge on right object
This commit is contained in:
parent
576218b003
commit
950cf14b9e
|
@ -36,7 +36,6 @@ class grant_badge_wizard(osv.TransientModel):
|
|||
def action_grant_badge(self, cr, uid, ids, context=None):
|
||||
"""Wizard action for sending a badge to a chosen user"""
|
||||
|
||||
badge_obj = self.pool.get('gamification.badge')
|
||||
badge_user_obj = self.pool.get('gamification.badge.user')
|
||||
|
||||
for wiz in self.browse(cr, uid, ids, context=context):
|
||||
|
@ -51,6 +50,6 @@ class grant_badge_wizard(osv.TransientModel):
|
|||
'comment': wiz.comment,
|
||||
}
|
||||
badge_user = badge_user_obj.create(cr, uid, values, context=context)
|
||||
result = badge_obj._send_badge(cr, uid, badge_user, context=context)
|
||||
result = badge_user_obj._send_badge(cr, uid, badge_user, context=context)
|
||||
|
||||
return result
|
||||
|
|
Loading…
Reference in New Issue