mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-20 21:49:18 +00:00
Merge pull request #46814 from frappe/mergify/bp/version-15-hotfix/pr-46812
fix: revert resetting `rounding_adjustment` (backport #46812)
This commit is contained in:
@@ -643,7 +643,7 @@ class calculate_taxes_and_totals:
|
|||||||
|
|
||||||
if self.doc.meta.get_field("rounded_total"):
|
if self.doc.meta.get_field("rounded_total"):
|
||||||
if self.doc.is_rounded_total_disabled():
|
if self.doc.is_rounded_total_disabled():
|
||||||
self.doc.rounded_total = self.doc.base_rounded_total = self.doc.rounding_adjustment = 0
|
self.doc.rounded_total = self.doc.base_rounded_total = 0
|
||||||
return
|
return
|
||||||
|
|
||||||
self.doc.rounded_total = round_based_on_smallest_currency_fraction(
|
self.doc.rounded_total = round_based_on_smallest_currency_fraction(
|
||||||
|
|||||||
@@ -343,6 +343,7 @@ erpnext.taxes_and_totals = class TaxesAndTotals extends erpnext.payments {
|
|||||||
|
|
||||||
calculate_taxes() {
|
calculate_taxes() {
|
||||||
var me = this;
|
var me = this;
|
||||||
|
this.frm.doc.rounding_adjustment = 0;
|
||||||
var actual_tax_dict = {};
|
var actual_tax_dict = {};
|
||||||
|
|
||||||
// maintain actual tax rate based on idx
|
// maintain actual tax rate based on idx
|
||||||
@@ -626,7 +627,6 @@ erpnext.taxes_and_totals = class TaxesAndTotals extends erpnext.payments {
|
|||||||
if (cint(disable_rounded_total)) {
|
if (cint(disable_rounded_total)) {
|
||||||
this.frm.doc.rounded_total = 0;
|
this.frm.doc.rounded_total = 0;
|
||||||
this.frm.doc.base_rounded_total = 0;
|
this.frm.doc.base_rounded_total = 0;
|
||||||
this.frm.doc.rounding_adjustment = 0;
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user