Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How can I set Target Start to present day?

Julia
Contributor
November 1, 2021

I AM ON JIRA SERVER

I want to set the value of Target Start to be the present day, but this JSON is returning an error saying the value has to be a string. Anyone can help? 

Screen Shot 2021-11-01 at 8.58.21 AM.png

4 answers

1 accepted

1 vote
Answer accepted
Darryl Lee
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 1, 2021

So... this may just not be possible:

As @John Funk wrote back in Nov 2020:

This is the second time in a couple of weeks where people are having trouble in Automation with the Target Date. It "seems" to be a typical date field type, but it doesn't behave as one when using Automation. 

And @Bill Sheboy found:

According to this Code Barrel ticket, the Portfolio and Advanced Roadmap fields are not supported yet:

https://codebarrel.atlassian.net/browse/AUT-1370

Alas, that Improvement request still appears to be open. :-{

Darryl Lee
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 1, 2021

Same ticket in Atlassian's system: https://jira.atlassian.com/browse/JIRAAUTOSERVER-159

0 votes
Rick Dorgan January 18, 2024

I wrote a rule to update the target start when a ticket transitions from To Do -> In Progress, which works perfectly. Hooe this helps. Here's the custom JSON: Screenshot 2024-01-18 at 11.04.15 AM.png

{
"fields": {
"Target start": "{{now.jiraDate}}"
}
}

0 votes
Pablo de Dios May 5, 2022

Hello the attr for the field "Target date" is "customfield_11001" you can export to XML any Epic or Task and check this...

0 votes
Julia
Contributor
November 1, 2021

Also, it is a locked custom field. This custom field is created and required by Portfolio for Jira.

Darryl Lee
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 1, 2021

Looks like "Target Start" is just a date (without a timestamp)? Maybe try:

{{now.jiraDate}}

Some other functions you might try are here: https://confluence.atlassian.com/automation/date-and-time-functions-993924864.html 

Julia
Contributor
November 1, 2021

I just tried that and got the same error.

Here is the error I am receiving: 

"(Operation value must be a string (customfield_14202))"

Darryl Lee
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 1, 2021

It would be helpful to do some debugging to see what an existing value looks like (to Automation).

So I would create a new rule with a Manual Trigger that doesn't do anything but do a Log action with a message of:

Target Start: {{issue.customfield_14202.value}}

And then manually trigger the rule from an issue that already has Target Start set, then look at the Audit log for this new rule to see what a "valid" value looks like.

I suppose you might also try:

{{now.toString}}
Julia
Contributor
November 1, 2021

@Darryl Lee 

I tried that, and the Target Start is set on the ticket, but the audit log shows up empty. Photos attached. Screen Shot 2021-11-01 at 12.37.04 PM.pngScreen Shot 2021-11-01 at 12.36.56 PM.png

Darryl Lee
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 1, 2021

I guess I would also try seeing if you get anything for these Smart Values:

{{issue.Target Start}}

{{issue.Target Start.value}}

{{issue."Target Start"}}

{{issue."Target Start".value}}

Darryl Lee
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 1, 2021

Oh and also: {{issue.customfield_14202}}

Julia
Contributor
November 1, 2021

@Darryl Lee 

{{issue.customfield_14202}} worked and returned this value

2021-11-02

 

How do I take this information and move forward with configuring the automation

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events