Forums

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

Automation : timeSpent = timeestimate when subtask is Done

François Kirié June 5, 2023

Hi,

I would like to implement an automation where when a subtask is done, the timeSpent take all the time remaining from this subtask.

I have tried with this and it worked :

...

"add": {
"timeSpent" : "{{timeestimate.divide(60)}}m"
}..

The pbm is when the timeestimate is with 2 decimals, i have an error ... (invalid datetime)

ie : 0.13d (for 1hour)

I think that i missed a time conversion or others .. Any ideas ?

Thanks for your help

1 answer

0 votes
Bill Sheboy
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.
June 6, 2023

Hi @François Kirié 

Would you please confirm what you are trying to do?  Your description notes removing all of the remaining time, but your smart value references the time just logged. 

Please check here to confirm your smart values: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/#--issue.timetracking--

Kind regards,
Bill

François Kirié June 7, 2023

Hi @Bill Sheboy ,

I would like that when a sub-tasks is done, all the estimate time will be consume by automation (so add in the field time spent).

Thanks for your help

Kind regards,
François

Bill Sheboy
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.
June 7, 2023

Given that, would it be better to use {{issue.timetracking.remainingestimate}} when subtracting all the remaining time?

François Kirié June 14, 2023

...

"add": {
"timeSpent" : "{{issue.timetracking.remainingestimate}}d"
}..

 

I have got the same problem using this. It doesn't worked for example with 0.13d (for 1hour) but it worked for example with 1d or 2d.

The error is : Invalid Duration entered (worklog_timeLogged))

It seems to have a conversion problem 

Bill Sheboy
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.
June 14, 2023

You may want to submit a ticket to Atlassian support to learn if this is a known issue, perhaps with a work-around: https://support.atlassian.com/contact/#/

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