diff --git a/stock_lot_sled.diff b/stock_lot_sled.diff index 8f82bc8..cc9ff0e 100644 --- a/stock_lot_sled.diff +++ b/stock_lot_sled.diff @@ -1,6 +1,6 @@ diff -r fb7f3b05e343 stock.py --- a/trytond/trytond/modules/stock_lot_sled/stock.py Mon Apr 23 17:44:40 2018 +0200 -+++ b/trytond/trytond/modules/stock_lot_sled/stock.py Wed Nov 14 11:12:49 2018 +0100 ++++ b/trytond/trytond/modules/stock_lot_sled/stock.py Tue Nov 27 11:21:59 2018 +0100 @@ -229,7 +229,8 @@ @classmethod @@ -11,12 +11,29 @@ diff -r fb7f3b05e343 stock.py pool = Pool() Date = pool.get('ir.date') Lot = pool.get('stock.lot') -@@ -237,7 +238,7 @@ +@@ -237,7 +238,24 @@ query = super(Move, cls).compute_quantities_query( location_ids, with_childs=with_childs, grouping=grouping, - grouping_filter=grouping_filter) + grouping_filter=grouping_filter, quantity_field=quantity_field) ++ ++ ++ return query ++ ++ # We avoid this part of code, and pass responsability to user to ++ # remove expired products from stock locations. ++ # This code had several problems and add inconsitence what you get ++ # in client and what you get in code ++ # In client you get all stock ++ # In code you get all stock without quanities expired ++ # Code tries to remove all quantities from expired products but ++ # introduces some issues on stock_supply procedure. ++ # - he substract all quantities from beginning to start_day, ++ # every day of planning ++ # - Even If you do not configure expired quantity, has anormal ++ # results in stock. ++ context = Transaction().context today = Date.today()