Skip to end of banner
Go to start of banner

admDeleteCustomFieldOption

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »


Availability

This routine is available since katl-commons 4.0.4.

Syntax:

admDeleteCustomFieldOption(option, fieldName[, projectKey, issueType])

Description:

Delete an option from the options list for the specified context. If the project key and issue type are not specified, the option will be deleted from the global context.
This routine only handles custom fields of the following types: single select, multi select, radio buttons and checkboxes (otherwise throws an exception).

This routine does not delete the context, it only deletes the specified option.


Parameters:

Parameter name

Type

Required

Description

option

string

Yes

The option to be deleted

fieldNamestringYesThe name of the custom field
projectKeystringNoThe project key
issueTypestringNoThe issue type

Return type:

boolean (true/false)

Returns true if the option was deleted successfully, false otherwise. If returned false check the log for a detailed reason on why it failed.

Example:

Example 1:

Delete the "Option" from the global context of custom field "Select List".

admDeleteCustomFieldOption("Option", "Select List");


Example 2:

Delete the "Option" from custom field "Select List" with context for project "TEST" and issue type "Task".

admDeleteCustomFieldOption("Option", "Select List", "TEST", "Task");


See also:

  • No labels