Thank you for your feedback.
Form temporarily unavailable. Please try again or contact docfeedback@servicenow.com to submit your comments.
Versions
  • London
  • Kingston
  • Jakarta
  • Istanbul
  • Helsinki
  • Geneva
  • Store
Close

HR Document Templates

HR Document Templates

HR Document Templates are used to create and modify reuseable HR documents.

Use HR document templates for documents that can be customized with dates, names, and signatures like:
  • Employee verification letters
  • Non-disclosure agreements
  • Offer letters
  • Educational reimbursement agreements
You can personalize HR document templates by mapping fields or using variables from the available tables to place data in fields. You can also capture multiple e-signatures in a document that automatically generates once all signatures are captured.
There are two types of HR document templates, both create PDF files, but are created and maintained differently:
  • Document templates (HTML)
  • PDF document templates

Document templates (HTML)

Document templates are created within the HR application and use variables to pre-fill information from tables into the document. You create how the document looks by defining the header, footer, images, placement of footer, and the text within the template. The base system provides default document templates that you can use to model your documents:
  • Employee Verification Letter in Canada
  • Employee Verification Letter in USA
  • Offer Letter Template
  • Education Agreement

Before you begin generating documents, configure the templates with your company logo and text. Obtain the following items and information to create or configure the predefined HR document templates.

  • A page of your company letterhead.
  • Copies of your current company employment verification letter and offer letter templates, if available.
  • The logo image to use in your header. The header image can be a maximum of 50 px high. If your letterhead includes a logo and text, ensure that the logo image includes the text, because you can only configure the image (not text) in the header.
  • The logo image to use in your footer, if applicable. The logo image can be a maximum of 15 pixels high. You can configure both an image and text in the footer.
    Note: For best results, ensure that the image is optimized and a Scalable Vector Graphics (SVG) file.

PDF document templates

PDF document templates originate from Managed Documents and use field mapping to pre-fill information from tables into the document. Before you customize a document:
  • The document must be a fillable PDF. See the Adobe home page and search for fillable PDF to learn how to create fillable PDF documents https://www.adobe.com/.
  • The document must be uploaded and published.
The base system provides the default PDF document template as an example:
  • Non-Disclosure Agreement (Sample)

Generating documents

Both the Document template (HTML) and PDF document template generate PDF documents that can be reviewed or printed and can require multiple signatures.

A common use case for generating a document from an HR case is when an employee requests an employment verification letter. For information on generating a PDF from a document template (HTML), see Generate a PDF from a document template (HTML).

For information on generating a PDF document from an HR case, see Document Generation.

Document Types

Document types limit the choices for allowable documents based on HR service. For organizations with large amounts of documents, document types help categorize and make finding the correct document easier.

For example, you can have multiple employee verification letters depending on if the employee is full-time, part time, or contingent. HR criteria on an HR service determines which letter to send.

When an HR case is created for an HR service, it checks:
  • HR case template for the HR service
  • The document type for the HR case template
  • HR criteria
Verifying this information allows the case to narrow the search for the correct letter or auto-populate the exact letter required.
Setting up document types
To use this feature:
  • Add a document type to your document templates.
  • Add the document type to an HR case template.
    • From the HR template classic UI, you can add a specific PDF template, but cannot specify a document type. Adding a specific PDF template automates populating the HR case form, but eliminates flexibility when you have multiple documents.
  • Add the HR case template to an HR service.
  • Add HR criteria to the HR service.
    • Using HR criteria provides flexibility in choosing or auto-populating a document for an HR service.
How it works
When an HR case is created from an HR service:Flow of HR case when document is selected.
  • The HR case template looks for a document type to determine what Document template or PDF document template to a case. It tries to automatically place a document template on an HR case by:
    • Checking if there are documents associated with the document type.
    • If there is only one document associated with the document type and the HR criteria is empty, place that document on the HR case form.
    • If there is HR criteria on the document template, verify the Subject person on the HR case form matches the criteria. If yes, place the document template on the HR case form.
    • If there are multiple document templates for the document type, check for HR criteria. When a single document matches, populate the document template on the HR case form. When multiple documents match, do not populate, but list documents on the HR case form choice list.
    • When HR criteria is not available on any document templates, list documents on the HR case form choice list.
      Note: There is HR criteria on the HR service and HR document templates. On HR services, HR criteria narrows the allowable services for an employee. For example, you can provide 401 (k) services to US employees, but not to non-US employees. On HR document templates, HR criteria narrows what employees the document is for. For example, when you have employee verification letters for US employees and non-US employees, use HR criteria to determine the correct document.

