Display view configuration


Table of contents



Display view

Available for LIVE FIELDS 

Optionally, you can set a different query configuration and editor configuration to be used when the field is displayed in Jira.

You might want to override this configuration if:

  • you want a different field rendering when it's edited and displayed
  • you want to improve performances



How it works

Display query not set

First, we'll see how Elements Connect works when the display query is not set. 

When the fields described above is displayed in an issue:

  1. Elements Connect executes the Edit view query

    idcustomercountry
    1John FarnsworthIndia
    2Erika PenaFinland
    3Mary SmithJapan
    4Patricia JohnsonUnited States
    5Linda WilliamsGreece
    etc...
  2. then, it identifies the values(s) selected in the field by looking at the "key" column

    idcustomercountry
    1John FarnsworthIndia
    2Erika PenaFinland
    3Mary SmithJapan
    4Patricia JohnsonUnited States
    5Linda WilliamsGreece
  3. and finally applies the template on the matching rows.

    display value
    Mary Smith (Japan)

This can lead to performance issues if the edit query returns a high number of result or if the request is slow.

In our example above, the edit query returns 600 rows, whereas we only need 1: the one selected during edit.

Display query set

In the Display query configuration, we have access to the field value (the key, the value stored in the Jira database) through the $currentCustomfieldValue velocity variable.

We can set the display configuration as follows:





When an issue where the Connect field is set is displayed,

  1. the $currentCustomfieldValue variable is replaced with the connect field value:
    SELECT name, country FROM customer_list WHERE id = 3 

  2. the query result set is:

    namecountry
    Mary SmithJapan
  3. from this result set, Elements Connect compute the template:
    Mary Smith (Japan) 

  4. and display the result in the issue view

This time, the query executed only returns 1 row - whereas the edit query returned 600 rows.

As you can guess, this is much more faster:

  • the query execution time is lower
  • less data sent on the network
  • Elements Connect does not have to look up for a result in a list of hundreds

and can only improve the performances.



Configuration

Display views are divided in two categories:

  • Main display view
  • Specific display views

A hierarchy is applied on views:

  1. Edit view
    1. Main Display view
      1. Specific view

Query configuration and Editor configuration can be set independently.
If a configuration is not set, then Elements Connect uses the configuration set at the upper level.






Main view

If set, this configuration is always used when a Connect field is displayed (unless a specific view is defined).

Specific views

To cover specific needs, it's possible to configure a specific query and/or editor on the secondary views.

Dashboard gadget

This configuration is used when a field is displayed in a Jira dashboard statistics gadget, such as:

  • Pie Chart
  • Heat Map
  • Bubble chart
  • etc...





Two restrictions apply on this view:

  • HTML tags cannot be used in the template (otherwise they won't be interpreted)
  • References to $issue  are not available, only the $currentCustomfield variable can be used
    Indeed, there is no issue context in this case, as we see statistical values computed on a set of issues

Issue navigator column

This configuration is used when a field is displayed in a column, when the "List View" is used in the issue navigator.





It's recommended to override this view template when the default display takes up a lot of space.

Issue navigator summary

This configuration is used when a condition is set on a field in the basic mode of the issue navigator, to display the values selected in the search bar:





Elements Connect REST API

Configuration used when an Elements Connect field value is retrieved using Elements Connect REST API

Post-function comment

Configuration used when an Elements Connect field value is posted in a comment using Elements Connect "Post comment" post function.

XML export

Configuration used when an issue is exported to XML.