Issue on my project with CRON Expression and JQPL

Giuseppe Amoruso May 16, 2021

Hi all,

I have a problem with my project.

I need to create an automation that close the issue automaticly when the "Planned end date" has been passed. I give an example: "if the planned end date is 16/05/2021 6PM, the issue must closed tonight at 11.59PM."

Until now, tickets have been closed on the same day as the ticket was opened.

 

Can you help me?

BR,

2 answers

0 votes
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 16, 2021

Hi Giuseppe - so what is not working with it now? 

Giuseppe Amoruso May 16, 2021

Hi, the rule works only that the ticket closes on the day of creation and not the day set in the PLANNED END DATE field.

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 16, 2021

Just remember that the date/time for the cron is UTC - so you might have to adjust the timing based on your time zone. 

Giuseppe Amoruso May 16, 2021

Hi,

yes, what happens is that the ticket closes on the day of opening and not when the "Planned End Date" occurs.

Do you have any other suggestions?

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 17, 2021

What time zone are you located in? 

And at what time would you like the rule to fire local time? 

Giuseppe Amoruso May 17, 2021

Hi, the Time zone is CET.

I would like to fire the rule at 23.59 local time (not every day but on the day reported in the  Customer Field Planned End Date).

BR,

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 17, 2021

So, is custom field 10081 the planned end date?

Giuseppe Amoruso May 17, 2021

Yes.

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 17, 2021

So it runs a one minute to midnight tonight - but it would process tickets for today? Or tomorrow? Or yesterday? 

Giuseppe Amoruso May 19, 2021

Hi,

I would like to set the rule that the ticket must close automatically at 11.59 pm on the day set in the custom field "Planned end time".

The set rule now closes the ticket on the same day as the ticket is created.

BR,

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 21, 2021

Ah, now that I think about it, I believe it is your query. try doing the Planned end date as < now()

Giuseppe Amoruso May 21, 2021

Hi, can you give me the correct syntax? Just to make no mistake.

BR,

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 21, 2021

Just update exactly what you have already except change out

> startOfDay()  

with 

< now()

0 votes
Giuseppe Amoruso May 16, 2021

I add a screen with the automation.Automation.JPG

Suggest an answer

Log in or Sign up to answer