Add or modify an HR document template (HTML)

Create HR document templates with your unique company logo and audience criteria. Document templates are created within the HR application and use variables to pre-fill information from tables to create reusable HR documents.

Before you begin

Role required: sn_hr_core.manager and sn_hr_le.admin

About this task

HR document templates customize HR documents to match the service and subject person.

The base system provides examples of employment verification letters, educational reimbursement agreements, and an offer letter.

Note: The example offer letter only appears when the Human Resources Scoped App: Lifecycle Events is activated. Refer to Configuring Enterprise Onboarding and Transitions.

Procedure

  1. Navigate to HR Administration > Document Templates.
  2. Click New or edit an existing document template. When you select New, HR Document Templates list appears.
    HR document templates choice list
  3. Select Document Template.
  4. Complete the form.
    OptionDescription
    Name Enter a name for your document template.
    Table Select the table associated with the type of letter. The table determines the available variables that can be used.
    Note: Only tables that you have access to appear.
    Document type Select the document type the template applies to.

    Click New from HR Document Type to create a document type.

    A document type is required when you want a list of documents to appear in the HR case form. HR criteria works with this field to narrow the list of documents you want available for an HR case.

    See Document Types.

    Note: When creating a document type, the Value auto-populates from the name you enter (all lower case and underscores).
    Header image Select to add a new image in the header. You can add your company logo using this feature.
    Note: Supported file types are: JPEG, JPEG2000, GIF, PNG, BMP, WMF, TIFF, and JBIG2.
    Header image position Select where you want the header image to appear.
    HR criteria Select the audience criteria for this document. For example, you can create a letter intended for only Canadian employees.
    Body Enter and format the text in the Body.

    To insert variables, place your cursor in the desired location and click the variable. Available variables are listed under Fields.

    Use the formatting tools in the Body to apply formatting options, such as bold, italic, underline, font styling.

    The body is a place holder for HTML text and tokenized variables. When the PDF is generated, the variables are resolved before sending it to the PDF Generator [com.snc.pdf_generator] plugin.

    Note: Currently, there is no support for style tags to align text left or right. Space indentation must be used. Jelly and CSS Styling are not supported.
    Select variables A list of variables that can be used in the body of the letter. Variables pull information from the selected table to customize the letter.
    Note: Only variables that you have access to appear.
    Footer image Select a footer image.
    Note: Supported file types are: JPEG, JPEG2000, GIF, PNG, BMP, WMF, TIFF, and JBIG2.
    Footer image position Select where you want the footer image to appear.
    Footer text Enter text. For example, you can add proprietary and confidential statements.
    Page size Select the page size from the choice list.
    Note: A4 is 8.3 x 11.7 inches or 210 x 297 millimeters.
  5. Place the cursor in the desired location in the body and use the Insert date or Insert signature buttons. You can use these multiple times using different types of dates or signatures based on the variables you choose.
  6. Click Save to save your document and remain on the HR Document Template form or click Submit to save and return to the HR Document Templates list.
  7. Review the look of the generated letter by impersonating an employee and submitting the associated catalog item. Impersonate the user assigned to work on the case to generate the letter within the HR case. Continue editing and testing the letter template until you are satisfied with the generated PDF.
    The TinyMCE editor provides rich text creation that the PDF generator does not support. Non-supported HTML elements are:
    • Vertical alignment.
    • Page breaks (alternative, use document.addNewPage().
    • Table-specific color (text color is supported).
    • Custom spacing between blocks of text or images.
    • Custom column width in HTML tables.
    • Custom column alignment in HTML tables.
    • Custom border styling in HTML tables.
    • CSS text manipulation ()including CSS based font tags).
    • Inline styling.
    • Background images.
    See Editing functions in the TinyMCE editor.

Generate a PDF from a document template (HTML)

You can generate a PDF document from an HR case using a UI action, such as an Employment Verification letter.

Before you begin

Role required: admin
  • Create a UI action on the table referenced in the Document Template.
  • Code the UI action to call the document generation methods to generate a PDF.
