Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Page properties
hiddentrue
Status
Tech review

Status
titletodo

Style guide

Status
titletodo

Status
titletodo
Status
colourYellow
titleReady for review
Status
colourGreen
titledone
Status
colourRed
titleflagged

Page properties
hiddentrue
Short description

Returns a text 

Output Statussubtletruetitletext UI Text Box
sizemedium
typeinfo

This function returns a text with a comma-separated list of decimal representation of the numeric values in lconverts the decimal representation of a number (or timestamp) into plain text


UI Text Box
typetip

This is one of the most commonly used functions in JWT.

Whenever any type of list is returned by a field code or parser function (e.g. subtasks()) and you are using the advanced text parsing mode, the toString() function converts the output to a readable format.

This is especially helpful if you want to test your expression.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(number list l) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString([1, 2, 3, 4.0]141592)


This example returns the following text:

"1, 2, 3, 43.141592"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lnumber

Status
subtletrue
titlenumber list

Any given number listor numerical field code.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext




UI Text Box
sizemedium
typeinfo

This function returns a text with a comma-separated list of issue keysVariant where you can additionally define the number of decimal places.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(issue list lnumber, decimalPlaces) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString(subtasks())3.141592, 2)


This example returns "CRM-5, CRM-6 ", being CRM-5 and CRM-6 the keys of current issue's sub-tasks.the text:

"3.14"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lnumber

Status
subtletrue
titleissue listnumber

Any given number.
decimalPlaces

Status
subtletrue
titlenumber

Any positive numberA given issue list.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext



Image AddedNumber list

UI Text Box
sizemedium
typeinfo

This function returns a text with a list of issue keys separated by parameter separatorconverts any number list into plain text.

A comma-separated text with the decimal representation of each numeric value will be returned.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(issue list l, string separatornumberList) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
 toString(subtasks()[1, "2, " 3, 4.0])


This example returns "CRM-5, CRM-6 ", being CRM-5 and CRM-6 the keys of current issue's sub-tasks.the text:

"1, 2, 3, 4"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lnumberList

Status
subtletrue
titleissue number list

A Any given issue list.separator

Status
subtletrue
titledata type

Parameter descriptionnumber list.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext




UI Text Box
sizemedium
typeinfo

This function returns a text with a comma-separated list of decimal representations of the numeric values in l, with the number of characters in the decimal part specified by parameter decimalsVariant where you can additionally define the number of decimal places.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(number list lnumberList, number decimalsdecimalPlaces) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString([1.123, 2.452, 3.64612], 2)


This example returns the following text:

"1.12, 2.45, 3.65"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lnumberList

Status
subtletrue
title number list

A Any given number list.
decimalsdecimalPlaces

Status
subtletrue
titledata typenumber

Any positive numberParameter description.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext




UI Text Box
sizemedium
typeinfo

This function returns a text with a list of decimal representations of the numeric values in l, with the number of characters in the decimal part specified by parameter decimals and separated by parameter Variant where you can additionally define a specific separator.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(number list lnumberList, number decimalsdecimalPlaces, text separator) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString([1.123, 2.452, 3.64612], 2, " : ")


This example returns the following text:

"1.12 : 2.45 : 3.65"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lnumberList

Status
subtletrue
titlenumber list

A Any given number list.
decimalsdecimalPlaces

Status
subtletrue
titlenumber

Parameter descriptionAny positive number.
separator

Status
subtletrue
titletext

Parameter descriptionAny separator character.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext



Image AddedText list

UI Text Box
sizemedium
typeinfo

This function converts any text list into plain text.

A comma-separated text with each value will be returned.This function returns a text with the decimal representation of the numeric value in n. Numeric value of a Date_Time field is number of milliseconds elapsed since January 1, 1970, 00:00:00 GMT.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(number ntextList) #Output: Text


UI Expand
titleExamples


following text: "3.141592"
Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString(3.141592["Hello", " ", "world", "!"])


This example returns the text:

"Hello, , world, !"


Code Block
languagebash
linenumberstrue
toString(fieldValue(%{issue.reporter}, subtasks()))


This example returns the

user names of all sub-task reporters, e.g.:

"b.smith, a.grant"

To achieve this the following functions are used:



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
ntextList

Status
subtletrue
titlenumbertext list

Any given numbertext list.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext




UI Text Box
sizemedium
typeinfo

This function returns a text with the decimal representation of the numeric value in n limiting the fractional part to the number of digits in parameter decimalsVariant where you can additionally define a specific separator.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(number ntextList, number decimalsseparator) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString(3.141592, 2["blue", "red", "green"], "; ")


This example returns the following text:

"blue; red; green"3.14"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
ntextList

Status
subtletrue
titlenumbertext list

Any given numbertext list.
decimalsseparator

Status
subtletrue
titlenumbertext

Any given number smaller or equal than nseparator character.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext



Image AddedIssue list

UI Text Box
sizemedium
typeinfo

This function returns a text with a commaConverts an issue list into a comma-separated list of text values in ltext containing issue keys.


Code Block
languagebash
titleSyntax
linenumberstrue
 toString(string list lissueList) #Output: Text


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
toString(["Hello", " ", "world", "!"]subtasks())


This example returns the following text: "Hello, , world, !"might return:

 "CRM-5, CRM-6 "

To achieve this the following functions are used:



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lissueList

Status
subtletrue
titletext issue list

Any given text issue list. Usually this value is retrieved from a function (e.g. linkedIssues() or subtasks()).



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext




UI Text Box
sizemedium
typeinfo

This function returns a text from the list of text values in l separated by parameter Variant where you can additionally define a specific separator.


Code Block
languagebash
titleSyntax
linenumberstrue
toString(text list lissueList, text separator) #Output: Text


UI Expand
titleExamples


returns the following text: " blue; red; green 
Parser expressionDescription


Code Block
languagebash
linenumberstrue
 toString(["blue"(subtasks(), "red", "green"] ")


This example might return: 

"CRM-5 CRM-6 CRM-7"


Code Block
languagebash
linenumberstrue
 toString(subtasks(), ";
")


This example

might return: 

"CRM-5;CRM-6;CRM-7

"



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
lissueList

Status
subtletrue
titletext issue list

Any given text list.issue list. Usually this value is retrieved from a function (e.g. linkedIssues() or subtasks()).
separatorseperator

Status
subtletrue
titletext

Parameter descriptionAny separator character.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext



Image AddedUse cases and examples

Page properties report
firstcolumnUse case
headingsJWT feature, Workflow function, Field type, Automated action, Parser functions
cqllabel = "parser_func_tostring" and space = currentSpace()


Page properties
hiddentrue
id1


Parser function cloudtoString()
Map(tick)
Notes




Page properties
hiddentrue



Status
Tech review

Status
colourGreen
titledone

Style guide

Status
colourGreen
titledone

Status
titletodo
Status
colourYellow
titleReady for review
Status
colourGreen
titledone
Status
colourRed
titleflagged



Page properties
hiddentrue


Short description

Converts numbers and lists into plain text.

Output

Status
subtletrue
titletext

Available since
Label

Status
colourRed
titlestaff pick