Forums

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

Due Date Automation based on status change

kalaimani
Contributor
November 23, 2023

Hello

 

There are four statuses in my task workflow: open, in progress, waiting for confirmation, and done.For this reason, we have to set the default due dates to Open (1 day), In progress (5 days), Waiting for confirmation (2 days), and Done (one day).

For example, the issue's open status and one-day due date were set at the time it was created [23-11-2023].The due date is extended by five days if I change it from Open to In Progress, and I also need to set up other statuses.How should I set up Jira Cloud?

1 answer

1 accepted

2 votes
Answer accepted
Ste Wright
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 23, 2023

Hi @kalaimani 

This will be possible, but can I confirm some queries about the logic?

  • I assume there's an Automation Rule or Post Function that sets the initial due date when the issue is created - is this always the case?
  • What is a due date has been removed - how should the rule handle this?
  • Can a user skip a status (eg. go Open > Waiting for Confirmation)?
    • If yes, what should happen here given the "In Progress" +5 is missed?

Ste

kalaimani
Contributor
November 23, 2023
  • Yeah Ok. It works in Post Function also?
  • Yes that is my question 
  • Yes,If the status changes to a new status, the due date must be extended based on my days.
Ste Wright
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 23, 2023

Hi @kalaimani 

No need to accept the answer until you have the response you need :)

You've not directly answered my questions - it'd be good to get these responses. Otherwise the rule will be possible to build, but I anticipate it'll have flaws in its logic.

Another question is:

  • Can a user move back a status? If yes, what should happen in that scenario (eg. In Progress > Open)

Ste

kalaimani
Contributor
November 23, 2023
  • No, the workflow is only Open->In Progress->Waiting for Confirmation->done.So the user will not come back.
  • If the issue was created Open [23-11-2023] and the status was moved to In progress the Due date needs to automatically set Business days[30-11-2023] and In progress to Waiting for confirmation [04-12-2023].Hope now its cleared.
Ste Wright
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 23, 2023

Hi @kalaimani 

Great! In your case, you can actually manage both rules (set initial due date and set status-based due dates) in the one rule - it will look like this:

  • Trigger: Multiple Issue Events
    • Events = Issue Transitioned, Issue Created
  • Condition: IF Block...
    • IF...
      • Sub-Condition: Issue Fields Condition
        • Field = Status
        • Condition = equals
        • Value = Open
      • Sub-Action: Edit Issue
        • Field = Due Date
          • Value = {{now.plusBusinessDays(1)}}
    • ELSE-IF...
      • Sub-Condition: Issue Fields Condition
        • Field = Status
        • Condition = equals
        • Value = In Progress
      • Sub-Action: Edit Issue
        • Field = Due Date
          • Value = {{issue.Due date.plusBusinessDays(5)}}
    • ELSE-IF...
      • Sub-Condition: Issue Fields Condition
        • Field = Status
        • Condition = equals
        • Value = Waiting for Confirmation
      • Sub-Action: Edit Issue
        • Field = Due Date
          • Value = {{issue.Due date.plusBusinessDays(2)}}
    • ELSE-IF...
      • Sub-Condition: Issue Fields Condition
        • Field = Status
        • Condition = equals
        • Value = Done
      • Sub-Action: Edit Issue
        • Field = Due Date
          • Value = {{issue.Due date.plusBusinessDays(1)}}

---

A few notes...

  • I'd consider if this is needed on the transition to Done - isn't the issue complete at that point?
  • This rule uses multiple date and time smart values, see how those work on this help page

Let us know if this works for you!

Ste

kalaimani
Contributor
November 23, 2023

Hi @Ste Wright 

Yes, it is what I needed, and it worked. Thank you! 

 

  • Suppose if one status like Waiting for confirmation there was no time limit so what should we do ?
Like Ste Wright likes this
kalaimani
Contributor
November 23, 2023

Got It .{{issue.Due date.plusBusinessDays()}} the Due date come now None.

None Due Date.png

Ste Wright
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 23, 2023

Hi @kalaimani 

Glad it's working!

You could also just leave the field empty in the rule, and that counts as NULL.

Ste

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