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

Script Field - Date Time Picker always returns $datePickerFormatter.format($value)

Mahek Mody Dec 18, 2017

code I have tried

def last_test_date = Date.parse("yyyy-MM-dd hh:mm:ss", "2014-04-03 1:23:45")

return last_test_date 


return "12-13-2017"

return "13-12-2017"

return "12/13/2017"

return "12/Dec/2017"


Nothing seems to work.

1 answer

1 accepted

0 votes
Answer accepted

Hi Mahek,

Which searcher are you using for this script field? Your first example (where you return a Date object) should work correctly, so long as you make sure that the searcher is set to 'Date Time Range picker'.



Mahek Mody Dec 21, 2017 • edited

I don't get "Date Time Range Picker" as an option.

I am using "Date Time Picker" - Same result

Joanna Choules [Adaptavist] Dec 22, 2017 • edited

Hi Mahek,

'Date Time Picker' is one of the available templates for a script field, but you also need to select the right searcher, which in this case is 'Date Time Range picker'. You can select the searcher as follows:

  1. Go to the Script Fields tab, where all of your script fields are listed.
  2. Locate the field you want to configure. In the left-hand column are listed the configuration scheme, the searcher, and the template (see first image below for an example).
  3. Click on the name of the searcher, and you will be taken to a page where you can edit the field's details (see second image).
  4. Select 'Date Time Range picker' from the 'Search Template' drop-down and submit the form.

Image 1

Screen Shot 2017-12-22 at 11.21.02.png

Image 2

Screen Shot 2017-12-22 at 11.18.43.png

Mahek Mody Dec 23, 2017


That is the issue, the problem is fixed.

Thanks Jake. Appreciate the effort.

Hi Mahek,

I'm glad to hear that the problem is resolved. If you find this answer to be useful, please consider accepting it so that other users of Community who may be having the same issue as you will be able to see that there is a solution available.

Many thanks,


Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Marketplace Apps & Integrations

Webinar alert! An IT Admin's Guide to Securing Collaboration at Scale

Hello, Atlassian Community! My name is Dave Meyer and I'm a Principal Product Manager at Atlassian. I wanted to give this community a heads up about an upcoming Webinar that might be of interest...

188 views 2 7
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