Fix: Since pydantic v2 is sending decimal as string. It is fucking things up.

This commit is contained in:
Amritanshu Agrawal 2023-08-15 06:39:02 +05:30
parent c0458ed96e
commit 84728eb037

View File

@ -95,13 +95,13 @@ export class LedgerComponent implements OnInit, AfterViewInit {
this.running = 0;
this.info.body.forEach((item) => {
if (item.type !== 'Opening Balance') {
this.debit += item.debit;
this.credit += item.credit;
this.debit += +item.debit;
this.credit += +item.credit;
if (item.posted) {
this.running += item.debit - item.credit;
this.running += +item.debit - +item.credit;
}
} else {
this.running += item.debit - item.credit;
this.running += +item.debit - +item.credit;
}
item.running = this.running;
});