Versions Compared

Key

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

Supported list types

Table of Contents
exclude(Supported list types).*
stylecircle
typeflat
separatorpipe

Number list

UI Text Box
sizemedium
typeinfo

This function filters a number list by the list elements' cardinality (how often they appear in the list) using the given comparison.

Code Block
languagebash
titleSyntax
linenumberstrue
filterByCardinality(numberList, operator, number) #Output: Number list
UI Expand
titleExamples
Parser expressionDescription
Code Block
languagebash
linenumberstrue
filterByCardinality([anyNumberList], >, 1) 
In this example a number list with those elements would be returned, that occurred more than once in the number list.
Code Block
languagebash
linenumberstrue
filterByCardinality([1, 1, 2, 3, 4, 4, 4, 5], >, 1) 

This example returns

[1, 4]

since 1 and 4 are occurring more than once in the list.

Code Block
languagebash
linenumberstrue
filterByCardinality([1, 1, 2, 3, 4, 4, 4, 5], =, 1) 

This example returns

[2, 3, 5]

since these values are occurring exactly once in the list.

UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
numberList

Status
subtletrue
titlenumber list

Any given number list.
operator

Status
subtletrue
titleoperator

One of the following comparison operators: =, !=, <, <=, > and >=.
number

Status
subtletrue
titlenumber

Any given number that will be used in combination with the operator to filter the given list.
UI Expand
titleOutput

This function returns a

Status
subtletrue
titlenumber list
.

If the number list is empty or the comparison won't be fullfilled by any element, the function returns an empty 

Status
subtletrue
titlenumber list
.


Text list

UI Text Box
sizemedium
typeinfo

A variant for text lists.

Code Block
languagebash
titleSyntax
linenumberstrue
filterByCardinality(textList, operator, number) #Output: Text list
UI Expand
titleExamples
Parser expressionDescription
Code Block
languagebash
linenumberstrue
filterByCardinality(["tiger", "tiger", "tiger", "lion", "lion", "cat", "lynx"], <, 3) 

This example returns

["lion", "cat", "lynx"]

since these elements are occurring less then than 3 times in the list.

Code Block
languagebash
titleSyntax
linenumberstrue
filterByCardinality(fieldValue(%{issue.component}, subtasks()), =, count(subtasks()))

This example returns a text list with those Components who are present in all sub-tasks.

To achieve this, the following functions are used:

UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
textList

Status
subtletrue
titletext list

Any given text list.

operator

Status
subtletrue
titleoperator

One of the following comparison operators: =, !=, <, <=, > and >=.
number

Status
subtletrue
titlenumber

Any given number that will be used in combination with the operator to filter the given list.
UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext list
.

If the number list is empty or the comparison won't be fullfilled by any element, the function returns an empty 

Status
subtletrue
titletext list
.


Issue list

UI Text Box
sizemedium
typeinfo

A variant for issue lists.

Code Block
languagebash
titleSyntax
linenumberstrue
filterByCardinality(issueList, operator, number) #Output: Issue list
UI Expand
titleExamples
Parser expressionDescription
Code Block
languagebash
linenumberstrue
filterByCardinality(linkedIssues(), >, 1)

This example returns an issue list with all issues that are linked to the current issue more than once.

To achieve this, the following functions are used:

UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
issueList

Status
subtletrue
titleissue list

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

Status
subtletrue
titleoperator

One of the following comparison operators: =, !=, <, <=, > and >=.
number

Status
subtletrue
titlenumber

Any given number that will be used in combination with the operator to filter the given list.
UI Expand
titleOutput

This function returns an

Status
subtletrue
titleissue list
.

If the number list is empty or the comparison won't be fullfilled by any element, the function returns an empty 

Status
subtletrue
titleissue list
.

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

Filters a given number, text, or issue list by the number of occurence of elements.

Output

Status
subtletrue
titlelist

Available since

Status
subtletrue
colourRed
titleneeds lookup

Label