From 731b15edf4cf6d98f19946ec141175473dca1cfe Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Sun, 5 Apr 2015 20:09:09 +0530 Subject: [PATCH] [hotfix] taxes and totals --- erpnext/controllers/taxes_and_totals.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/erpnext/controllers/taxes_and_totals.py b/erpnext/controllers/taxes_and_totals.py index 4c4f281637..bd7322543c 100644 --- a/erpnext/controllers/taxes_and_totals.py +++ b/erpnext/controllers/taxes_and_totals.py @@ -282,15 +282,15 @@ class calculate_taxes_and_totals(object): tax.total = flt(tax.total + discount_amount_loss, tax.precision("total")) self._set_in_company_currency(tax, ["total", "tax_amount_after_discount_amount"]) - + def manipulate_grand_total_for_inclusive_tax(self): # if fully inclusive taxes and diff if self.doc.get("taxes") and all(cint(t.included_in_print_rate) for t in self.doc.get("taxes")): last_tax = self.doc.get("taxes")[-1] - diff = self.doc.net_total - flt(last_tax.total / self.doc.conversion_rate, - self.precision("grand_total_export")) + diff = self.doc.net_total - flt(last_tax.total / self.doc.conversion_rate, + self.doc.precision("grand_total_export")) if diff and abs(diff) <= (2.0 / 10**last_tax.precision("tax_amount")): adjustment_amount = flt(diff * self.doc.conversion_rate, last_tax.precision("tax_amount"))