[IMP] small twaeks in doc
bzr revid: mat@openerp.com-20130625145100-7ko58fj4z0p3ouqc
This commit is contained in:
@@ -35,3 +35,8 @@ Fields
|
||||
- ``sequence`` : to order list of goals in a challenger
|
||||
- ``action_id`` : the XML id to of an ir.actions.act_window to execute when the user clicks on a goal on the home page
|
||||
- ``res_id_field`` : the res_id used by the action, using user as for the domain (eg: user.company_id.id)
|
||||
|
||||
Methods
|
||||
+++++++
|
||||
|
||||
Add new methods inheriting from this class to add goal type with python computation mode. Look at the example in ``gamification/goal_type_data.py``
|
||||
@@ -18,5 +18,7 @@ A **Badge** is a symbolic token granted to a user as a sign of reward. It can be
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
|
||||
goal_type
|
||||
goal
|
||||
gamification_plan_howto
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
|
||||
from openerp.osv import osv
|
||||
|
||||
|
||||
class gamification_goal_type_data(osv.Model):
|
||||
"""Goal type data
|
||||
|
||||
@@ -30,7 +31,6 @@ class gamification_goal_type_data(osv.Model):
|
||||
"""
|
||||
_inherit = 'gamification.goal.type'
|
||||
|
||||
#TODO: is it usefull to have this method in a standalone file? why not directly in the computation field of the related goal type?
|
||||
def number_following(self, cr, uid, xml_id="mail.thread", context=None):
|
||||
"""Return the number of 'xml_id' objects the user is following
|
||||
|
||||
|
||||
Reference in New Issue
Block a user