Merge pull request #53406 from ljain112/fix-item-valaution-deduct

This commit is contained in:
Smit Vora
2026-03-30 19:53:55 +05:30
committed by GitHub
2 changed files with 65 additions and 2 deletions

View File

@@ -503,11 +503,15 @@ class BuyingController(SubcontractingController):
if d.category not in ["Valuation", "Valuation and Total"]:
continue
amount = flt(d.base_tax_amount_after_discount_amount) * (
-1 if d.get("add_deduct_tax") == "Deduct" else 1
)
if d.charge_type == "On Net Total":
total_valuation_amount += flt(d.base_tax_amount_after_discount_amount)
total_valuation_amount += amount
tax_accounts.append(d.account_head)
else:
total_actual_tax_amount += flt(d.base_tax_amount_after_discount_amount)
total_actual_tax_amount += amount
return tax_accounts, total_valuation_amount, total_actual_tax_amount