# Case list

## Configuration of case visibility on the case list

For a case to be visible on the list, permissions for the role must be configured [user](https://docs.eximee.com/documentation/documentation-en/budowanie-aplikacji/interfejs-uzytkownika/eximee-dashboard/konfiguracja/uprawnienia) (PROCESS\_DEFINITION\_KEY\_MAPPING parameter).

Case visibility on the list is additionally handled by the mechanism: Dynamic definition of access to the case list (setAccessGroups).

{% hint style="warning" %}
This mechanism grants only \*\*additional\*\* permissions. The functionality does not allow removing case permissions granted via PROCESS\_DEFINITION\_KEY\_MAPPING.
{% endhint %}

## Case label configuration

It is possible to configure the label for a case in the left part of the tile on the Eximee Dashboard page, located for example at:

```
ROUTER_HOST:8083/router-ui/#/processes
```

To configure the label, create a new task of type in the BPMN process *ScriptTask* and attach it to the process:

<figure><img src="https://2112972046-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2CssJT0zIo4SJQLbSZ6l%2Fuploads%2Fgit-blob-bc7b36abbf1b277967560fa39b1e4544461e9f1a%2F1-Konfiguracja-zadania%20-ScriptTask.png?alt=media" alt=""><figcaption><p>Figure 1. Configuration of the "ScriptTask" task</p></figcaption></figure>

In the configuration [of the script task](https://docs.eximee.com/documentation/documentation-en/budowanie-aplikacji/proces-biznesowy/zadania-automatyczne/zadanie-skryptowe-bpms-scripttask) set:

* **Script Format**: groovy
* **Script Type**: Inline Script
* **eScript**: Here is Groovy code that will set in the variable **PROCESS\_DASHBOARD\_DESCRIPTION** the label value of text type, e.g.

```
execution.setVariable("PROCESS_DASHBOARD_DESCRIPTION", "Foreign currency loan application");
```

<figure><img src="https://2112972046-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2CssJT0zIo4SJQLbSZ6l%2Fuploads%2Fgit-blob-3b7715df7a343038339878ced5767ed198fc6c77%2F2-Lista-spraw.png?alt=media" alt=""><figcaption><p>Figure 2. Case list</p></figcaption></figure>

When the process is completed (has status *COMPLETED*), the text is displayed: *Case completed*.

When the process is not completed and does not have the variable filled in **PROCESS\_DASHBOARD\_DESCRIPTION** then we do not display the label.

In other cases, we display the text indicated in **PROCESS\_DASHBOARD\_DESCRIPTION**, in the example it is "Process start" and "Form".

## Data display configuration

It is possible to configure the displayed data in the middle part of the tile on the Eximee Dashboard page, located for example at:

```
ROUTER_HOST:8083/router-ui/#/processes
```

To configure which data we want to display in the middle part of the tile, create a new task of type in the BPMN process *ScriptTask* and attach it to the process:

<figure><img src="https://2112972046-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2CssJT0zIo4SJQLbSZ6l%2Fuploads%2Fgit-blob-f153a8a7563c0cca7f80e6e387fd50f4a9d06114%2F3-Konfiguracja-zadania%20-ScriptTask.png?alt=media" alt=""><figcaption><p>Figure 3. Configuration of the "ScriptTask" task</p></figcaption></figure>

In the configuration [of the script task](https://docs.eximee.com/documentation/documentation-en/budowanie-aplikacji/proces-biznesowy/zadania-automatyczne/zadanie-skryptowe-bpms-scripttask) set:

* **Script Format**: groovy
* **Script Type**: Inline Script
* **Script**: Here is Groovy code that will set in the variable **PROCESS\_DASHBOARD** the configuration map on the right side of the tile.

We can add configuration in the form of label-value pairs, which will be displayed on the case list in Eximee Dashboard.

Remember that values in the key must be unique.

Literal values or process variables can be passed to the map values using:

```
execution.getVariable("VARIABLE_NAME");
```

Example code supplementing the configuration:

```js
execution.setVariable("PROCESS_DASHBOARD", [
"Label1": "Value1",
"Label2": execution.getVariable("variable1")
]);
```

We can also specify the order of displayed variables by providing a number in square brackets at the beginning of the key, based on which the variables will be sorted, e.g. "\[1]Label". Such a number will not be displayed, and variables without a number will go to the very end. For example, the map:

```js
execution.setVariable("PROCESS_DASHBOARD", [
 "[3]A": "A",
 "B": "B",
 "[1]C": "C"
]);
```

will be displayed as key-value pairs in the order of the labels C, A, B.
