Preparing a New Email Template

From the menu in ShareDo, select Open Document Admin.

In the left-hand panel, select Document Templates / Email Templates.

The existing email templates can be seen:

  1. Click at the top right to begin the creation process.
  2. A Prepare Email blade appears. Enter an internal System Name, a Name (that will be seen by users) and a Description.
  3. Select a Category in which the new email will be presented in the Prepare Document menu.
  4. Data Context: as with document templates, this option will determine what work types, etc the Email can be used with, who the Recipients can be and crucially, what Tags will be available to be inserted into the email from the Data Composer.
  5. Question Sets: to whom will this email be sent? Select from the list of Roles. This list is determined by the Data Context.

Note that the end user (the person who actually sends the email) will select whether the recipients receive the email as part of the To, CC or BC. This cannot be set here.

Pack Contents Nav Bar

  1. Enter an Output Title for the email – this is the title of the email that users will see within ShareDo.
  2. The Output File Name is the name of the physical file that is generated and stored in the Document Management system. Unless instructed otherwise by your implementation team, accept the default.
  3. Email Subject: By default, this will be the same as the Output Title. Toggle the “Same as Title” option off to allow another Subject description to be used.
  4. Source: the body of the email is created and maintained here.
  5. Click Confirm to apply the changes.

Output & Delivery Nav Bar

  1. Select the Default Folder into which the generated email will be saved.
  2. As with Document Templates, note the Vary by Type option that allows the generated email to be saved into different folders according to the actual Context of the matter. For example, the email can be assigned to a high-level Context of “Real Estate,” and by default, any generated emails are added to the Email folder. However, for certain types of work, e.g., Easements, the email can be saved into a different folder altogether.
  3. Click Confirm to apply the changes.
  4. Click Save to save progress to date.

Note that a new “Tag Browser” button appears in the blade menu.

Tag Browser

The Tag Browser button provides access to the Data Composer. This function provides access to all the data elements that reside within the Context that has been selected for this email. E.g. If the Context was the Property Acquisition work type, then all the standard and bespoke data elements that form part of that work type could be viewed from within this option.

See Data Composer for full details of the Data Composer.

The Data Composer is presented here both for reference and for debugging purposes. However, the Data Composer is also available in the Pack Contents nav bar where the actual body of the email can be created.

Email Tagging

Now that a Context has been assigned to the email, we can start creating the body of the email, using a combination of text and Data Composer Tags.

  1. Open the Pack Contents nav bar and click on the Edit icon to open the HTML editor:

    Note the toolbar options that allow standard formatting, lists, numbering, alignment, etc. In a moment, we will return to the tagging options at the far right (highlighted in red). You may need to click the three dots to open the Show More menu, which includes the tagging options.
  2. Enter the body text required, leaving spaces for any Tags that need to be inserted.
    For example:
  3. Click in the body where the Tag needs to be inserted, then click on the Tag icon in the toolbar.
    The Data Composer will appear. Tags from 3 main areas can be used: the current Activity (e.g. the matter), the current Document (including Email) that is being generated or the Environment (e.g. the date).

    So, for example, you may wish to look at the Participant Roles for the matter to obtain, say, the Matter Partner Tag. But, you may also wish to look at the Participant Roles for the Document to obtain, say, the name of the Creator of the document / email.


    Remember:
    Click on the to drill down into each section.
    The navigation path at the top of the blade will display the name of the current data set. Click on the name to move back and forth between the different forms (in red, above)
    Where present, click on the to the right of a data element to select it for insertion into the email body.
    Tag the body text. Here are several Tags which you may find useful:

Matter Reference: context.reference

First name of the Recipient: document.activity.roles.email-to-recipient!1.ods.person.firstName

Sender’s Direct Dial Number: document.activity.roles.creator.ods.contact.direct-line!1.value

Sender’s Name: document.activity.roles.creator.ods.name

When finished, it should look something like this:

Testing the HTML Email

  1. Click the Confirm button at the top right. The blade will close.
  2. Click Confirm again, then Save, to save the changes.

As always, when amending configuration, click on the icon at the bottom left of ShareDo to update your cache.

  1. Open a separate browser window and select a matter that has the same Context as the email you’ve just created.
  2. Create the email.
    Note the following:
    If there is only one Recipient, they will be assigned into the To: section.

    If there are multiple Recipients, the user will need to select each of them using this option here:

    Most of the Tags in the email body will have been replaced with the appropriate data:

    Note the Recipients name Tag is still visible. This is because ShareDo does not know to whom the email will actually be sent at this stage. The user may change the Recipient or add more.

    Note the Refresh icon to the right of the About section:

    This will completely remove the email body and replace it with the latest version of the template and the corresponding Tag data.
  3. Click Refresh to convert the Tag into the Recipient’s name. Note that if there are multiple Recipients, then each of their names would be shown here – something to consider when designing the email template.

It is important to note that if the user attempts to send an email that still has Tags in the body, the Phase Guards would trigger and prevent it from being sent out.

 

