Expressions in Expressions

Complete reference of built-in expressions in the Expressions of the TIVITY platform.

{DateTime.Now}

Returns the current date and time.

Syntax

{DateTime.Now}

{DateTime.Now.Date}

Returns the current date.

Syntax

{DateTime.Now.Date}

{DateTime.Now.Add(<Parameters>)}

Returns the time calculated based on the current time (the span to be added is passed as a parameter(s)). You can add either years or days or hours or minutes. If the value is negative the resulting time will be in the past.

Syntax

{DateTime.Now.Add(YEARS, 1)}
{DateTime.Now.Add(DAYS, -7)}
{DateTime.Now.Add(HOURS, 12)}

Parameters

  • YEARS,<years> or

  • DAYS,<days> or

  • HOURS,<hours> or

  • MINUTES,<minutes>

{NewGuid()}

Returns a new generated value of the universally unique identifier.

Syntax

{NewGuid()}

{CurrentUser.<Property>}

Returns the specified property of the current user.

The value of a DefaultTemplate, an Expression or a Condition Value can be a mix of a text and one or more expressions enclosed in the curly brackets. The resulting value is concatenated after evaluation of the expressions. For example if the expression for the virtual field FullName is "{FirstName} {LastName}", the FirstName="John" and the LastName="Brown", the value of the field FullName is "John Brown".

Syntax

{CurrentUser.Id}
{CurrentUser.FirstName}
{CurrentUser.Nickname}

Properties

Possible properties:

  • Id

  • LanguageId

  • LoginName

  • FirstName

  • LastName

  • Nickname

{CurrentUser.Groups}

Returns all group IDs separated by ',' of the current user and office. If no office is provided, no group IDs are returned.

Syntax

{CurrentUser.Groups}

{CurrentUser.Roles}

Returns all role IDs separated by ',' of the current user, office and app. If no app is provided, all role IDs of all apps of the office for the current user are returned. If no office and app is provided, no role IDs are returned.

Syntax

 {CurrentUser.Roles}

{CurrentOffice.Id}

Returns the id of the current workspace.

Syntax

{CurrentOffice.Id}

{CurrentApplication.Id}

Returns the id of the current application.

Syntax

{CurrentApplication.Id}

{ParentObject.<Property>}

Returns the specified field of the parent object (relevant if the object is created as a link of some other object - its parent).

Syntax

{ParentObject.<Property>}

{LinkPath["<ClassName>"].<FieldName>}

Returns the value of the specified field of the parent object with the specified class name (relevant for indirectly linked objects).

Syntax

{LinkPath["<ClassName>"].<FieldName>}

{<FieldName>}

Returns the value of the virtual field based on the value of another field.

Syntax

{<FieldName>}

{Convert(<Parameters>)}

Returns the value of the virtual field depending on the value of another field according some rules defined as parameters.

FieldName - the name of the field the virtual field depends on (e.g. FieldA); Value1, Value2... - possible values of the the FieldA; Result1, Result2 - corresponding return values of the virtual field. For example the expression returns Result1 if the FieldA equals to Value1.

Syntax

{Convert(<Parameters>)}

Parameters

<FieldName>,<Value1>:<Result1>[,<Value2>:<Result2>]

{IsCheckedOut()}

Returns "True" if the document of the current object is checked out, otherwise "False".

Syntax

{IsCheckedOut()}

{CheckedOutBy()}

Returns the name of the user who has checked out the document of the current object.

Syntax

{CheckedOutBy()}

{IsFinalized()}

Returns "True" if the document of the current object is finalized, otherwise "False".

Syntax

{IsFinalized()}

Last updated