Fixed IsPaid for Incoming
This commit is contained in:
@@ -105,8 +105,7 @@ const getInvoiceSum = (invoice) => {
|
|||||||
const isPaid = (item) => {
|
const isPaid = (item) => {
|
||||||
let amountPaid = 0
|
let amountPaid = 0
|
||||||
item.statementallocations.forEach(allocation => amountPaid += allocation.amount)
|
item.statementallocations.forEach(allocation => amountPaid += allocation.amount)
|
||||||
|
return Math.abs(amountPaid) === Math.abs(Number(getInvoiceSum(item)))
|
||||||
return amountPaid === Number(getInvoiceSum(item))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user