[All Adaptavist Apps]
You can reference the following functions and properties within your behaviour scripts:
Returns the name of the affected field.
String
Returns the description of the affected field.
String or Atlassian Document Format object depending on how your instance is configured
Returns the value of the affected field.
The type of value depends on the affected field you have chosen.
Affected field | Type |
---|---|
Summary | String |
Description | String or Atlassian Doc Format depending on how your instance is configured. |
Labels | String[] |
Priority | { iconUrl: string, name: string, id: string } |
Assignee | { accountId: string, displayName: string, } |
Returns the Id of the affected field.
String
Returns a boolean indicating whether or not the affected field is visible.
boolean
Returns information about a specific field and then allows you to call the set methods outlined below on that field to set properties on the field.
Name | Type | Description |
---|---|---|
fieldid | String | ID of the field. Note that only affected fields are supported. |
Code Block |
---|
{
getName(): string,
getDescription(): string,
getID(): string,
getValue(): depends on the field, see table in getValue above
isVisible(): boolean
} |
Updates the name of the affected field.
Name | Type | Description |
---|---|---|
name | String | The new value for the name field. |
Updates the description of the affected field
Name | Type | Description |
---|---|---|
description | String or Atlassian Doc Format Object | The new value for the description field. |
Updates the value of the affected field.
The value parameter will depend on the affected field you have chosen.
Affected field | Type |
---|---|
Summary | String |
Description | String or Atlassian Doc Format depending on how your instance is configured. |
Labels | String[] |
Priority | { iconUrl: string, name: string, id: string } |
assignee | { accountId: string, displayName: string, } |
Hides the specified field if is visible on the current screen.
shows the specified field if is visible on the current screen.
Used to make a request to the Jira Cloud REST API.
Note | ||
---|---|---|
| ||
|
Name | Type | Description |
---|---|---|
path | String | REST endpoint to hit e.g /rest/api/2/myself |
Promise<{ status: number, body: JSONObject}>
An object containing functions used for logging
Available logger functions
Follow the steps below to create a behaviour in ScriptRunner for Jira Cloud:
...
...