mirror of
https://github.com/frappe/erpnext.git
synced 2026-04-24 17:18:30 +00:00
fix(accounts): round and convert net_amount to company currency in JS tax controller
(cherry picked from commit b10b205394)
# Conflicts:
# erpnext/public/js/controllers/taxes_and_totals.js
This commit is contained in:
@@ -382,6 +382,7 @@ erpnext.taxes_and_totals = class TaxesAndTotals extends erpnext.payments {
|
|||||||
);
|
);
|
||||||
if (frappe.flags.round_row_wise_tax) {
|
if (frappe.flags.round_row_wise_tax) {
|
||||||
current_tax_amount = flt(current_tax_amount, precision("tax_amount", tax));
|
current_tax_amount = flt(current_tax_amount, precision("tax_amount", tax));
|
||||||
|
current_net_amount = flt(current_net_amount, precision("net_amount", tax));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Adjust divisional loss to the last item
|
// Adjust divisional loss to the last item
|
||||||
@@ -447,8 +448,12 @@ erpnext.taxes_and_totals = class TaxesAndTotals extends erpnext.payments {
|
|||||||
|
|
||||||
for (const [i, tax] of doc.taxes.entries()) {
|
for (const [i, tax] of doc.taxes.entries()) {
|
||||||
me.round_off_totals(tax);
|
me.round_off_totals(tax);
|
||||||
|
<<<<<<< HEAD
|
||||||
me.set_in_company_currency(tax,
|
me.set_in_company_currency(tax,
|
||||||
["tax_amount", "tax_amount_after_discount_amount"]);
|
["tax_amount", "tax_amount_after_discount_amount"]);
|
||||||
|
=======
|
||||||
|
me.set_in_company_currency(tax, ["tax_amount", "tax_amount_after_discount_amount", "net_amount"]);
|
||||||
|
>>>>>>> b10b205394 (fix(accounts): round and convert net_amount to company currency in JS tax controller)
|
||||||
|
|
||||||
me.round_off_base_values(tax);
|
me.round_off_base_values(tax);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user