...
...
JAVA API Examples
Code Block | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
Read data of the grid.
@param issueId - id of the issue where rows should be added
@param customFieldId - id of the grid custom field where data should be read from
@param user - Jira user which will be used to control permissions
@param columnIds - set of columns' ids to filter columns for the returned result
@return object of Grid meta data and rows
GridFieldData readFieldData(Long issueId, CustomFieldId customFieldId, ApplicationUser user, Set<String> columnIds);
|
...
language | java |
---|---|
theme | Eclipse |
firstline | 1 |
title | readRows method script example |
linenumbers | true |
collapse | true |
...
Java API Examples
Expand | |||||
---|---|---|---|---|---|
| |||||
readFieldData usage exampleThe example script reads all data from a Grid custom field with default configuration called API Sample in issue TEST-1.
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
Code Block | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
Add rows to the grid.
@param issueId - id of the issue where rows should be added
@param customFieldId - id of the grid custom field where data should be added
@param rows - list of maps with columns' ids and values
@param user - Jira user which will be used to control permissions
@return list of rows' ids
List<String> addRows(Long issueId, CustomFieldId customFieldId, List<Map<String, Object>> rows, ApplicationUser user); |
...
language | java |
---|---|
theme | Eclipse |
firstline | 1 |
title | addRows method script example |
linenumbers | true |
collapse | true |
...
Expand | |||||
---|---|---|---|---|---|
| |||||
addRows usage exampleThe example script adds 2 rows to a Grid custom field with default configuration called API Sample in issue TEST-1.
|
Expand | |||||
---|---|---|---|---|---|
| |||||
updateRows usage exampleThe example moves all rows assigned to a current user in status In Review to status Closed in a Grid custom field with default configuration called API Sample in issue TEST-1.
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
Code Block | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
Update rows of the grid.
@param issueId - id of the issue where rows should be added
@param customFieldId - id of the grid custom field where data should be added
@param changes - list object that represent changes for specific rows
@param user - Jira user which will be used to control permissions
void updateRows(Long issueId, CustomFieldId customFieldId, List<GridRow> changes, ApplicationUser user);
|
...
language | java |
---|---|
theme | Eclipse |
firstline | 1 |
title | updateRows method script example |
linenumbers | true |
collapse | true |
...
|
Expand | |||||
---|---|---|---|---|---|
| |||||
deleteRows usage exampleThe example script deletes all rows assigned to a current user in status Closed in a Grid custom field with default configuration called API Sample in issue TEST-1.
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
language | java |
---|---|
theme | Eclipse |
firstline | 1 |
title | GridRow class |
linenumbers | true |
collapse | true |
...
|
Expand | |||||
---|---|---|---|---|---|
| |||||
readFieldDataInEditMode usage exampleThe example script checks whether a sample Grid custom field contains values on transition and throws an error otherwise.
|
...
|
...
|
...
|
...
|
...
|
...
|
...
language | java |
---|---|
theme | Eclipse |
firstline | 1 |
title | GridFieldData class |
linenumbers | true |
collapse | true |
...
|