How to edit a custom field (date picker type), whenever the issue updates, with the current date?

Deleted user May 19, 2017

I'm trying to set up an automation where:

Every time the issue updates, it would edit the custom field (date picker) and set it to the current date. I know there's already a field like that, but it's not supported by the Zendesk add-on, so I can't map it out.
That's why I need to create a custom field, so I can map it to Zendesk.

Thank you in advance :)

2 answers

1 accepted

1 vote
Answer accepted
andreas
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 21, 2017

Hi Alexander,

There's a couple of ways you can do this.  You can add the date field to the simple form above in the edit issue section and simply use {{now}} as its value.

Or if you're using 'Advanced', then this would work:

{
"fields": {
"customfield_12200": "{{now}}"
}
}

Cheers,

  Andreas

0 votes
Stefan Arnold
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 19, 2017

You could do that in each transition postfunction. But this way you will not get the updated timestamp when someone adds a comment or edits the issue.

I never used Zendesk, but are you sure you cant get the value from issue date modified field?

Deleted user May 19, 2017

Zendesk's add-on doesn't support the "Updated" field :( How would it be possible to do this through the post functions?

I've checked the postfunctions and I couldn't find a way to edit a custom field, only the system ones :/

Deleted user May 19, 2017

I've added the following in an automation, but I guess the syntax is incorrect?

{
"fields": {
"customfield_12200": "Date(now()"
}
}

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events