Open marination opened 1 year ago
The same we have discovered.
I also face the same issue. get_balance_on function has get the balance from general ledger, so I think there is no need to get payment entry
I am also struggling with very erroneous values in the Bank Reconciliation Tool. I am confused as to why all the complexity is needed. Shouldn't the bank balance match the general ledger balance for any given date? The problem with selecting just payments and journal entries is that other transaction types can also affect bank balance, such as Sales Invoice, Purchase Invoice, Loan Repayment, etc.
I agree. The reconciliation tool should just pull from the ledger balances for dates selected on the reconciliation tool. Also, it is possible the discrepancy with reconciliation balances may be related to this other issue: https://github.com/frappe/erpnext/issues/33932
Assume:
In https://github.com/frappe/erpnext/blob/develop/erpnext/accounts/doctype/bank_reconciliation_tool/bank_reconciliation_tool.py#L59-L83 :
balance_as_per_system
is nullified bytotal_debit
andtotal_credit
.get_balance_on()
essentially getssum(debit - credit)
until a certain datetotal debit = 12700
andtotal_credit = 240
,get_balance_on() = 12460
So here if all my GL Entries resulted from Payment + Journal Entries, the result would be 0.
_I would expect
get_account_balance
to give me the balance of 'HDFC - R' (bank account that has final impact after making payment) which would be 12460_Module
accounts
Version
ERPNext - v14 (latest)