Versions Compared

Key

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


This routine is available starting with SIL Engine™ 4.8.0.11.
Info
titleAvailability
Table plus
applyColStyleToCelltrue
heading0
columnTypess,s,s,s
multiplefalse
columnAttributesstyle="background:#e5e7ea;font-weight:bold,,style="background:#e5e7ea;font-weight:bold,
enableSortingfalse

Syntax

getCustomFieldIdByName(customfieldName);

Package

Alias

Pkg Usage

Description

Excerpt
hiddentrue
Returns a list of ids for all custom fields with the given name.

Returns a list of ids for all custom fields with the given name.

Parameters

Table plus
applyColStyleToCelltrue
columnTypess,s,s,s
heading0
multiplefalse
enableSortingfalse

Parameter name

Type

Required

Description

...

customfieldName

String

Yes

Name of custom field to retrieve ids for.

Return

...

Type

String []

Returns an array of custom field ids.

Examples

Example 1

Code Block
return getCustomFieldIdByName("My Custom Field");

Returns: "customfield_10101"

Example 2

This example has multiple custom fields for a single name.

Code Block
string myCustomField;
for(string id in getCustomFieldIdByName("My Custom Field")) {
	    //check the context for the calling issue to determine which custom field to use
    	if(isCustomFieldInContext(id, projectKey, issueType) {
		
        myCustomField = id;
	    }
} 

return myCustomField;

See also

Filter by label (Content by label)
showLabelsfalse
max25
showSpacefalse
cqllabel = "jiracustomfield_group_routine" and space = currentSpace ( )
labelsjiraarray_group_routineroutines