Skip to end of metadata
Go to start of metadata

Creating Templates

Templates are used to display a form on a phone or tablet and to process messages.

Templates are composed of several elements - some are for displaying the form and others are for encapsulating data. To create a Template you login to the AMS web application and go to the templates section. Click the "Create New Template" button to get started.

Summary Items

The summary section allows you to setup the base information required for a Template.

Item

Description

Name

This is the display name for the Template and will be shown on the phone in the "New Message" menu and in message lists.

Description

This is not currently shown on the phone but may in future versions. It should provide a fuller description of the Template.

Root

Root Templates can be use to create new messages on the phone. Non root messages can be used for display only or for sub templates when creating a list card.

Summary Template

This is a string which can be used to create a custom summary line for messages on the phone. It can include data from the message by placing the external label for that item in the string inside curly braces eg

Timesheet for {employeeCode}

It can only contain data items from the root template i.e. data cannot be included from sub templates.

External Label

This is label that will be used when exporting messages to external systems e.g. the name of the XML tag.

Collection External Label

This is label that will be used when exporting a collection of messages to external systems e.g. the name containing the XML tag.

External Labels

External labels & collection external labels need to be valid XML entity names. In principal this means using alphanumeric characters and no whitespace. To separate words you can use an underscore or camel case eg my_external_label or myExternalLabel. Don't worry if you enter an invalid label as you will receive a validation error when trying to save.

Cards

Cards correspond to screens on the phone. They allow you to spread form elements across screens and collect relevant sections together. There are two types of cards, Form Cards and List Cards.

You need to select one card to be the root card for a template. The root card becomes the first screen that is displayed on the phone when creating or viewing a message.

Form Cards

Form Cards can contain fields and commands. They can contain any number of field or command items but it is best to keep the number as low as possible to improve usability on the phone. You can have multiple cards so it can be good to spread many form items over more than one card. You can link between these cards using a "Link Command".

List Cards

List Cards can contain multiple entries of a sub template. They can be used as root cards or contained within a template and linked to from a form card. If you were creating a roster type form you could use a list view for each of the roster entries rather than sending multiple messages. To use a List Card you need to select a non root Template for the type of entries that will be displayed. You will also need to specify an external label as List Cards are considered data items that contain a collection of entries.

Fields

Fields are used on Form Cards to display form items. You can set a field to be required in which case a message cannot be sent without that information. All fields require an external label which is used when exporting messages. The follow is a list of the types of fields available.

Field

Description

Text Item

A text field for entering a single line of text. It can have a max size and type. The type restricts the input allowed on the phone.

Text Box Item

A text field for entering multiple lines of text. It can have a max size and type. The type restricts the input allowed on the phone. Text Boxes are shown on a separate screen to that of the enclosing Form Card. A "Text Box Command" is required to link the form card to the text box.

String Item

A non editable string. Can be used for providing instructions or extra information.

Date Item

A field for entering dates and times. The type can restrict the field to date only, time only or date and time. This field will most likely display differently depending on the phone used.

Gauge

Allows you to select from a number range.

Choice Group

Allows you to select options from a list of choices. The list can be a popup menu, an exclusive menu (only 1 selection) or a multiple selection type. Specify the choices you want as a string with commas separating the choices and no spaces e.g "Low,Medium,High".

Ordering Fields

Fields can be ordered by using the green arrows to move them up or down.

Commands

Commands are used on Cards to provide menu choices for the screen on the phone. The following is a list of types of commands available.

Command

Description

Link

Link commands connect two cards together.

Text Box Command

A text box command links a form card to a text box contained in that card.

Call Command

Uses a meta data entry to place a phone call. This can be useful as a short cut to call a phone number without requiring the user to enter a phone number e.g. a call command could be set to automatically call the client for a particular job.

Set Value Command

This command can be used to set a meta data entry to a predetermined value. This could be used as an "Accept" or "Reject" command.

Ordering Commands

Commands can be ordered by using the green arrows to move them up or down.

Routes

Routes allow you to convert messages into documents or push received messages automatically to another server. Currently AMS only supports Documents as email attachments and HTTP/HTTPS posts to external web servers. For more information see the Routes section of the Developer Guide.

Labels: