On this page
Use case
Update a number field with the difference in days between two dates obtained from two Date Picker fields.
Prerequisites
Configuration
Target issue*
Select current issue
Fields
Field*
Select Time Difference, the field previously created
Value*
Select Set field value manually (parser expression) and enter the following expression:
((new Date(issue?.customfield_10043 + "T00:00:00").getTime() - new Date(issue?.customfield_10040 + "T00:00:00").getTime())) / 1000 / 60 / 60 /24
Replace the field codes of the expression with the ones of your Date Picker fields.
Related use cases
If you still have questions, feel free to refer to our support team.