Customizing Dunning Letter Templates
Read the following topics for guidance on customizing dunning letter templates:
-
Customizing the List of Invoices in the Dunning Template File
-
Including Fields from the Transaction Saved Search in Dunning Templates
-
Including Information from NetSuite Records in Dunning Templates
Customizing the Sample Dunning Template Files
The Dunning Letters SuiteApp provides three samples of dunning letter PDF templates in increasing levels of urgency. Use the content of the sample templates as a basis for creating new templates by copying the content from the sample files to your custom templates. Consolidated sample templates are located in the following file cabinet folder: SuiteBundles > Bundle 392827 > Templates > Consolidated.
Template Name |
Subject |
---|---|
Level 1 Default Template – English |
First Notice -Overdue Payments |
Level 2 Default Template – English |
Second Notice -Overdue Payments |
Level 3 Default Template – English |
Third Notice -Overdue Payments |
The templates included in the SuiteApp are samples intended to help you create custom templates. Copy the content of the sample template into a new file that you can customize. Creating templates requires knowledge of XML and FreeMarker.
In the sample templates provided by the Dunning Letters SuiteApp, be aware of the following:
-
In customer level dunning, the sample letter template shows the following:
-
The customer’s total overdue amount
Note:The overdue balance is sourced from the Overdue Balance field of the customer record, and is shown in the customer’s primary currency.
-
A list of the customer’s posting invoices that are overdue, and that do not have due dates, regardless of whether the invoices have dunning procedures assigned.
Note:You can customize your template to modify what shows in the list. See Customizing the List of Invoices in the Dunning Template File.
-
-
In invoice level dunning, the sample letter template shows the following:
-
The customer’s total overdue amount
Note:The overdue balance is sourced from the Overdue Balance field, and is shown in the customer’s primary currency.
-
Only one invoice in the list
-
-
In invoice group level dunning, the sample letter template shows the following:
-
The customer’s total overdue amount
Note:The overdue balance is sourced from the Overdue Balance field, and is shown in the customer’s primary currency.
-
List of invoices that are part of the invoice group
-
Customer dunning is used to evaluate all invoices of the customer. Invoice dunning is used for evaluating a specific invoice. Invoice group dunning is used to evaluate invoices that are part of an invoice group. See Understanding Customer Level Dunning, Invoice Level Dunning and Invoice Group Level Dunning.
Before creating custom templates, be sure to read Best Practices for Creating and Using Dunning Templates.
Use NetSuite email templates for dunning letters that will be sent by email. See Creating Dunning Letter Email Templates.
Use FreeMarker templates for dunning PDF letters. See Creating Dunning Letter PDF Templates.
To show NetSuite fields on a dunning letter template, a predefined transaction search is already provided. See Including Fields from the Transaction Saved Search in Dunning Templates.
To create dunning letter templates, read the following topics:
Customizing the List of Invoices in the Dunning Template File
In the sample templates provided by the Dunning Letters SuiteApp, if you use customer level dunning, the dunning letter shows a list of all the overdue invoices of the customer, including those invoices that have dunning procedures assigned.
Invoices that have dunning procedures assigned are marked with an asterisk. Invoice groups that have dunning procedure assigned are also marked with an asterisk.
You can customize your template to modify what shows in the list:
-
Marking Invoices That Have Dunning Procedures Assigned
Marking invoices enables your customers to identify the invoices for which separate dunning letters can be sent. Marking invoice groups enables your customers to identify the invoice groups for which separate dunning letters can be sent.
The sample template shows all invoices to be dunned, and uses an asterisk to mark the invoices that have dunning procedures assigned.
The following sample code snippet checks for invoices that have dunning procedures assigned, and marks them with an asterisk:
<#if invoice.custbody_3805_dunning_procedure != "">*</#if>
The following sample code snippet checks for invoice groups that have dunning procedures assigned, and marks them with an asterisk:
<#if invoicegrouprecord.custrecord_dl_ig_dunning_procedure!="">*</#if>
You can add some text to explain what the asterisk means. For example, you can add text saying that the customer receive separate dunning letters for those marked invoices.
You can use a different way of marking the invoices, if you do not want to use an asterisk.
-
Showing all Invoices
The following sample code snippet includes all invoices to be dunned:
<#list invoicelist as invoice> <tr> <td>${invoice.tranid}</td> <td>${invoice.memo}</td> <td>${invoice.trandate}</td> <td>${invoice.duedate}</td> <td>${invoice.currency}</td> <td>${invoice.fxamountremaining?string.number}</td> </tr> </#list>
-
Hiding Invoices With Dunning Procedures
You can hide the invoices that have dunning procedures if you do not want them included in the list.
The following sample code snippet includes only those invoices that do not have a dunning procedure assigned:
<#list invoicelist as invoice> <#if invoice.custbody_3805_dunning_procedure == ""> <tr> <td>${invoice.tranid}</td> <td>${invoice.memo}</td> <td>${invoice.trandate}</td> <td>${invoice.duedate}</td> <td>${invoice.currency}</td> <td>${invoice.fxamountremaining?string.number}</td> </tr> </#if> </#list>
-
Showing all Invoice Groups
The following sample code snippet includes all invoice groups to be dunned:
<#list invoicegrouplist as invoicegrouprecord> <tr> <td>Invoice Group #${invoicegrouprecord.invoicegroupnumber} <#if invoicegrouprecord.custrecord_dl_ig_dunning_procedure!="">* </#if> </td> </tr> <#list invoicelist as invoice> <#if invoice.groupedto==invoicegrouprecord.invoicegroupnumber> <tr> <td>${invoice.tranid} <#if invoice.custbody_3805_dunning_procedure !="">*</#if> </td> <td>${invoice.memo}</td> <td>${invoice.trandate}</td> <td>${invoice.duedate}</td> <td>${invoice.currency}</td> <td>${invoice.fxamountremaining?string.number}</td> </tr> </#if> </#list> </#list>
-
Hiding Invoice Groups With Dunning Procedures
You can hide the invoice groups that have dunning procedures if you do not want them included in the list.
The following sample code snippet includes only those invoice groups that do not have a dunning procedure assigned:
<#list invoicegrouplist as invoicegrouprecord> <#if invoicegrouprecord.custrecord_dl_ig_dunning_procedure == ""> <tr> <td>Invoice Group #${invoicegrouprecord.invoicegroupnumber}</td> </tr> <#list invoicelist as invoice> <#if invoice.groupedto==invoicegrouprecord.invoicegroupnumber> <tr> <td>${invoice.tranid} <#if invoice.custbody_3805_dunning_procedure !="">*</#if> </td> <td>${invoice.memo}</td> <td>${invoice.trandate}</td> <td>${invoice.duedate}</td> <td>${invoice.currency}</td> <td>${invoice.fxamountremaining?string.number}</td> </tr> </#if> </#list> </#if> </#list>