Versions Compared

Key

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

...

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

Parameter name

Type

Required

Description

issue key

String

Yes

Key of the selected issue.

field name

String

Yes

Name of the selected field.

Return Type

/wiki/spaces/AA/pages/351830229JFieldChanges []

The return value is an array of JFieldChange. The strings come in pairs. The first value is a date representing the time when the value was modified and the second value is the content of the requested field at that date.

Examples

Example 1

Code Block
languagejs
JFieldChange[] changes  = getFieldChanges("TEST-10", "My Text Field");

return changes;

Result:
admin|2017-05-23 13:28:05|My Text Field||test|admin|2017-05-23 13:28:09|My Text Field|test|lalaa

...

Let's say we want to get the latest change for the given field:

Code Block
languagejs
JFieldChange[] changes  = getFieldChanges("TEST -10", "customfield _10200");
JFieldChange latestChange = changes[0];
date newest = latestChange.changeDate;

for (JFieldChange change in changes) {
    if (change.changeDate> newest ) {
        latestChange = change;
    }
       }
return latestChange;

Done. Program returned: admin|2017-05-23 13:28:09|Text Field|aaaaa|nnnnn

...

Filter by label (Content by label)
showLabelsfalse
max25
showSpacefalse
cqllabel = "customfield_routine" and space = currentSpace ( )
labelsarray_routines

We've encountered an issue exporting this macro. Please try exporting this page again later.