fix: print Total, Additional Discount, Net Total in that order

Default Standard Sales Invoice and Tax Invoice/Receipt printed the
Additional Discount Amount among the charges, after the Total line but
with no total after the discount. App copies of ERPNext's totals
includes are swapped in via doc.print_templates:

- taxes.html: a discount on Net Total is followed by the Net Total line
  ahead of the charges; a discount on Grand Total stays after them.
- total.html: with inclusive tax, "Total (Without Tax)" is the total
  before the discount (net_total + discount_amount); upstream printed
  net_total, which already has the discount taken off, so the same
  figure appeared before and after the discount line.
This commit is contained in:
2026-09-17 10:02:23 +00:00
parent 8cba58ba02
commit 71eda0bec9
3 changed files with 53 additions and 2 deletions
File diff suppressed because one or more lines are too long