TIP! Using the Refresh function is a good way to see / test the latest changes that have been made to the underlying email template.

 
  1. Try it. Leave this email open. Return to the template email in the other browser window. Navigate thru Pack Contents / Source / Edit and amend the email body in some way. E.g. add some new text.
  2. Click Confirm / Confirm / Save. Finally, update the cache:

Now, revert back to the browser window with the matter and the email still visible. Click the Refresh button – note how the body is updated to reflect your changes.

Ok, going forward, let summarise these Confirm, Save and Refresh steps into the phrase “Save and test your changes”.

Formatting Tags

Tags in HTML Emails can be formatted as Tags used in Word documents. For example, to format and present the date that the work item (e.g. matter) was created.

  1. Return to the HTML editor and click where you want a date Tag to appear.
  2. In the Data Composer, navigate to Context -> Created Date -> UTC
  3. This brings us to the Value level. Don’t click on the + symbol next to Value, instead select the right arrow to drill down another level to access the formatter:
  4. Enter a format that the Created Date will be presented in. Note the icon, click on this to show the various date formats available.
  5. Enter a format. E.g. dd mmmm yyyy and click Resolve to apply the formatting.
  6. Click the + symbol to add the new Tag to the email body.
  7. Save and test your changes.

Conditional Sections

Conditional Sections can be used to intelligently display or hide blocks of text and tags, depending on whether or not a Tag has a certain value. For example, to display one of two blocks of text and Tags depending on whether the matter was created before or after a certain date.

  1. Open the HTML Email editor.
  2. Open your test email.

We need to begin by obtaining the name of the Tag we wish to test, in this case, the date that the matter was created.

  1. Open the Data Composer.
  2. Navigate to the Context Work Item -> Created Date -> UTC.
  3. Click on the Value label. The name of the Tag will appear underneath:
  4. Click on the clipboard icon to the right of the Tag name to copy it. We now have our Tag.
  5. Cancel out of the Data Composer.
  6. Place the cursor where we wish to add a new section of text and Tags.
  7. Now, open the Expression Editor that will allow us to create a test, by clicking the Conditional Section icon at the top right of the toolbar. Note the icon to view the range of Operators and Functions available, complete with examples.
  8. Close this form and place the cursor at the top of the editor.
  9. Paste in the Tag name you copied before.

We’ll now add an Operator. We will test that the matter created date is less than a date of our choice.

  1. So, add the following text (namely, a recent date) < ’01 Jun 2021’
    The test should now look like this:

    Lets check that the code is correct. Click on the Validate button at the top right of the form:
    We’re looking for this message:  
    If the code is wrong, the editor will try and identify where:
  2. If all is OK, click Confirm.

A new section has now been added to the email body:

Section Properties

Handy Tips:

  • Note the test displayed in blue at the top right.
  • To select an entire section, click on the light blue space surrounding the text. The section will now be highlighted in blue:
  • With the left mouse button depressed, the section can now be moved around the email body. If required, it can be deleted using the keyboard delete button.
  • Note that sections cannot be cut / copied or pasted.
  • Note the arrows at the top and bottom of a section. Clicking on these will add new blank lines above or below a section.

Clicking on the cog icon will re-open the Expression Editor and allow you to edit the test for the Conditional Section.

  1. Click inside the section so that it is highlighted in yellow. Add some standard text that you wish to be displayed if the test is true:
  2. Save and test.
    If the test was true, we should now see your text in the email:

    If the text was false, your new text will not be displayed.
  3. Return to the HTML email editor.

Lets create a new section, this time testing whether the matter was created after a specific date.

  1. The quickest method is to copy the text from the other section. So, select the existing section so it highlights in blue, then click on the cog icon to open the editor. Copy the test. Close the editor.
  2. Now, place your mouse directly below the other section and click on the icon top open the editor.
  3. Paste the text in. Amend the test so the operator changes to greater than:

Validate and Confirm.

There should now be two sections:

Add relevant text to the new section.

Save and test the changes.

Now, try moving between matters with different creation dates and generating the email – note how one section is hidden and the other displayed.

Note that Tags can be added into the section as well as text. To do this, open the HTML email editor and click inside a section where you want the Tag to be presented.

Now, click on the Data Composer icon and select a Tag. E.g. Matter Jurisdiction. Click on the + symbol to add it into the section.

The section will now look something like this:

Save and test your changes.

HTML Content Blocks

As the name suggests, these are individual blocks similar in nature to the email sources described here in that they contain a variety of tags, text, tables, images, conditional sections and so on. For example, these could be standard paragraphs of text, such as Funding Terms, which may vary over time and which can be updated centrally and the latest version inserted into emails as and when required.

See the separate section on how to create and maintain HTML Content Blocks.

To insert a Content Block:

  1. Place your cursor in the email source where you wish to insert the Content Block and select this option from the toolbar:
  2. A list of available Content Blocks is presented:
  3. Check the entry you require and select Confirm.
    (Alternatively, note that the Content Block blade can be presented, allowing you to amend the contents. To do this, click on the entry itself.)

    The email source should now look something like this:
  4. Save and test the changes.

