Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Hide Issue type Edited

I want to hide the issue type in a project and i tried script runner behaviour . Here the script below

import com.atlassian.jira.component.ComponentAccessor
import static com.atlassian.jira.issue.IssueFieldConstants.ISSUE_TYPE

def projectRoleManager = ComponentAccessor.getComponent(ProjectRoleManager) def allIssueTypes = ComponentAccessor.constantsManager.allIssueTypeObjects def user = ComponentAccessor.jiraAuthenticationContext.loggedInUser def issueTypeField = getFieldById(ISSUE_TYPE) def remoteUsersRoles = projectRoleManager.getProjectRoles(user, issueContext.projectObject)*.name def availableIssueTypes = [] if ("Users" in remoteUsersRoles) { availableIssueTypes.addAll(allIssueTypes.findAll { in ["Query", "General Request"] }) } if ("Developers" in remoteUsersRoles) { availableIssueTypes.addAll(allIssueTypes.findAll { in ["Bug", "Task", "New Feature"] }) } issueTypeField.setFieldOptions(availableIssueTypes)

But i'm getting error code is 

Parsing XML failed: Unexpected character 'i' (code 105) in prolog; expected '<' at [row,col {unknown-source}]: [1,1]

Also attaching the screen shot below 

Hide support type.png

and we are using script runner version is 5.7.0 and jira version is 7.13.11

Please help me with this where to changes implemented on script



1 answer

Is there something preventing you from removing the 'support' issue type from the Issue Type Schemes that the current project is using?


Thanks for the responce,

Is there any related script so i can hide the 'SUPPORT' issue type in particular project.

Note: Support issue type is assign with few issues in this project so i am unable to delete in  Issue Type Schemes. So, i want to hide using behaviour please let me know is any relevant script.


Daniel Ebers Community Leader Jul 22, 2021

In case it is just because some issues are currently having this issue type you could migrate them to any other issue type defined in your Issue Type Scheme - would that be an option?

Restricting issue types is possible, however I have never tested it with a Service Management project:

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Trello

🏊‍♀️ Atlympic Event: Trello

Hello Community!  Quick disclaimer: We are running a contest on Community (The Atlympics!) from July 23rd - August 8th of 2021. If you are interested in participating in this contest (prizes! ...

170 views 2 13
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you