Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to get the user group membership when i add the user in a macro

Baris July 27, 2021

Hi

I'm trying to create a custom macro (I'm novice) where I select the user and want to see the list of group memberships where the user belongs.

User list macro does not achieve this because a group needs to be selected first.

I found an example in the community but i can't make it work.

## @param User:title=User|type=string|required=true|desc=Enter a user name.
<ul>
#foreach($group in $userAccessor.getGroupNamesForUserName($paramUser))
<li>$group</li>
#end
</ul>

 Is there another way to select the user and have the groups listed as a macro ?

thanks

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events