changeset 19a69c93a7a5 in modules/product_cost_fifo:default
details: 
https://hg.tryton.org/modules/product_cost_fifo?cmd=changeset;node=19a69c93a7a5
description:
        Do not get product from last fifo moves but from self move

        The fifo moves can be empty and so move is undefined.

        issue7918
diffstat:

 move.py |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r bb9c35dc27b3 -r 19a69c93a7a5 move.py
--- a/move.py   Sun Apr 07 19:50:03 2019 +0200
+++ b/move.py   Wed Apr 10 09:55:06 2019 +0200
@@ -74,7 +74,7 @@
         # Compute average cost price
         unit_price = self.unit_price
         self.unit_price = Uom.compute_price(
-            move.product.default_uom, cost_price, self.uom)
+            self.product.default_uom, cost_price, self.uom)
         average_cost_price = self._compute_product_cost_price('out')
         self.unit_price = unit_price
 

Reply via email to