changeset 17c9731089fd in modules/account_stock_anglo_saxon:5.0
details:
https://hg.tryton.org/modules/account_stock_anglo_saxon?cmd=changeset;node=17c9731089fd
description:
Round cost with company instead of invoice currency
issue8186
review259091002
(grafted from b69bc1a680f4c1307b390597a09e7e0e46b24fab)
diffstat:
invoice.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff -r c68753a13eaa -r 17c9731089fd invoice.py
--- a/invoice.py Tue Feb 19 21:58:37 2019 +0100
+++ b/invoice.py Fri Mar 08 18:53:15 2019 +0100
@@ -115,7 +115,7 @@
moves.sort(key=operator.attrgetter('effective_date'))
cost = Move.update_anglo_saxon_quantity_product_cost(
self.product, moves, abs(self.quantity), self.unit, type_)
- cost = self.invoice.currency.round(cost)
+ cost = self.invoice.company.currency.round(cost)
with Transaction().set_context(date=accounting_date):
anglo_saxon_move_lines = self._get_anglo_saxon_move_lines(