How to make a custom field not appear during issue creation

Balakrishna M July 5, 2018

I have been looking into the related question I am unable to get the proper answer.

My Req is :

1. I have created one custom field ( Days Opened - Value will poppulated by the Script Runner)

2.  I dont want this to be appear during issue creation.

I have verified across jira configf , I am unable to get it , Please advise me on this

3 answers

1 vote
Yogesh Mude
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.
July 5, 2018

HI @Balakrishna M

You can do like this..if you don't want this field on create issue screen but you want to show on view issue screen.

Copy/create a screen and then add this field on view issue screen, associate this view issue screen on view issue operation.

Add the custom script post function in that set the value of this field (Days Opened ) so whenever user will create an issue they will not be able to see this field but once the issue will create then post function will set the value for it and the user will be able to see the field on view issue screen.

Balakrishna M July 16, 2018

Yes This will work , but I am looking for the easier solution that this.

Nic Brough -Adaptavist-
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.
July 16, 2018

The easy solution is to remove the field (that you don't want on the create screen) from the create screen.

Balakrishna M July 16, 2018

I have two questions here 
1. So I have to create two screens , with/without variables ?

2. Is there any other way to do except the above one ?

Nic Brough -Adaptavist-
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.
July 16, 2018

1. Yes

2.  Not without coding of some form.  The reason screens were implemented was to allow for different fields to be presented at different places, as you're trying to do.

0 votes
JohnsonHoward
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.
July 5, 2018

Hi,

You could also add a Scriptrunner behaviour and map it to the issue types it usually appears on:

 

getFieldByName("Days Opened")?.setHidden(true)

Incredibly quick and easy to do. 

Thanks,

Johnson Howard 

Balakrishna M July 16, 2018

How do I set during IssueCreated the field should be hidden and during view screen it shouldnt be?

JohnsonHoward
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.
August 1, 2018

You can always check the action to see if it is on the create action.

Behaviours gives you access to such methods as:

getActionName()

Read this page to see what is available. In the behaviour script just do a simple if statement to check that the action is create and then hide the field if it is, in the else set the field to be not hidden. 

Thanks,

Johnson Howard

0 votes
Alexey Matveev
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.
July 5, 2018

Hello,

You mean that you created a scripted field in ScriptRunner and it appears in the create screen? 

Balakrishna M July 16, 2018

I have created a custom field and set it in a screen, which should not appear in create page screen .

The value of that field is populated through Scriptrunner script.

Alexey Matveev
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.
July 16, 2018

Remove this field from the create screen.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events