Allow scripted fields to be placed in their correct panel (eg. Dates)

Summary:  Script Fields in the Date format (Tagged as: Searcher: Date Time Range Picker and Template: Date Time Picker) are sporadically not showing up in the Date panel on the main issue view.

 

This issue originally appeared here: https://answers.atlassian.com/questions/281199

And was later addressed in a fix here: https://jamieechlin.atlassian.net/browse/GRV-430

The issue is, I am seeing it is again a problem in JIRA v7 with ScriptRunner v4.2.0.4.

 

Has support for this feature (showing script date fields in the date panel) been discontinued?  Is it just no longer available in JIRA v7?  Or are there additional configuration changes I need to make to have this function as intended?

 

 

1 answer

This widget could not be displayed.

Hi James,

I have just looked on my JIRA 7.0 instance and as long as the template for the Script Field is set to be of the Date Time Picker then it will show up in the dates panel of the view issue screen.

For any other return type it will not show up in the Dates panel.

An example of this shown in the scripted the field which is shown in the screenshots below which shows when the issue was last refreshed. Note the search index for the custom field must also be set to Date Time Picker for the field to show up in the dates panel.

image2016-2-5 18:16:16.png

image2016-2-5 18:15:16.png

I hope this helps.

Thanks

Kristian

Hello Kristian:

Thanks for the reply.  My issue at this point is that the dates do not always appear one way or the other.  About 60% of the time they will appear on the main view body and the rest of the time they show up on the Date panel.  I have tried multiple things to reset the fields (re-indexing, etc), but nothing I actively do seems to correct the issue.  I will just randomly open a different issue on screen or just refresh my current screen and the fields suddenly pop into the date panel (and not after a set number of refreshes or any other such method that is trackable).

My configuration appears much as yours.  The only difference I see is that I did not explicitly list any imports.

Do the imports need to be explicitly stated for this to work properly?

Thanks,

 

James

Hi James,

Do you see any errors in the logs or is the field returning no value.

The imports in my example are needed as I need to pull in the Java Simple Date Format and Date classes.

Thanks

Kristian

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Aug 22, 2018 in Marketplace Apps

How a Marketplace app tech team is achieving gender diversity

Hello! My name is Genevieve Blanch, and I'm the Marketing Manager at RefinedWiki, creators of apps to give teams the tools to customize Atlassian platforms. Currently, 44% of the tech team at Re...

529 views 3 19
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