public static Map<String,Object> updatePaymentApplication(DispatchContext dctx,Map<String,Object> context){
  if (!context.containsKey("useHighestAmount")) {
    context.put("useHighestAmount","N");
  }
  BigDecimal amountApplied=(BigDecimal)context.get("amountApplied");
  if (amountApplied != null) {
    context.put("amountApplied",amountApplied);
  }
 else {
    context.put("amountApplied",ZERO);
  }
  return updatePaymentApplicationDefBd(dctx,context);
}

public static Map < String , Object > updatePaymentApplication ( DispatchContext dctx , Map < String , Object > context ) { if ( ! context . containsKey ( "useHighestAmount" ) ) { context . put ( "useHighestAmount" , "N" ) ; } BigDecimal amountApplied = ( BigDecimal ) context . get ( "amountApplied" ) ; if ( amountApplied != null ) { context . put ( "amountApplied" , amountApplied ) ; } else { context . put ( "amountApplied" , ZERO ) ; } return updatePaymentApplicationDefBd ( dctx , context ) ; }
service to add payment application records to indicate which invoices have been paid / received . for invoice processing , this service works on the invoice level when ' invoiceprocessing ' parameter is set to " y " else it works on the invoice item level .
