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
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Thursday in Jira

5 ways you can make the most of Jira Software and Bitbucket Cloud

As part of the Bitbucket product team I'm always interested in better understanding what kind of impact the use of our tools have on the way you work. In a recent study we conducted of software devel...

70 views 0 5
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