Configuring Payment Due Date Calculation
Usually, JustOn determines the Payment Due Date of an invoice adding the value of Payment Due (in days) to the set Invoice Date.
For details on payment due date concepts, see Payment Due Date.
Your business may, however, require a more flexible way for determining the Payment Due Date – like, for example, you want it always to be set automatically to the last day of the next month. To this end, use the Invoice field Payment Due Condition. It provides a way to define a custom calculation for the Payment Due Date and for the Payment Due value. JustOn evaluates the Payment Due Condition on invoice creation and on invoice finalization.
Posiible calculation options
The following table lists the calculation options for Payment Due Condition and illustrates the behavior:
| Pattern | Result | Example Invoice Date | Example Payment Due Condition | Calculated Payment Due (Date) |
|---|---|---|---|---|
xd |
Adds x days to the invoice date. |
2018-01-01 | 14d |
14 (2018-01-15) |
xd eom |
Adds x days to the invoice date, then goes to the last day of the month. |
2018-05-20 | 14d eom |
41 (2018-06-30) |
eom |
Starting from the invoice date, goes to the last day of the month. | 2018-02-05 | eom |
23 (2018-02-28) |
xd y |
Adds x days to the invoice date, then goes to the next yth day of the month. |
2018-01-01 | 14d 10 |
40 (2018-02-10) |
eom y |
Goes to the last day of the month, then goes to the next yth day of the next month. |
2018-02-12 | eom 10 |
26 (2018-03-10) |
y |
Starting from the invoice date, goes to next yth day of the month. |
2018-02-12 | 16 |
4 (2018-02-16) |
xd eom y |
Adds x days to the invoice date, then goes to the last day of the month, then goes to the next yth day of the next month. |
2018-05-20 | 14d eom 20 |
61 (2018-07-20) |
Note
Each evaluation recalculates the values for Payment Due Date and Payment Due. Hence, do not set Payment Due when using Payment Due Condition.
JustOn Billing & Invoice Management ships a number of predefined payment due conditions. Depending on your business requirements, you may have to add more options. Doing so involves two steps:
- adding the calculation option to the
Payment Due Conditionpicklist, and - providing a user-friendly name (or translation) for the picklist value.
Adding New Payment Due Condition
- Click to enter Setup, then navigate to the object management settings of the Invoice object (
ONB2__Invoice__c). - Click Fields & Relationships.
- Click the name of the
Payment Due Conditionfield. -
In the Values section, click New.
Add the new calculation options as required, each in a new line, like
10d eom
eom 20Pattern Result xdAdds xdays to the invoice date.xd eomAdds xdays to the invoice date, then goes to the last day of the month.eomStarting from the invoice date, goes to the last day of the month. xd yAdds xdays to the invoice date, then goes to the nextyth day of the month.eom yGoes to the last day of the month, then goes to the next yth day of the next month.yStarting from the invoice date, goes to next yth day of the month.xd eom yAdds xdays to the invoice date, then goes to the last day of the month, then goes to the nextyth day of the next month.The spelling of
eomin the picklist values does not matter – you can use lowercase, all caps or mixed-case spelling. JustOn converts the letters to lowercase before processing the payment due condition. -
Click Save.
This saves the new payment due calculation options.
For help about editing picklists, see Modifying Picklist Values.
Adding Labels or Translations to New Payment Due Conditions
To translate the new picklist values or to provide user-friendly names, you use the Translation Workbench:
- Click to enter Setup, then navigate to User Interface > Translation Workbench > Translate.
- Select the target language.
- In the
Setup Componentfield, selectPicklist Value. - In the
Objectfield, selectInvoice. - Under
Master Picklist Value Label, expand thePayment Due Conditionfield. - In the row of the relevant picklist value, click in the translation field.
- Specify the label or translation as required.
- Click Save.
For details, see Translate Metadata Labels in the Salesforce Help.