Versions Compared

Key

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

...

Considering we have a KCF - Single select configured with one SIL Data Source, one Selection script, minimum characters for autocomplete set to 5 and the maximum results number set to 50. We want to select an issue using its key or summary. The custom field looks like this: 


 The SIL data source used to populate the custom field above: 

Code Block
string [] issues = selectIssues("created < now()");
string [] res;
for (string iss in issues) {
    if (contains(iss.summary, argv["query"])) {
    res = addElementIfNotExist(res, iss);
    }
}
return res;

 

The select script used is:

Code Block
Option[] selectedOption = customfield_12209;
linkIssue(key, selectedOption[0].value, "Relates");

...