Versions Compared

Key

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


Warning
titlePower Custom Fields PRO™ is becoming Power Custom Fields™


Power Custom Fields PRO™ is being upgraded to Power Custom Fields™. We are removing Power Custom Fields PRO™ from the market to focus resources on the combined app, Power Custom Fields™ which has all the features of PRO™ and more. Existing Power Custom Fields PRO™ users can get 65% off their new Power Custom Fields™ license by following the steps here.


Note

In order to use dependent fields you must have Power Scripts for Jira app installed and enabled.

To use the screen values for a field in the data source, you have to add it as a dependent field. 

Image Modified 

Example

 Example: Let's suppose say we have two custom fields: one KCF  PCF-PRO - Single Autocomplete and one KCF and PCF-PRO - Multiple Autocomplete, and the second one field is populated depending on the value of the first one.

An easy example would be: For instance, the first custom field has five options , representing the five continents, and the second one contains the countries from some table ("countries")the countries table, depending on the value selected on the first one. You can see the corresponding data sources below: 

The The following data source for represents the first custom field: 

Code Block
return {"AFRICA", "ASIA", "EUROPE", "AMERICA", "OCEANIA"};


 The The following data source for represents the second custom field: 

Code Block
string x = argv["customfield_10101"];
string[] res = sql("myDB", "select country from countries where continent like '" + x + "'");
return res;


In The following result will be on the issue view screen, the result would look like this

Image Modified 


You can find a similar example here.

Note

For the moment, dependent fields can only be used by the two custom fields with autocomplete, and can only be referred in SIL data sources.

Starting with Power Custom Fields PRO 4.0.0, you can use the dependent fields on SQL data sources as well.

In order to get the value set on the screen for one custom field, you will have to refer it like this: refer by using:

  • "argv[customfield_id]" - in the SIL datasources
  • "{customfied_id}" - in the SQL datasources

See also