[Fix] Payment entry account Paid To Show receivable accounts for supplier

This commit is contained in:
Rohit Waghchaure 2017-02-24 15:07:54 +05:30
parent 5278da8901
commit b983f26b98

View File

@ -11,9 +11,8 @@ frappe.ui.form.on('Payment Entry', {
},
setup: function(frm) {
var party_account_type = frm.doc.party_type=="Customer" ? "Receivable" : "Payable";
frm.set_query("paid_from", function() {
var party_account_type = frm.doc.party_type=="Customer" ? "Receivable" : "Payable";
var account_types = in_list(["Pay", "Internal Transfer"], frm.doc.payment_type) ?
["Bank", "Cash"] : party_account_type;
@ -35,6 +34,7 @@ frappe.ui.form.on('Payment Entry', {
});
frm.set_query("paid_to", function() {
var party_account_type = frm.doc.party_type=="Customer" ? "Receivable" : "Payable";
var account_types = in_list(["Receive", "Internal Transfer"], frm.doc.payment_type) ?
["Bank", "Cash"] : party_account_type;