Page tree
Skip to end of metadata
Go to start of metadata


Display a filtered list of users with their avatar and name and additional information like phone number or position for e.g., a phone book

Configure which users to include in the list and which profile fields to display

Customized User List Macro

Create customized lists of users

The Customized User List Macro enables you to display a list of users filtered by a profile field value. For example this macro can be used to create a simple phone book for your department (see first image) or to list your team members on your team homepage or similar use cases, where you want to display a custom list of users. You are also able to configure which profile fields are shown in the list. The user list will only show people that have access to confluence.

The second image shows the configuration options for the macro:

Search Options

  1. Choose the profile field you want to filter on (e.g., "Location").
  2. Enter the value you want to filter for (e.g., "Wiesbaden").
  3. Add as many profile fields as you want to narrow your search request.

Display Options

  1. Displayed profile fields
    Choose the profile fields you want to be displayed as additional columns in the list (e.g., "Phone" and "Position"). The users avatar and name are always displayed.
  2. Ordered by
    Choose the profile field by which the list will be initially ordered. You can still order the list manually by clicking on the headlines in the table view.

The given example will display a list of all users whose profile field "Country" has the value "Deutschland" and will include their avatar, name, phone number, position, branch, country and e-mail.

You can use a subset of the Confluence search syntax for the profile field value, e.g., "W*" to find all users from Washington and Wiesbaden. Feel free to get in contact with us if you encounter any issues!

Due to security reasons, you can only configure visible fields since release 1.11.1.

Use Confluence Query Language for more flexibility

The Customized User List macro gives you now an expert mode where you can use the Confluence Query Language (CQL). CQL allows much more complex searches for users. To use CQL just switch the "Filter mode" to "Expert mode" and enter the CQL search string. For that you need to know the keys (this are not the names you gave to the fields!) of available Linchpin User Profile fields. You can find all available fields directly in the macro configuration, just click on "CQL help".

CQL Search examples:

exact match

cup.location="New York"

contains

cup.location~"York"

contains with operators

cup.department~"Marketi*"

cup.department~"Mar??ting"

contains any of listcup.department in ("HR", "Marketing")
contains none of listcup.department not in ("HR", "Marketing")

concatenation

cup.location="New York" AND (cup.department="marketing" OR cup.department="hr")

The following table shows which operators can be used with witch field types

CUP Field Type=!=~!~>>=<<=INNOT INANDORNOT( ... )
Input(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Textarea(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Select(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Multiselect(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Cascade(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Date(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
User(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Language(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Country

(tick)






(tick)(tick)(tick)(tick)
LDAP(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Dependent(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
Phone(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)
IM(tick)
(tick)




(tick)
(tick)(tick)(tick)(tick)


More information about CQL can be found in the official CQL documentation by Atlassian.

  • No labels