mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-05 19:42:45 +00:00
fix: creation of return/debit note from sales invoice
This commit is contained in:
committed by
GitHub
parent
9905b9e4b0
commit
dd10087db6
@@ -136,7 +136,7 @@ erpnext.accounts.PurchaseInvoice = class PurchaseInvoice extends erpnext.buying.
|
||||
|
||||
if (!doc.is_return && doc.docstatus == 1) {
|
||||
if (doc.outstanding_amount >= 0 || Math.abs(flt(doc.outstanding_amount)) < flt(doc.grand_total)) {
|
||||
this.frm.add_custom_button(__("Return / Debit Note"), this.make_debit_note, __("Create"));
|
||||
this.frm.add_custom_button(__("Return / Debit Note"), this.make_debit_note.bind(this), __("Create"));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user