Newer Version Available

This content describes an older version of this product. View Latest

TimeSheetTemplate

Represents a template for creating time sheets in Field Service Lightning.This type extends the Metadata metadata type and inherits its fullName field.

File Suffix and Directory Location

TimeSheetTemplate components have the suffix timeSheetTemplate and are stored in the timeSheetTemplates folder.

Version

TimeSheetTemplate components are available in API version 46.0 and later.

Special Access Rules

Field Service Lightning must be enabled. Users must have the Customize Application and Time Sheet Template permissions.

Fields

Field Name Field Type Description
active boolean Required. Indicates whether the time sheet template is active (true) or not (false).
description string The time sheet template's description.
frequency TimeSheetFrequency (enumeration of type string) Required. Defines the frequency of the time sheet creation period. One of the following values:
  • Daily
  • Weekly
  • EveryTwoWeeks
  • TwiceAMonth
  • Monthly
masterLabel string Required. The name of the time sheet template.
startDate date Required. The date when the time sheet takes effect.
timeSheetTemplateAssignments TimeSheetTemplateAssignment A list of profiles that the template is assigned to.
workWeekEndDay DaysOfWeek (enumeration of type string) Required. The end day of the template's work week. One of the following values:
  • Monday
  • Tuesday
  • Wednesday
  • Thursday
  • Friday
  • Saturday
  • Sunday
workWeekStartDay DaysOfWeek (enumeration of type string) Required. The start day of the template's work week. One of the following values:
  • Monday
  • Tuesday
  • Wednesday
  • Thursday
  • Friday
  • Saturday
  • Sunday

TimeSheetTemplateAssignment

Returns a quick action that’s associated with an EmbeddedServiceLiveAgent setup. The quick action includes the pre-chat form fields that the embedded chat window displays and shows the order in which the fields are displayed.

Field Name Field Type Description
assignedTo string The IDs of the user profiles that a time sheet template is assigned to.

Declarative Metadata Sample Definition

The following is an example of a TimeSheetTemplate file.

The following is an example package.xml that references the previous definition.

Wildcard Support in the Manifest File

This metadata type supports the wildcard character * (asterisk) in the package.xml manifest file. For information about using the manifest file, see Deploying and Retrieving Metadata with the Zip File.