Create a UI action
You can use the wrapper method to generate a PDF by creating an instance of our helper class and calling the generate method.
//tableNmame: Name of the table that the document template is based on.
//tableId: Sys ID of th record in the table to use for generation.
//targetTableName: Name of the table to attache the generated PDF.
//targetTableId: Sys ID of the record in the target table where the PDF is attached.

new GeneralHRForm (tableName, tableId, targetTableName, targetTableId).gnerate();
Create an instance of the GeneralFormAPI class
//fileName: Name of the PDF file to be generated.
//targetTable: Name of the table to attach the PDF.
//targetTableSysID: Record to attach the PDF.
new GeneralFormAPI (fileName, targetTable, targetTableSysId);
Set the values saved in the Document Template class
//header: Header image for the PDF.
//footer: Footer image for the PDF.
//headerLocation: Location of the header. Right, left, or center aligned.
//footerLocation: Location of the footer. Right, left, or center aligned.
GeneralFormAPISetDocument(header, footer, headerLocation, footerLocation);
Call the CreatePDF method and pass in the body text defined in the document template
//body: Body text defined in the template.
GeneralFormAPI.createPDF(body);

Add or modify a PDF document template

Create custom HR PDF document templates with your unique user criteria. PDF document templates originate from Managed Documents and are either a fillable PDF with mapped fields or a standard PDF with an inline signature.

Before you begin

Role required: sn_hr_core.manager

With PDF document templates, you can take an existing document and reuse it with custom information from an HR case or any available table. For example, you can take a fillable PDF document from Managed Documents, and map fields to customize the document each time it is used.

The document must be a fillable PDF to map the fields to a table. See the Adobe home page and search for fillable PDF to learn how to create fillable PDF documents https://www.adobe.com/.

Note: Fillable PDFs presented to an employee does not save any data populated by the employee (except for signatures). Fillable PDFs are only used for mapping fields to a table.

Documents are uploaded and accessed from the Managed Documents application in the Documents [dms_document] table. Documents are required to be published as a document revision before it can be accessed.

The base system provides the Non-Disclosure Agreement document template as an example of a PDF document template.

Procedure

  1. Navigate to HR Administration > Document Templates.
  2. Click New or edit an existing document template. When you select New, the HR Document Templates list appears.
    HR document templates choice list
  3. Select PDF Document Template.
  4. Complete the form.
    OptionDescription
    Name Enter a name that represents the document.
    Table Select the table associated with the type of letter. The table determines the available fields that can be mapped.
    Note: Only tables that you have access to appear.
    Document type Select the document type the template applies to.

    Click New from HR Document Type to create a document type.

    A document type is required when you want a list of documents to appear in the HR case form. HR criteria works with this field to narrow the list of documents you want available for an HR case.

    See Document Types.

    Note: When creating a document type, the Value auto-populates from the name you enter (all lower case and underscores).
    Document revision Select the document and revision the PDF document template is based on.

    Documents listed originate from Managed Documents.

    Note: User group and document owner determine what revisions are available to view or select.
    HR criteria Select the audience criteria for this document. For example, you can create a letter intended for only Canadian employees.

    The HR criteria narrows the number of users for the template.

    Mark Signatures Click to map where signatures are required in the document.
    PDF Preview Appears after saving or selecting an existing PDF template.
    Click to view a preview of the template.
    Note: Using style tags for text alignment is not supported. Use spaces to align your text.
  5. Click Save to save your document and the Parse PDF link appears under the Related Links section. This link only appears when there are fields that can be mapped.
    When you click Save and there are fields on the template that can be mapped, the Parse PDF link appears under Related Links. The fillable PDF determines which fields can be mapped and the table selected determines what information you can have populated in those fields.
  6. Click Parse PDF.
    The PDF Template Mappings list appears.
  7. The PDF Template Mappings section and fields display.

Create or modify a PDF template mapping

With PDF template mapping you can pre-fill information from specified tables into a reuseable HR document configured in a PDF document template.

Before you begin

Role required: sn_hr.core_admin

PDF template mappings are derived from the table associated with the PDF document template. PDF template mapping is accessed from a PDF document template that contains fields that can be mapped. Refer to Add or modify a PDF document template.

The PDF Template Mappings section appears when a new fillable PDF document has been uploaded from Managed Documents and the Parse PDF link is selected.
Note: The document must be a fillable PDF to map the fields to a table. See the Adobe home page and search for fillable PDF to learn how to create fillable PDF documents https://www.adobe.com/.

