IDEMPIERE-4324 Fix NPE on payment allocation (#115)
Co-authored-by: Orlando Curieles <orlando.curieles@ingeint.com>
This commit is contained in:
parent
c0710da6cd
commit
36d6644879
|
@ -230,10 +230,11 @@ public class Doc_AllocationHdr extends Doc
|
|||
{
|
||||
fl = fact.createLine (line, getPaymentAcct(as, line.getC_Payment_ID()),
|
||||
getC_Currency_ID(), line.getAmtSource(), null);
|
||||
if (fl != null && payment != null)
|
||||
if (fl != null && payment != null) {
|
||||
fl.setAD_Org_ID(payment.getAD_Org_ID());
|
||||
allocPayAccounted = allocPayAccounted.add(fl.getAcctBalance());
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
p_Error = "Cannot determine SO/PO";
|
||||
|
|
Loading…
Reference in New Issue