Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
UI Text Box
sizemedium
typeinfo

This function returns the display name for a given Atlassian account ID. In case, the given text is not a valid Atlassian account ID, an empty text is returned.

Code Block
languagebash
titleSyntax
linenumberstrue
userDisplayName(accountId) #Output: Text
UI Expand
titleExamples
Parser expressionDescription
Code Block
languagebash
linenumberstrue
%{userDisplayName(%{system.currentUser})}
This example returns the display name of the current user, e.g.:
Bob Smith
UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
accountId

Status
subtletrue
titletext

Text containing a valid Atlassian account IDId
UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext


UI Text Box
sizemedium
typeinfo

Variant for multiple users.

Code Block
languagebash
titleSyntax
linenumberstrue
userDisplayName(accountIdList) #Output: Text list
UI Expand
titleExamples
Parser expressionDescription
Code Block
languagebash
linenumberstrue
%{toString(userDisplayName(toStringList(%{issue.watcher})))}
This example returns the display names of all watchers.

To achieve this, the following functions are function is used:

toString()

Code Block
languagebash
linenumberstrue
%{toString(userDisplayName([""557058:145e0983-5707-439c-80e4-1160dd57f1141160dd57f142"", %{issue.reporter}]))}

This example returns the display names of all two users, e.g.:

Bob Smith, Dave Mary Jones

To achieve this, the following functions are used:

UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
accountIdList

Status
subtletrue
titletext list

Any valid text list containing Atlassian account IDsIds
UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext list

UI Text Box
typetip

If you want to return the Atlassian account ID Id instead of a display name, check out: userAccountId()


Use cases and examples

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

Notes
Page properties
Map(question)
hiddentrue
id1
Parser function cloud

Workaround

Code Block
languagebash
issue.reporter.displayName
//and
issue.watchers.map(u=>u.displayName)

Only possible to access it using an user field, but it is not possible to access to an user with an username, only with the account ID.

Page properties
hiddentrue

Status
Tech review

Status
colourGreenYellow
titledoneReady for review

Style guide

Status
colourGreenYellow
titledoneReady for review

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

Page properties
hiddentrue
3.0.1
Short description

Returns the full display name of a given user.

Output

Status
subtletrue
titletext
 
Status
subtletrue
titletext list

Available since
Status
subtletrue
colourBlue
title


Label