Issues found on Payment Selection process


On the research to support found some issues.

The review covered the full Payment Selection process that includes Payment Selection manual and automatic, Generate Checks and Payment Print/Export.

I'll annotate here the findings with class/method to ease resolution:

  • Payment Selection Manual:

    • WPaySelect.onEvent: The lines are refreshed when changing BP or doctype or pushing the refresh button - could be improved to refresh on onlydue and paymentrule changes too

    • WPaySelect.loadTableInfo: it has a code to show the due invoices in different color, but is not working

    • WPaySelect.generatePaySelect: The code to call the form 106 Payment Print/Export is broken. Must be moved to a callback or deprecated. See

    • PaySelect.getPaymentRuleData: is getting also inactive payment rules

    • PaySelect.generatePaySelect: out of transaction, dangerous, if a line fails the header is still there

    • WPaySelect is showing correctly the schedule records of an invoice, but the due date is wrong - leading to wrong schedule records shown with only due invoices flag

    • PaySelect.getDocTypeData: Is just selecting API/APC, two comments here

      • APC probably is not well supported (require testing)

      • Can also include AR documents

      • In the end probably we just support API/ARI - check if APC/ARC have issues

  • Payment Selection Create (button on window)

    • running PaySelectionCreateFrom repeated the invoices - must just add new

    • issotrx=N - must be a parameter if we want to support direct debit with this process too

    • The process is getting the records from C_Invoice instead of C_Invoice_V (as manual does) - this must be leading to error on selected schedule records for only due parameter (test required to confirm)

  • Payment Create Check

    • seems ok

  • Payment Print/Export

    • PayPrint.getPaySelectionData not used (deprecate or delete)

    • PayPrint.cmd_export and cmd_print: both are creating and completing payments out of transaction, if something fails in the middle the process can leave partial things

    • Maybe would be better to separate the confirmation/creation of payments in a separate process


Carlos Ruiz




Nicolas Micoud
September 16, 2019, 7:37 AM

HI ,

Please find a patch to handle the PayAmt null (see!topic/idempiere/cbv8917XX00




Carlos Ruiz


Carlos Ruiz



Tested By