diff options
| author | Martin Trigaux <mat@openerp.com> | 2013-04-11 15:24:38 +0200 |
|---|---|---|
| committer | Martin Trigaux <mat@openerp.com> | 2013-04-11 15:24:38 +0200 |
| commit | d4ccdb46de1f9f5c3daf3a89b751a7dbf6a9ceed (patch) | |
| tree | 8f1bbe158e19c93851900391dd29df7a63c73198 /addons | |
| parent | 4bcea683e204ee627813d1826c12530de22b4e23 (diff) | |
[IMP] better views
bzr revid: mat@openerp.com-20130411132438-x38ngml9sdi0uwb2
Diffstat (limited to 'addons')
| -rw-r--r-- | addons/gamification/badge_view.xml | 4 | ||||
| -rw-r--r-- | addons/hr_gamification/badge.py | 6 | ||||
| -rw-r--r-- | addons/hr_gamification/badge_view.xml | 8 |
3 files changed, 9 insertions, 9 deletions
diff --git a/addons/gamification/badge_view.xml b/addons/gamification/badge_view.xml index 651905253d6..d3e206b795f 100644 --- a/addons/gamification/badge_view.xml +++ b/addons/gamification/badge_view.xml @@ -27,9 +27,9 @@ <form string="Grant Badge To" version="7.0"> Who would you like to reward? <group> - <field name="user_id" /> + <field name="user_id" nolabel="1" /> <field name="badge_id" invisible="1"/> - <field name="comment" placeholder="Describe what they did and why it matters" /> + <field name="comment" nolabel="1" placeholder="Describe what they did and why it matters" /> </group> <footer> <button string="Grant Badge" type="object" name="action_grant_badge" class="oe_highlight" /> or diff --git a/addons/hr_gamification/badge.py b/addons/hr_gamification/badge.py index 0c0ee260c47..7b85305289a 100644 --- a/addons/hr_gamification/badge.py +++ b/addons/hr_gamification/badge.py @@ -45,9 +45,9 @@ class hr_gamification_badge_user(osv.Model): ] -class hr_gamification_badge(osv.Model): +class gamification_badge(osv.Model): _name = 'gamification.badge' - _inherit = ['gamification.badge', 'mail.thread'] + _inherit = ['gamification.badge'] def message_post(self, cr, uid, thread_id, context=None, **kwargs): """Overwrite the message_post method to send the badge to the employee""" @@ -58,7 +58,7 @@ class hr_gamification_badge(osv.Model): if badge_user.employee_id: return self.pool.get('hr.employee').message_post(cr, uid, badge_user.employee_id.id, context=context, **kwargs) - return super(hr_gamification_badge, self).message_post(cr, uid, thread_id, context=context, **kwargs) + return super(gamification_badge, self).message_post(cr, uid, thread_id, context=context, **kwargs) class hr_grant_badge_wizard(osv.TransientModel): diff --git a/addons/hr_gamification/badge_view.xml b/addons/hr_gamification/badge_view.xml index 9035058402a..98be93e0279 100644 --- a/addons/hr_gamification/badge_view.xml +++ b/addons/hr_gamification/badge_view.xml @@ -11,9 +11,9 @@ <form string="Grant Badge To" version="7.0"> Who would you like to reward? <group> - <field name="employee_id" /> + <field name="employee_id" nolabel="1" domain="[('user_id', '!=', False)]" /> <field name="badge_id" invisible="1"/> - <field name="comment" placeholder="Describe what they did and why it matters" /> + <field name="comment" nolabel="1" placeholder="Describe what they did and why it matters" /> </group> <footer> <button string="Grant Badge" type="object" name="action_grant_badge" class="oe_highlight" /> or @@ -34,8 +34,8 @@ What are you thank for? <group> <field name="employee_id" invisible="1" /> - <field name="badge_id" /> - <field name="comment" placeholder="Describe what they did and why it matters" /> + <field name="badge_id" nolabel="1" /> + <field name="comment" nolabel="1" placeholder="Describe what they did and why it matters" /> </group> <footer> <button string="Reward Employee" type="object" name="action_grant_badge" class="oe_highlight" /> or |
