Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Automation for moving data from custom field to Due Date

Jörg Steinhauer March 30, 2023

Hello,

I'm trying to move data from a custom field to the "Due Date" field for all existing and new issues.

I've created an automation with "Schedule" trigger, which checks for a custom field not being empty:

"Gitlab Due Date (Text)[Short text]" IS NOT EMPTY 

 Screenshot at 2023-03-30 15-02-31.png

The date coming from the Gitlab Due Date (Text) custom field has values like so: 2023-01-31 and is probably of type "text".

 

Then I'm trying to format this date so it can be consumed by the Due Date field, which is of type "date" and is using 01/31/2023 formatting, like so:

 

{{issue.customfield_10143.format("MM/dd/yyyy")}}

Screenshot at 2023-03-30 15-10-56.png

 

Although the Audit log says, its successful, I don't see any entries in the Due Date field.

1 answer

1 accepted

0 votes
Answer accepted
Mark Segall
Community Champion
March 30, 2023

Hi @Jörg Steinhauer and welcome to the community!

You could try this:

{{issue.customfield_10143.toDate.format("MM/dd/yyyy")}}

There's more info here:

https://support.atlassian.com/cloud-automation/docs/examples-of-using-smart-values-with-dates/

Jörg Steinhauer March 31, 2023

Hello @Mark Segall , thank you very much! Actually {{issue.customfield_10143.toDate.format("yyyy-MM-dd")}} did the job, but your advise with toDate was important.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events