Forums

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

Comparing dates in automation

jan.ambroz
November 6, 2023

Hi there, 

 

I have automation that fetches data from Jira REST API and I would like to compare some dates from the response and one Issue date field. 

Screenshot 2023-11-06 at 2.45.17 PM.png

 

 

I am creating two variables:

  • sprintStartDate => {{sprint.startDate.substring(0,10).toDate.jiraDate}}
  • scheduledDate => {{issue.Date Scheduled}}

The output of these variables are :

2024-04-18
2024-04-17

 

If I use any function to compare these dates it never passes the condition. I guess I am not sending the dates correctly into compare function. 

 

I tried: {{scheduledDate.isAfter(sprintStartDate)}} but no output. 

 

How to format these dates to use them in the "Advanced compare condition"?

 

Thank you.

1 answer

0 votes
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 Champions.
November 5, 2018

What is the error message you get when you try to transition an issue from one status to another?

Deleted user
November 5, 2018

Hi Nic!

It's NS_ERROR_FILE CORRUPTED

I attached screenshot of the error. Kindly see above screenshots. Thank you!
I'm still experiencing the same issue as yesterday. Still having navigation and performance issue.

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 Champions.
November 7, 2018

Those errors are from the browser console, we need to see the error you get on the front end.

Although I would try clearing the browser cache and restarting it - ns_error_file usually refers to damaged files on the client side, not the server.

Deleted user
November 7, 2018

Hi Nic!

Already tried clearing browsing history, cache and all but still no luck.
I think error concerns about the time stamp?
As the error says...

e/this._getLastSentTimestamp https://jira-frontend.prod.atl-paas.net/assets/vendor.217cc9a39eacf9e29691.7.js:1:327090
    e/this._shouldSendEvent https://jira-frontend.prod.atl-paas.net/assets/vendor.217cc9a39eacf9e29691.7.js:1:327501
    e/this._sendEvent https://jira-frontend.prod.atl-paas.net/assets/vendor.217cc9a39eacf9e29691.7.js:1:327673

Thanks much!
       

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 Champions.
November 7, 2018

No, the error is about a corrupted file in your cache from the look of it.

Could you tell us what the on-screen error is, not the one you get from the js console?  And ideally the error in the Jira logs that should be seen at the same time?

Deleted user
November 7, 2018

Hi Nic,

Thank you very much on your time and support. Really appreciate it! :)
It's weird but now it's already working fine.

Actually, I have raised this too with the service desk, I don't know if they do something or not. But according to John Mata, a ticket was raised JST-430934 in JIRA support.

But to answer your question, there was no any on-screen error.
And for the logs, can't replicate now since it's already working. Sorry :(

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events