User Group and Issue creation

Hi, I want to restrict some fields when a user ( belongs to a group ) create an issue. Also want to autocomplete version and fix version's field.

Can I do that?

The secuence should be something like this:

1. Create Issue

2. Only a few types of issue appears to select ( i would configuring this )

3. Then some fiend will be autocompleted ( i would configuring that too)

4. Create Issue.

Thanks!

3 answers

1 accepted

This widget could not be displayed.
Timothy Chin Community Champion Oct 06, 2013

2. Only a few types of issue appears to select ( i would configuring this )

You're looking for this (https://jira.atlassian.com/browse/JRA-1330).

3. Then some fiend will be autocompleted ( i would configuring that too)

You might want to consider using post functions to do this. The script runner add on should be useful.
This widget could not be displayed.

you mean, custom fields should be display for specific users/group? then try with javascript

<script type="text/javascript">  
JIRA.bind(JIRA.Events.NEW_CONTENT_ADDED, function (e,context) {
hideField();    
});
hideField();
function hideField(){
        var user=getCurrentUserName();          
        if(isUserInGroup(user,'Developers')){
            //to hide the Activity Tab
            $("#customfield_10571").closest('div.field-group').hide();
        }else {
            AJS.$("#customfield_10571").closest('div.field-group').show();
        }
 
}
function getCurrentUserName()
{
var user;
     AJS.$.ajax({
        url: "/rest/gadget/1.0/currentUser",
        type: 'get',
        dataType: 'json',
        async: false,
        success: function(data) {
            user = data.username;
        }
     });
     return user;
}
   
   
function getGroups(user)
{
var groups;
     AJS.$.ajax({
        url: "/rest/api/2/user?username="+user+"&expand=groups",
        type: 'get',
        dataType: 'json',
        async: false,
        success: function(data) {
            groups = data.groups.items;
        }
     });
     return groups;
}
function isUserInGroup(user, group){
    var groups = getGroups(user);
    for (i = 0; i < groups.length; i++){
         if (groups[i].name == group){
              return true;
         }
    }
    return false;
}
     
 
</script>

check this

https://answers.atlassian.com/questions/215699/can-i-configure-user-group-who-can-view-a-custom-field?page=1#comment-217292

This widget could not be displayed.

Thanks, it seems that i'll have to do it in another way. I saw that screen schemes configuration also meet my needs.

Thanks to all !!

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Apr 22, 2018 in Jira Software

How-to setup a secured Jira Software 7.9.0 on Ubuntu 16.04.4 in less than 30 minutes

...PermissionsStartOnly=true User=www-data Group=www-data ExecStart=/opt/jira/bin/startup.sh ExecStop=/opt/jira/bin/shutdown.sh TimeoutStartSec=120 TimeoutStopSec=600 PrivateTmp=true [Install] WantedBy...

1,489 views 10 12
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