mirror of
https://github.com/frappe/books.git
synced 2024-11-13 00:46:28 +00:00
Merge pull request #12 from piyushsinghania/fix/partial-payment-ledger-entry-issue
Fixed the general ledger entry issue while doing partial payments
This commit is contained in:
commit
17bf07a3ae
@ -15,9 +15,7 @@ module.exports = class PaymentServer extends BaseDocument {
|
||||
async getPosting() {
|
||||
let entries = new LedgerPosting({ reference: this, party: this.party });
|
||||
await entries.debit(this.paymentAccount, this.amount);
|
||||
for (let row of this.for) {
|
||||
await entries.credit(this.account, row.amount);
|
||||
}
|
||||
await entries.credit(this.account, this.amount);
|
||||
return entries;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user