Forums

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

Automation to divide date custom field based on actual efforts in percentage

Sattar Baig August 16, 2023

Hi Team,


I am using Automation in Jira Cloud for my project purpose. Could you please on below requirement:

 

1) I have date custom field Planned Live date, Actual effort in percentage(number), Actual effort in days(number) and status (single select list) with Values Red, Orange, Green and would like to create Automation rule for same.
2) I am facing issue to create Automation rule using smart values for below requirement:

  • if Jira issue crossed planned Live date if Actual effort in percentage is b/w 1-19.99%, status must be in Orange.
  • else if Jira issue crossed planned Live date if Actual effort in percentage is 20 to 30%, status must be in Red.
  • else Jira issue completed within  planned Live date if Actual effort in percentage is 0 status must be in Green.

Any help would be appreciate?

 

BR,

Sattar

 

 

1 answer

0 votes
Marco Brundel
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.
August 16, 2023

Hi @Sattar Baig ,

in which part of automation is your problem/question mainly? Are you unable to find the right issues with a JQL filter? Or is it not possible to get the right action to set the status?

For a JQL filter, this might be an option:
("Actual effort in percentage" <= 20 AND "Actual effort in percentage" >= 1) AND "Planned Live date" <= now()

I can imagine that you create a scheduled automation rule that, for example, checks daily. Or a field changed as a trigger.

Regards, Marco

Sattar Baig August 16, 2023

Hi @Marco Brundel

Apologies for my mistake!

 

Based on Planned Go-live date(date field) it can easily divide the value of percentage on Actual effort in percentage (number field) using Jira smart values on Actual effort in Percentage:

{{now.diff(Planned Go-Live Date).asPercentage}}

  • if Planned Go-Live date is 30-8-23, Actual effort in percentage must calculated as 0, status will be green.
  • if Planned Go-Live date is 13-8-23, Actual effort in percentage must calculated as 0-2%, status will be Orange.
  • if Planned Go-Live date is 20-07-23, Actual effort in percentage must calculated as more than 30%, status will be Red.
  • I am facing error when I use below smart value in Automation:

{{now.diff(Planned Go-Live Date).asPercentage}}

Could you please suggest me appropriate automation rule for my issue?

Reference:

https://support.atlassian.com/cloud-automation/docs/jira-smart-values-math-expressions/

Jira smart values - date and time | Automation for Jira Data Center and Server 8.2 | Atlassian Documentation

Please find the attached screenshot for reference:

Automation rule.png Jira Issue.png


BR,

Sattar 

Marco Brundel
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.
August 16, 2023

Hi @Sattar Baig ,

Sorry, I don't see a solution for you right away.

I personal don't understand on what basis you want the percentage. In what situation is it 100%?

And what specific error do you get on the smart value in Automation?

 

regards, Marco

Sattar Baig August 16, 2023

Hi @Marco Brundel

I got requirement from my team they would like to see how much percentage Jira issue got completed like 10%,20% based on Planned Go-Live date(date field). But my team is facing issue they have to enter manually percentage value on Actual effort in percentage field by calculating on their own. Specifically, I am looking for Automation rule for my below requirement:

 

we have below custom fields in my project:

Planned Live date(date field),

  • Actual effort in percentage(number),
  • Actual effort in days(number) and
  • status (single select list) with Values Red, Orange, Green

 

My requirement is:

  • Example: if Planned Go-Live date is 30-8-23, Actual effort in percentage must calculated as 0, status will be green.
  • Example:if Planned Go-Live date is 13-8-23, Actual effort in percentage must calculated as in between 1-20%, status will be Orange.
  • Example: if Planned Go-Live date is 20-07-23, Actual effort in percentage must calculated as more than 20-40%, status will be Red.

 

Could you please help me to how to create automation rule for above requirement?

I have created automation rule for one field Actual effort in Percentage field using smart values in automation

{{now.diff(Planned Go-Live Date).days.divide(100)}}

But automation rule is calculating as 0 and it's not working according to my expectation.

Could you please help with this?

Please find the attached screenshot for reference....

 

Jira Issue.png Screenshot 2023-08-16 180353.png

Yoann LEGRAND
Contributor
August 22, 2023 edited

Hi @Sattar Baig , 


Can you try this  :  {{#=}}{{now.diff(Planned Go-Live Date).days}} / 100{{/}

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
atlassian, atlassian government cloud, fedramp, webinar, register for webinar, atlassian cloud webinar, fedramp moderate offering, work faster with cloud

Unlocking the future with Atlassian Government Cloud ☁️

Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.

Register Now
AUG Leaders

Atlassian Community Events