Fix Bank Reconcilaition for Payment Entries (#19190)
* Fix Bank Reconciliation with Payment Entries * Update bank_reconciliation.js
This commit is contained in:
parent
8b2223ae5f
commit
a227b9a9a6
@ -529,9 +529,16 @@ erpnext.accounts.ReconciliationRow = class ReconciliationRow {
|
||||
frappe.db.get_doc(dt, event.value)
|
||||
.then(doc => {
|
||||
let displayed_docs = []
|
||||
let payment = []
|
||||
if (dt === "Payment Entry") {
|
||||
payment.currency = doc.payment_type == "Receive" ? doc.paid_to_account_currency : doc.paid_from_account_currency;
|
||||
payment.doctype = dt
|
||||
payment.posting_date = doc.posting_date;
|
||||
payment.party = doc.party;
|
||||
payment.reference_no = doc.reference_no;
|
||||
payment.reference_date = doc.reference_date;
|
||||
payment.paid_amount = doc.paid_amount;
|
||||
payment.name = doc.name;
|
||||
displayed_docs.push(payment);
|
||||
} else if (dt === "Journal Entry") {
|
||||
doc.accounts.forEach(payment => {
|
||||
@ -564,8 +571,8 @@ erpnext.accounts.ReconciliationRow = class ReconciliationRow {
|
||||
|
||||
const details_wrapper = me.dialog.fields_dict.payment_details.$wrapper;
|
||||
details_wrapper.append(frappe.render_template("linked_payment_header"));
|
||||
displayed_docs.forEach(values => {
|
||||
details_wrapper.append(frappe.render_template("linked_payment_row", values));
|
||||
displayed_docs.forEach(payment => {
|
||||
details_wrapper.append(frappe.render_template("linked_payment_row", payment));
|
||||
})
|
||||
})
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user