mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-03 21:48:27 +00:00
Merge branch 'staging' into develop
This commit is contained in:
@@ -65,6 +65,7 @@ class calculate_taxes_and_totals(object):
|
||||
|
||||
if item.doctype in ['Quotation Item', 'Sales Order Item', 'Delivery Note Item', 'Sales Invoice Item']:
|
||||
item.rate_with_margin, item.base_rate_with_margin = self.calculate_margin(item)
|
||||
|
||||
if flt(item.rate_with_margin) > 0:
|
||||
item.rate = flt(item.rate_with_margin * (1.0 - (item.discount_percentage / 100.0)), item.precision("rate"))
|
||||
item.discount_amount = item.rate_with_margin - item.rate
|
||||
|
||||
Reference in New Issue
Block a user