mirror of
https://github.com/NaN-tic/trytond-patches.git
synced 2023-12-14 06:03:03 +01:00
24 lines
905 B
Diff
24 lines
905 B
Diff
diff -r 463332839c4e trytond/trytond/modules/stock_lot/stock.py
|
|
--- a/trytond/trytond/modules/stock_lot/lstock.py Wed May 11 11:26:49 2016 +0200
|
|
+++ b/trytond/trytond/modules/stock_lot/stock.py Mon May 30 14:23:41 2016 +0200
|
|
@@ -78,6 +78,20 @@
|
|
for move in moves:
|
|
move.check_lot()
|
|
|
|
+ @classmethod
|
|
+ def assign_try(cls, moves, with_childs=True, grouping=('product',)):
|
|
+ lot_moves = []
|
|
+ product_moves = []
|
|
+ for move in moves:
|
|
+ if move.lot:
|
|
+ lot_moves.append(move)
|
|
+ else:
|
|
+ product_moves.append(move)
|
|
+ return (super(Move, cls).assign_try(lot_moves,
|
|
+ with_childs=with_childs, grouping=('product', 'lot'))
|
|
+ & super(Move, cls).assign_try(product_moves,
|
|
+ with_childs=with_childs, grouping=grouping))
|
|
+
|
|
|
|
class ShipmentIn:
|
|
__metaclass__ = PoolMeta
|