Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to hide tabs on Create screen for an issue

J Manas Kumar
Contributor
February 20, 2020

Hi plan.PNG

I have a issue , my requirement is while creating that issue based on condtion i need to hide some of tabs present in its screen.

I wrote one behavior which work while editing but not working on create issue.

below i have pasted the code. with screen shot.

here while selecting "Project Type" == "Waterfall" then only i need to show these extra 4 fields otherwise i wont.

In the screen shot you can see if i select waterfall exra 4 fields should come, but even if i have not selected waterfall value its coming.

 

if(getActionName() as String == "Create") {

def projectTypeValue = getFieldByName("Project Type").getValue() as String
if(projectTypeValue != null) {

if(projectTypeValue == "Waterfall") {

showTab("BR Approvals")
showTab("FR Approvals")
showTab("SIT Test Plan Approvals")
showTab("UAT Test Plan Approvals")


}else{
hideTab("BR Approvals")
hideTab("FR Approvals")
hideTab("SIT Test Plan Approvals")
hideTab("UAT Test Plan Approvals")
}
}
}else{
hideTab("BR Approvals")
hideTab("FR Approvals")
hideTab("SIT Test Plan Approvals")
hideTab("UAT Test Plan Approvals")
}plan.PNG

 

 

Regards

Manas

2 answers

0 votes
Matt Doar
Community Champion
February 20, 2020

I think I would use different issue types per Product Type and then an issue type screen scheme to control which fields are visible for each product type. That use of Jira tabs looks very confusing to me

0 votes
Victor Mutambuki
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 20, 2020

Manas,

Remove the fields from Create Issue screen and instead add them to the View Issue screen 

Victor

J Manas Kumar
Contributor
February 20, 2020

Hi @Victor Mutambuki 

 

I had that in my mind too, but what is my doubt is if i remove it , then what will happen , when i will select "Project Type" == " Waterfall" ? from where i can show those tabs if they dont present in create screen?

i need to add them in edit and view screen but what about while create issue?

 

 

Regards

manas

Suggest an answer

Log in or Sign up to answer