From 5e4c8a52ee20df241f04519cfd66c4a1453c4b0a Mon Sep 17 00:00:00 2001 From: bohlian Date: Mon, 7 Dec 2015 12:06:08 +0800 Subject: [PATCH] Payment To Be Shown When Outstanding Amount != 0 Payment button should be shown when outstanding amount != 0. --- erpnext/accounts/doctype/purchase_invoice/purchase_invoice.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.js b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.js index db49a4ded9..6eb29fa55b 100644 --- a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.js +++ b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.js @@ -24,7 +24,7 @@ erpnext.accounts.PurchaseInvoice = erpnext.buying.BuyingController.extend({ if(!doc.is_return) { if(doc.docstatus==1) { - if(doc.outstanding_amount > 0) { + if(doc.outstanding_amount != 0) { this.frm.add_custom_button(__('Payment'), this.make_bank_entry).addClass("btn-primary"); } cur_frm.add_custom_button(__('Debit Note'), this.make_debit_note);