Note that Content Blocks can be inserted inside Conditional Sections – simply create a Conditional Section then click inside the section before selecting the Content Block option. Alternatively, simply drag/drop an existing Content Block into a Conditional Section.

Repeating Sections

If you wish to present a list within the email, rather than just one piece of information (such as a date or a property address) then a special “Repeating” section is required. This section is ideal for displaying multiple Participants on a matter that have the same Role, such as a Purchaser, Witness, Defendant or Tenant.

For our example, pick a Participant type that tends to be a person rather than a company. Let's present their name and date of birth.

  1. Open the HTML Email editor.
  2. Open your test email.
  3. Add some text like “Here is a list of all the Tenants on this matter:”.
  4. Place your cursor where you want the list to be presented.
  5. Click on the Repeater Section icon at the top right of the toolbar.
  6. Click on the icon to load the Data Composer.
  7. Select Context.
  8. We need to select which list we want to present. 
  9. Select the Participant Roles.
  10. Click on the green plus symbol on the Role you wish to present e.g. Tenant.
    A new section is created:

Let's add some Tags to bring the contents of our list back. We’ll start with the name of the each Participant.

  1. Click inside the Section and click on the Tag icon in the toolbar.
  2. The Data Composer appears but note how the Tags presented relate only to the Participants list – all other Tags are hidden:
  3. We’re going to present the Participants details so click on ODS, then click on the green plus symbol over the Name Tag. The Tag will be inserted into the section as follows:
  4. Click on the icon to load the Data Composer. Click on S, then Person then click on the arrow to the right of the Date of Birth Tag.

The format box will appear. Enter the date format you wish to present the date in. For example:

  1. Save and test your changes.

Finally, lets add some automatic numbering to our list.

  1. Place the cursor to the far left of the ods.name Tag in your section and click on the “Numbered List” icon. 

    It should look like this:
  2. Save and test your changes – note how the numbering is automatically increased.

Repeating Tables

Note that the repeating sections function can be used in conjunction with tables to produce a table with 1 row per item of information returned.

To reproduce the exercise above, but this time place the results inside a table:

  1. Place your cursor where you wish the table to be created.
  2. Click on the Insert Table icon:
  3. Select the size of the table. For Training purposes, select 1 row by 2 cells wide. Hover over the table to see the options:
  4. Select the Row icon and tick on the option for Header Row.
  5. Add a heading for each cell. E.g. Name in the first cell, then Date of Birth in the second.
  6. Now, tab through the first row to automatically create a new row. It should look like this:
  7. To turn the table into a repeatable row table, click anywhere on the table and select the option:
  8. As above, select the element from the Tag Browser that you wish to present as a list. E.g. Participant Role of Tenant.
  9. The table can now repeat one row per Participant.
  10. To add Tags into the cells to show specific information about each Participant, click inside the left hand cell.
  11. Click on the Data Composer – as above, note that the Tags available are restricted. Select the Name Tag from the ODS section.
  12. Now, repeat for the right-hand cell – this time, select the Date of Birth.

It should look like this:

  1. Save and test your changes.

Variations

The variations function allows different email bodies to be used within the same email template. It uses the Business Rule function to determine which body to present to the user. See Business Rules for more details.

An example of email variation would be, say, in a Personal Injury claim, where all the properties of the email are identical, regardless of the type of claim (Recipients, Participants, etc), but the email body itself may require slightly different content.

So, for a Road Traffic Accident, ShareDo would present body A, but for another type of claim, it would present body B.

To create a new email variation.

  1. Open the HTML Email, then open the Pack Contents navigation bar.
  2. At the foot of the Source panel, note the following section

    … and the icon highlighted in red. Click on this to create a new Source panel.

The blade should now look like this:

Note:

  • The Source panels are numbered 1 and 2.
  • Source panels can be removed using the red trashcan icon.
  • Each Source panel has its own Business Rules test. These determine whether the email body will be presented or not.
  • The second Source can be created / edited by clicking on the icon to open the HTML Editor.

Business Rules

The first source that meets the criteria determined by the Business Rules will be presented.

Click on the Business Rule Select button to view a list of rules:

You can view, maintain, and create new rules here.

Email Versions

Previous versions of the email source can be reviewed and, where required, restored back and re-used.

Click on the Versions icon at the foot of the Source section on the Configure Pack blade to view a history of the email template.

Each saved change is shown, together with a Version number and details of the date and user:

Click on the three dots to the right of each entry to view the options:

  • View – displays the contents of the email source as they were at that selected date/time.
  • Restore – saves the current version of the source then creates a new, current, version using the selected source. Press Confirm and Save to confirm the changes and update the History.

Using Tags in Template Properties

Provided a Data Context has been selected and the email blade saved, Data Composer Tags will be made available for use in the properties fields in the email template.

For example:

Select the Pack Contents nav bar. Click inside the Output Title field

A Data Composer Tag becomes visible:

Accordingly, when the email is generated, the Tag will be replaced with data.

See also the Output File Name and Email Subject on the same blade.

Plus Output Path on the Output & Delivery nav bar.