mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-24 13:42:10 +01:00
fix: pos return throwing amount greater than grand total
(cherry picked from commit 35c70f39fa)
This commit is contained in:
@@ -124,8 +124,8 @@ erpnext.taxes_and_totals = erpnext.payments.extend({
|
|||||||
item.net_amount = item.amount = flt(item.rate * item.qty, precision("amount", item));
|
item.net_amount = item.amount = flt(item.rate * item.qty, precision("amount", item));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
let qty = item.qty || 1;
|
// allow for '0' qty on Credit/Debit notes
|
||||||
qty = me.frm.doc.is_return ? -1 * qty : qty;
|
let qty = item.qty || -1
|
||||||
item.net_amount = item.amount = flt(item.rate * qty, precision("amount", item));
|
item.net_amount = item.amount = flt(item.rate * qty, precision("amount", item));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user