From 79e01f0f4d92b301ad5cb608119db0e386727293 Mon Sep 17 00:00:00 2001 From: Martin Trigaux Date: Tue, 20 Jan 2015 16:15:10 +0100 Subject: [PATCH] [FIX] gamification: fetch results is a tuple --- addons/gamification/models/challenge.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/gamification/models/challenge.py b/addons/gamification/models/challenge.py index 50f7059dc31..ce0c86c5cf1 100644 --- a/addons/gamification/models/challenge.py +++ b/addons/gamification/models/challenge.py @@ -316,7 +316,7 @@ class gamification_challenge(osv.Model): OR (gg.state = 'reached' AND (gg.end_date >= %s OR gg.end_date IS NULL))) """, (tuple(ids), yesterday.strftime(DF))) - goal_ids = cr.fetchall() + goal_ids = [res[0] for res in cr.fetchall()] # update every running goal already generated linked to selected challenges goal_obj.update(cr, uid, goal_ids, context=context)