From 11e61f6ec941bacf795d5f3dbefa2a3f0ba15b93 Mon Sep 17 00:00:00 2001 From: Martin Trigaux Date: Mon, 18 Feb 2013 16:49:15 +0100 Subject: [PATCH] [IMP] gamification: better selection choice bzr revid: mat@openerp.com-20130218154915-r5hfx5dr5np5ivkq --- addons/gamification/goal.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/addons/gamification/goal.py b/addons/gamification/goal.py index c6f8f32799e..924fe2dcee5 100644 --- a/addons/gamification/goal.py +++ b/addons/gamification/goal.py @@ -36,7 +36,7 @@ GAMIFICATION_PLAN_STATE = [ ] GAMIFICATION_PERIOD_STATE = [ - ('once','No automatic assigment'), + ('once','Manual'), ('daily','Daily'), ('weekly','Weekly'), ('monthly','Monthly'), @@ -60,6 +60,7 @@ GAMIFICATION_REPORT_MODE = [ ] GAMIFICATION_REPORT_FREQ = [ + ('never','Never'), ('onchange','On change'), ('daily','Daily'), ('weekly','Weekly'), @@ -131,7 +132,7 @@ class gamification_goal(osv.Model): def _get_completeness(self, cr, uid, ids, field_name, arg, context=None): res = {} for goal in self.browse(cr, uid, ids, context): - # more 100% ? + # more than 100% case is handled by the widget if goal.target_goal > 0: res[goal.id] = 100.0 * goal.current / goal.target_goal else: @@ -201,7 +202,8 @@ class gamification_goal_plan(osv.Model): 'planline_ids' : fields.one2many('gamification.goal.planline', 'plan_id', string='Planline', - help="list of goals that will be set"), + help="list of goals that will be set", + required=True), 'autojoin_group_id' : fields.many2one('res.groups', string='Group', help='Group of users whose members will automatically be added to the users'),