Merge lp:~numerigraphe/openobject-addons/trunk-stock-docstrings into lp:openobject-addons

Proposed by Numérigraphe
Status: Merged
Merged at revision: 7622
Proposed branch: lp:~numerigraphe/openobject-addons/trunk-stock-docstrings
Merge into: lp:openobject-addons
Diff against target: 50 lines (+11/-2)
1 file modified
stock/stock.py (+11/-2)
To merge this branch: bzr merge lp:~numerigraphe/openobject-addons/trunk-stock-docstrings
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+94740@code.launchpad.net

Description of the change

More informative docstrings and comments in stock/stock.py

To post a comment you must log in.
Revision history for this message
Fabien (Open ERP) (fp-tinyerp) wrote :

merged in trunk , thanks for the contribution.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'stock/stock.py'
2--- stock/stock.py 2012-02-15 18:00:28 +0000
3+++ stock/stock.py 2012-02-28 16:09:49 +0000
4@@ -669,6 +669,7 @@
5 ]
6
7 def action_process(self, cr, uid, ids, context=None):
8+ """Open the partial picking wizard"""
9 if context is None: context = {}
10 context = dict(context, active_ids=ids, active_model=self._name)
11 partial_id = self.pool.get("stock.partial.picking").create(cr, uid, {}, context=context)
12@@ -710,6 +711,7 @@
13 return {}
14
15 def action_explode(self, cr, uid, moves, context=None):
16+ """Hook to allow other modules to split the moves of a picking."""
17 return moves
18
19 def action_confirm(self, cr, uid, ids, context=None):
20@@ -844,14 +846,20 @@
21 # TODO: change and create a move if not parents
22 #
23 def action_done(self, cr, uid, ids, context=None):
24- """ Changes picking state to done.
25+ """Changes picking state to done.
26+
27+ This method is called at the end of the workflow by the activity "done".
28 @return: True
29 """
30 self.write(cr, uid, ids, {'state': 'done', 'date_done': time.strftime('%Y-%m-%d %H:%M:%S')})
31 return True
32
33 def action_move(self, cr, uid, ids, context=None):
34- """ Changes move state to assigned.
35+ """Process the Stock Moves of the Picking
36+
37+ This method is called by the workflow by the activity "move".
38+ Normally that happens when the signal button_done is received (button
39+ "Done" pressed on a Picking view).
40 @return: True
41 """
42 for pick in self.browse(cr, uid, ids, context=context):
43@@ -2367,6 +2375,7 @@
44 return res
45
46 # action_split function is not used anywhere
47+ # FIXME: deprecate this method
48 def action_split(self, cr, uid, ids, quantity, split_by_qty=1, prefix=False, with_lot=True, context=None):
49 """ Split Stock Move lines into production lot which specified split by quantity.
50 @param cr: the database cursor

Subscribers

People subscribed via source and target branches

to all changes: