Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Child pages (Children Display)toc
minLevel1
maxLevel6
outlinefalse
typelist
printablefalse

I. Common Placeholders

Placeholders are used to display dynamic data in the document. According to the document type, we can use placeholders in these fields:

...

All the information of the policyholder will get through the placeholder @Model.Policyholder.{info}

You can define the DateTime format as .ToString("dd.MM.yyyy"). For example, @Model.InsuranceContext.ShortCreationDate.Value?.ToString("dd.MM.yyyy")

Seamless information

Placeholder in document

ID

@Model.PolicyHolder.Id

NIN

@Model.PolicyHolder.NIN

Reference

@Model.PolicyHolder.Reference

Name

@Model.PolicyHolder.Name

Date Of Birth

@Model.PolicyHolder?.DateOfBirth

Postal Address

@Model.PolicyHolder.Addresses.VisitingAddress?.PostalAddress

Invoice Address

@Model.PolicyHolder.Addresses.VisitingAddress?.InvoiceAddress

City

@Model.PolicyHolder?.City

Phone Number

@Model.PolicyHolder?.PhoneNumber

Email

@Model.PolicyHolder?.Email

Organization Context

@Model.PolicyHolder.OrganizationContext

...

Seamless information

Placeholder in document

Id

@Model.SalesChannel.Id

Name

@Model.SalesChannel.Name

h. Identify policy type

This placeholder is used for identifying policy type, especially when you need to show/ hide information based on the policy type.

The example below if showing the text on policies only, and hides when the document is a quote document

@if (Model.DocumentContext.DocumentUsage == "NewBusiness" || Model.DocumentContext.DocumentUsage == "MTA" || Model.DocumentContext.DocumentUsage == "Renewal")
{

<h2 class="text-uppercase">FORSIKRINGSTILBUD</h2>

}

Seamless information

Placeholder in document

Policy type

Model.DocumentContext.DocumentUsage

III. Tips when updating a document template

  1. Always close your tags when you open it

    1. For example, when you open the tag <h1> then you need to closed it as </h1>

  2. No space between @ and the placeholder

    1. For example, Seamless will show an error when you define your document template as @ Model

  3. Use the Document Templates menu in Insurance → Document Templates

  4. When you are not sure whether your data is always available or optional data (e.g. Optional cover can be chosen or not), then you need to mark ? before your attribute as the example Model.PolicyHolder?.Name

  5. To show information based on some conditions, you can use @If as the example below

    1. @If (Model.DocumentContext.DocumentUsage == "NewBusiness") // this case the @ is defined at the If and won't be defined in the placeholder

      1. { <h1> This is a new business policy </h1> }

    2. Else //you won't need to write @ before else

      1. { <h1> This is not a new business policy </h1> }

  6. Contact Contemi team to support you in building a perfect document (wink)