Hi,
I am new to Jira Automation, I am looking to insert a hard date into my automation code for further manipulation.
How do I convert a hard date within the code?
{{issue.summary.toDate("2022 01 31")}}
{{[issue.dueDate.jiraDate].diff(issue.summary.toDate("2022 01 31")).Days}}My End goal is a formula similar to the following:
Var1: RoundUp [ (([DueDate] - [HardDate] + 1) / 70 ), 0]
Var2: RoundDown [ ( (Var1 -.01) /5),0 ]
Then to have a logic tree that:
If Var1 < 6
Then: "22."& Var1
Else: 22 + Var 2 & "." [Var1 - (5*Var2)]
Then to have a second logic set that does the same as above except divides Var by 14 and an end formula of:
Var1(14)/[Var2(14)*5]
Ultimately, I am syncing Jira/Jira Align TargetStart/Due dates, and trying to store the PI & Sprint info as Integers in a field to build further logic on.
Hi @jeffrey.schrik -- Welcome to the Atlassian Community!
Perhaps try storing the fixed date using Create Variable, in the format yyyy-mm-dd and explicitly convert to date type when needed:
{{varMyFixedDate.toDate}}
IMHO, there are some limitations to where created variables can be used:
If you get stuck on implementing your use case please post images of your rule and audit log details so the community can help. Thanks!
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.