action.skip

Scheduling Payment Bookkeeping Data Generation

Creating booking details from payment balances on a regular basis requires a job that calls the appropriate batch process BatchBalanceExportJob provided by JustOn Billing & Invoice Management.

Info

Be aware of the following specifics:

  • JustOn recommends to schedule the payment bookkeeping data job for daily execution.

    By default, JustOn generates booking details for balances that have been created or modified in the past eight days (according to the SystemModstamp information). This is why the payment bookkeeping data job must run at least once per week, otherwise it does not detect all new, changed or deleted balances. The detection of deleted balances is improved if they are still available in the recycle bin. If you delete balances on a regular basis, you must align the operations for creating payment bookkeeping data and emptying the recycle bin.

    You can, however, overwrite the default period of past eight days using a dedicated batch parameter setting, see Overwriting Default Period.

  • For the payment bookkeeping data creation to work, the global setting Create Bookkeeping Data must be selected.

  • The payment bookkeeping data creation supports the custom Account field ON_DebtorNo. The debtor number is used as the primary bookkeeping account number for a payment booking detail, see Assigning Bookkeeping Accounts.
  • The payment bookkeeping data creation supports the custom Balance field ON_ProviderFee for calculating the payment provider fees based on your payment provider contract. If the field is not available or empty, JustOn uses the standard Provider Fee field, see Handling Provider Fees.

Overwriting Default Period

The payment bookkeeping data creation job allows for an optional parameter that overwrites the default period to consider balance modifications. If, for example, the job executions uses too many resources because of a large number of balances to process, you can set a shorter period to consider and, consequently, adjust the execution interval for the payment bookkeeping data job accordingly.

To overwrite the default period of relevant balance modifications, you create a specific batch parameters setting for the payment bookkeeping data creation job.

  1. Click to enter Setup, then open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Batch Parameters.

  3. Click New.
  4. Specify the details as required.

    • Name: BatchBalanceExportJob

      Using the original batch chain name overwrites the default settings.

    • Batch Chain: BatchBalanceExportJob

    • Parameter 1: Period, an integer that specifies the required number of past days to consider balance modifications (according to the SystemModstamp information)

      Assuming you want to consider the balance modifications of the past three days, set

      Period = 3
      
  5. Click Save.

Scheduling Export Balances Job

To schedule the payment bookkeeping data creation job, you can use either JustOn's Scheduled Jobs page or Salesforce's Schedule Apex functionality. For details, see Scheduling a Job.

Via JustOn's Scheduled Jobs page:

  1. Open the Scheduled Jobs page.

    Use the following URL https://login.salesforce.com/apex/ONB2__JobsSetup, or, if you are already logged in, append apex/ONB2__JobsSetup to your org's domain name.

    You can access the Scheduled Jobs page via the JustOn configuration app ( > JustOn Configuration > Jobs Setup).

  2. From the Apex Job drop-down list, select Export Balances Job.

    The Job Name field is automatically set to BatchBalanceExportJob.

  3. From the Start Time drop-down list, select the preferred execution time.

  4. Optionally, edit the displayed cron expression to adjust the execution time.
  5. Click Schedule.

    This sets up the payment bookkeeping data creation to be executed at the specified time.

Info

From the Scheduled Jobs page, you can also run the job immediately.

Via Salesforce's Schedule Apex functionality:

  1. Click to enter Setup, then open Apex Classes.

    In Salesforce Lightning, navigate to Custom Code > Apex Classes.

    In Salesforce Classic, navigate to Develop > Apex Classes.

  2. Click Schedule Apex on top of the list.

  3. Specify the details as required.

    • Job Name
    • Apex Class: BatchBalanceExportJob
    • Frequency
    • Start
    • End
    • Preferred Start Time
  4. Click Save.

    This sets up the payment bookkeeping data creation to be executed at the specified time.

For more details about job scheduling, see Scheduling a Job in the JustOn documentation and Schedule Apex in the Salesforce Help.