User is creating and issue and has 2 date fields....
Start Date and End Date - Is there a way to stop the user being able to enter an earlier date than the Start Date in End Date
HI @Rob B
Yes this would be implemented as a validator on the create transition.
Note to access the create transition you need to view the workflow in diagram mode and select the line from the grey circle.
Depending on whether this is an on premise or cloud instance will then impact how you can compare the dates.
Cloud
On Premise
To do date comparisons on premise you need to use a plugin here is an example using JSU
An alternative is to use Scriptrunner and base the script off the information at https://library.adaptavist.com/entity/calculate-the-difference-between-two-dates
This latter option gives you greater flexibility in terms of checking for a minimum gap between the dates for example or checking for the existence of both fields.
Thanks Phil! Ill give it a go
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Rob B ,
We have opened a support ticket, https://beecom-products.atlassian.net/servicedesk/customer/portal/3/JSU-3493 to better track your request. However, we couldn't add you as a reporter.
Please sign up using this link https://beecom-products.atlassian.net/servicedesk/customer/portal/3/user/signup and share the user name/id. We'll then add you as the reporter and confirm.
Thanks,
Manisha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Rob B ,
Please add the Date Compare (JSU) validator to the specific workflow transition.
Now, save and publish the workflow and rerun the scenario, if the End date is smaller than the Start date, you will see the error message. Please refer to the below gif file for details.
Please let us know if you face any issues.
Thanks,
Manisha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Robert,
it is possible to validate these date fields during the create transition. You must edit the workflow and add the "Date Compare Validator" validation to the create transition. Please see https://confluence.atlassian.com/adminjiraserver/advanced-workflow-configuration-938847443.html#Advancedworkflowconfiguration-validators.
Best regards, Lukas
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.