Is it possible to have two different teams to jira, but they can't see each others projects?

Is it possible to have two different teams to jira, but they can't see each others projects?

2 answers

2 votes

A better solution than issue level security (which you have to then remember to set, or use a script) is the "Reporter Browse" permission - see https://confluence.atlassian.com/jira/current-reporter-browse-project-permission-135274.html

But the question said "project", not "issue", so I suspect the answer is far more simple.  Look at the permission schemes for the projects and look at the "browse" permission for both of them.  They probably say "Role: User".  That means "look at the users and groups in the role of user in this project".  What you need to do is remove the users/groups that grant them the access you want to deny, and only let the right users see the issues.  (This usually means "create group A for project A, and group B for project B and add those groups separately into the projects, and then remove the default group of 'JIRA users', which is granting access to everyone)

Hi Jon,

I assume your requirement is 2 teams using same JIRA Project and each team should not see issue of other ?

If this is the requirement then you can achieve using JIRA Issue Level Security.

If you want your users to not select this security level and want to automate this on create issue, you need custom Workflow post function. If you have Script Runner plugin then you could use custom script post function on Create transition and add below code, you can  modify it as per your need

import com.atlassian.jira.ComponentManager 
import com.atlassian.crowd.embedded.api.* 
import org.ofbiz.core.entity.GenericValue 
import com.atlassian.jira.bc.project.component.ProjectComponent
import com.atlassian.jira.bc.project.component.ProjectComponentManager
import com.atlassian.jira.security.groups.GroupManager   
     
  ComponentManager componentManager = ComponentManager.getInstance() 
  User currentUser = componentManager.getJiraAuthenticationContext().getUser()
  GroupManager groupManager = componentManager.getComponentInstanceOfType(GroupManager.class)
     
 if(groupManager.isUserInGroup(currentUser.name, "jira-administrators"))
    {
        issue.setSecurityLevelId(10001) 
    }
  else if(groupManager.isUserInGroup(currentUser.name, "jira-developers")) 
    {
        issue.setSecurityLevelId(10000) 
    }

 

Regards,

Taha

 

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 27, 2018 in Portfolio for Jira

Introducing a new planning experience in Portfolio for Jira (Server/DC)

In the past, Portfolio for Jira required a high degree of detail–foresight that was unrealistic for many businesses to   have–in   order to produce a reliable long-term roadmap. We're tur...

2,541 views 15 21
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you