Procedure

  1. Click New or an existing PDF template mapping to edit. The PDF Template Mapping form appears.
  2. Complete the form.
    OptionDescription
    Field name Enter a name that represents the field mapping.
    HR PDF template The name of the PDF template associated with the field mapping.
    Document field type Select the type of field you are mapping. The choices are:
    • Signature
    • Text Field
    • Checkbox
    • Combo
    • Radio
    Preview value Enter a field mapping value for preview.
    Note: Use this field to test a field value without going through the process of mapping fields or creating a case to test your mappings. What you enter here appears in your document.
    Advanced script Use to configure script fields for complex mapping of a field.

    For example, to map a Social Security Number from the HR Profile [sn_hr_core_profile] table to a document and format it correctly, a script is used.

    Mapping table The table the mapped fields come from.
    Mapping field The field that maps information into your document.
    Use signing date Check when the signing date should be captured with the signature when a user signs the document.
    Page number The page number of the PDF document the mapped field should insert information. For example, enter 2 when the mapped field appears on page 2 of the PDF document.
    Active Check to activate the field mapping.
  3. Click Save to save your field mapping and remain on the PDF template mapping form. Or, click Submit to save your field mapping and return to the HR Document Templates list.

Signature Pad

Signature pad is a feature that any application can use. It captures an electronic signature that can be associated with a document or a task.

The HR Service Delivery application uses signature pad with onboarding documents like offer letters, background check approval, company policy acknowledgements, and more.

The Human Resources Scoped App: Core [com.sn_hr_core] plugin activates the Signature Pad [com.snc.signaturepad] plugin. The Signature Image [signature_image] table installs with this plugin.

Ensure Yes is checked in the com.snc.signaturepad.retrieveSignature field on HR properties. See HR Properties.

Use
You can send your employees documents that require a user verification such as a digital signature or by typing their name.
When signature pad is associated with a document or a task, it captures the drawn signature as an image and stores it in the Signature Image [signature_image] table.
Note: Typing a signature provides acknowledgement, but does not capture an image that is stored.
For HR document templates, use the Insert Signature button to insert a variable that prompts a user to sign the document. For HR PDF document templates, use the Employee Signature field name and PDF Template Mappings to prompt a user to sign the document. See HR Document Templates.
Note: Check the generate document UI action condition to ensure this feature works correctly.
Examples
The HR Delivery System uses PDF documents for various scenarios. An example of the code used to call a UI page or dialog box for the signature pad:PDF code snippet example that calls UI page.
An example of the code used in a document after a signature has been accepted and a final PDF document is created:Example of code when signature is accepted.

Activate the Signature Pad plugin

To activate signature pad in your application, activate the Signature Pad plugin [com.snc.signaturepad]. The Signature Image [signature_image] table installs with this plugin.

Before you begin

Role required: admin

About this task

To purchase a subscription, contact your ServiceNow account manager. After purchasing the subscription, activate the plugin within the production instance.

You can evaluate the feature on a sub-production instance without charge by requesting it from the HI Customer Service System.

Procedure

  1. Navigate to System Definition > Plugins.
  2. Find and click the plugin name.
  3. On the System Plugin form, review the plugin details and then click the Activate/Upgrade related link.

    If the plugin depends on other plugins, these plugins are listed along with their activation status.

    If the plugin has optional features that depend on other plugins, those plugins are listed under Some files will not be loaded because these plugins are inactive. The optional features are not installed until the listed plugins are installed (before or after the installation of the current plugin).

  4. (Optional) If available, select the Load demo data check box.

    Some plugins include demo data—Sample records that are designed to illustrate plugin features for common use cases. Loading demo data is a good practice when you first activate the plugin on a development or test instance.

    You can also load demo data after the plugin is activated by clicking the Load Demo Data Only related link on the System Plugin form.

  5. Click Activate.

Test Signature Pad

After you have activated the Signature Pad plugin, you can try it.

  1. Navigate to System UI > UI Pages > accept_signature.
  2. Scroll down and click Try It.
  3. In the Print your name field, type your name.
  4. Click Accept.
    A record is inserted in the Signature Image [signature_image] table.
  5. To draw your signature, select the Draw it tab.
  6. Use your mouse to draw your signature.
  7. Click Accept.
    A record is inserted in the Signature Image [signature_image] table.