You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
I'm trying to figure out a way to do the following:
If currentUser is member of group X, show issues with label Y
I'm pretty certain my above search is not possible the way I wrote it, but can I get the sought-after result in another way? Been scratching my head for a while, can't seem to find a good solution for this.
Doesn't have to be with labels specifically, but I think you get the idea.
I guess what I'm after is a form of "Assign to group" and have one system dashboard that works no matter which "group" you are in.
Can you please let us know where are you trying to run the query you informed? Is it in an automation plugin or in the own JIRA JQL filter? Should the users from other group be restricted from seeming issues with the label Y or this is only to build a customized filter with an easy display for each team?
If you are configuring it on a JQL query, I think you got the wrong idea of the JQL functionality. There's no way to make conditional queries using JQL, this is only a search language and not works for programming.
If you are trying to display different issues depending on a specific users group, I would recommend you to create one filter per group and then share it only with the users you need.
Taking your own scenario as an example, I would create a JQL filter like labels = y and share the filter only with the group X.
In fact, you can use labels or even custom fields to identify the group that should be working on the issue.
It's Jira JQL filter I'm talking about, being well aware that I'm wanting the dog to purr. The vagueness of this is due to me not really being able to work out a proper work around with the tools in front of me.
I want to create a system dashboard that works for all members, with some sort of group classification, where you only see the issues that are relevant to your team.
Let's say we have Mary in team A and Ken in team B. We have label A and B to correspond to the teams.
When Mary logs in, she sees the system dashboard. On the dashboard, there is a filter result that displays all open ticket with label "A". The filter doesn't show issues with other labels (or more specifically, issues without label "A").
When Ken logs in, it's the same thing, but for label "B". He doesn't see anything with e.g. label "A".
I can't rely on users using different dashboards or create their own, just getting them to understand how to navigate Jira in the first place can be a challenge, and I have to create the environment to need as little administration as possible in the long run (i.e., when I'm no longer part of this board).
I don't know if there is some ingenious way of getting the result I want with another approach, but I do know I can't do this the exact way I'm envisioning it.
Thank you for your detailed answer.
I believe that the only way that you can do this kind of configuration would be by adding a user picker (Multiple Users) custom field that must be filled in the creation of the issue, so you will be able to filter your gadget with the following JQL:
"user picker custom field" = currentUser()
Performing the steps above, your gadget will only display the issues where the current user is one of the users added to the Custom field.
Also, the user picker (Multiple Users) custom field can be filled with an entire group, so you will not need to flag every single user everytime you create a new ticket:
Please, let me know if this option would work for you, Simon.
FYI: We use the plugin Scriptrunner von Adaptavist and i wrote an additional JQL function:
It searches all AD groups of the current user for the AD group that is passed as the value by the parameter and returns all issues that fulfil this condition. This issueFunction can be linked with other JQL statements.
I`m not a professional delevoper but it helps us a lot and works as suggested :-D
So if this is still needed, I can gladly provide the code.