AppBase enables you to use templates for HTML Emails and/or Microsoft Word and use them in any AppBase application to populate fields in the template with specific content from your application. For example, you might use a New Customer Welcome Letter template to pull information from the BOM to create a PDF containing each customer’s information. The resulting letter could be placed in the CMS and work like any other file.
Navigate to Letter Template. Click the green + New Letter Template button.
- Select Type as Email Html, insert Name as LOAN APPROVAL NOTIFICATION, select Root Object Type as Case, add GBANK LOAN APPROVAL NOTIFICATION for Description. Click the Save button.
Click the Template Content button, type Auto Loan Application Notification for Email Subject, and insert the following text in the Email Body:CODE
Dear @@, We are pleased to approve your Auto Loan application. The loan amount is $@@; the annual interest rate is 4%. If you have any questions, please call our local branch or @@, your representative will help you.
- From the bookmark button at the top left menu, you can select any of the available bookmarks in this solution.
- From the list of available placeholders, select @APPLICANT_NAME@ and drag&drop it after Dear.
- Select @APPLICANT_LOAN_AMOUNT@ from the list of available placeholders and place it after the dollar sign of the loan amount.
Position the cursor in the @@ in the text ‘local branch or @@, your representative…’. Now click on the Placeholder icon(1) to select CASE_OWNER from the list(2). Click OK.
- Save your work
- Click the Test Template button and using a valid case ID (Object ID) and an email address execute the template (you are suggested to use the email assigned for this training XX@eccentexcloud.com).
You can also populate the values of the bookmarks using the fields under the Placeholders section.
- If everything was OK, you will receive an email like below in your inbox (please check the Junk folder if you do not receive it in a couple of seconds).
- Save the template and Publish You will see your new template listed and ready to be used. Now that our template is tested and published let's hook it up with the workflow.
- Go back to the Setup application and open the Auto Loan milestone diagram.
- Fill the TemplateCode parameter with the code of our new template (LOAN_APPROVAL_NOTIFICATION) in the Email Decision rule (CUST_ltr_send_email).
- Save the changes to the milestone diagram and close the window.
Email Templates with Attachments
- Navigate to Letter Templates. Click the +New Letter Template green button.
- Select Type as Email Html, insert Name as LOAN REVIEW NOTIFICATION, select Root Object Type as Case, add GBANK LOAN REVIEW NOTIFICATION for Description.
- Save the new Template.
- After saving, you will see a new section called Default attachment list, Click the plus (+) button and select the NOTIFICATION_LETTER from the template the list.
Save the template.
Click the Template Content button, in the Subject field insert Auto Loan Review Notification - @CASE_ID@, in the Email From insert email@example.com
In the Email Body section click the Source button and paste the following HTML code:XML
<p>Dear <strong>@APPLICANT_NAME@</strong></p> <p>After a thoroughly review of your Auto Loan application #<strong>@Case.CaseId@</strong>, we are requiered to ask you for supplementary docucumentation.</p> <p>If you have any questions, please call our local branch or contact your representative <a href="mailto:@USRS_EMAIL@?subject=Auto Loan Review Notification - @CASE_ID@">@USRS_FULLNAME@</a>, who will be happy to help you.</p> <p> Best regards, @COMPANY_NAME@ </p>
Click the Source button again to go back to the WYSIGYG editor
The template will not save your changes when the editor is in the Source view, you must un-select Source view before saving it.
Save the template.
Click the Test Template button and using a valid case ID (Object ID) and an email address (you are suggested to use the email assigned for this training XX@eccentexcloud.com) execute the template.
Save the template and Publish it.