Hello,
I've starting to struggle with multi-currencies and Realized/UnrealizedGainLoss stuff.
I'm not an expert, so I may miss something :)
Here's my scenario :
Accounting Schema in USD
1 invoice of 12000 EUR (July) partially paid (10000) on September
If Invoice is made by Org1 and Payment by Org2, the allocation generate this posting :
Which seems correct (the realized gain/loss is recorded)
But if Invoice is made by Org1 and Payment by Org1, the allocation generate nothing
Which seems incorrect as the realized gain/loss is not recorded.
Debugging, I found the reason on Doc_AllocationHdr (line 252)
if ((!as.isPostIfClearingEqual()) && acct_unallocated_cash != null && acct_unallocated_cash.equals(acct_receivable) && (!isInterOrg)) {
// if not using clearing accounts, then don't post amtsource
// change the allocationsource to be writeoff + discount
allocationSource = line.getDiscountAmt().add(line.getWriteOffAmt());
}
Is it normal to check if the allocation is an 'inter org' one ? I mean, in any case, there is a gain or a loss, no ?
Or should I avoid to use PostIfClearingEqual to force the generation of those lines ?
Thanks,
Nicolas