This cannot be done with an issue rule, you need to use a SLA and SLA Target to achieve this.
The example will set issues with status "Message sent" to status "Completed" after 3 work days.
But this setup can be used for changing other issues statuses after specified time as well.
To create actions of this kind you need to create a SLA first.
Follow the steps below:
- First make sure that you have the following fields on your issues:
- If the fields above aren't available on your issues add them in "General" --> "Settings" --> "Issue configuration" --> "Issue fields" (They don't have to be visible but must exist on the issue)
- Go to "General" --> "Settings" --> "SLA settings"
- Create a work schedule (if you haven't done so before), call it default (or something similar), with Monday - Friday work hours of 8-17 (or whatever suits you)
- Create a SLA target
- Set Title/name to "Close after 3 days" (or something similar)
- Set Target to Active
- Set Trigger to "Time in Start or Running statuses more than 24.0 hours" - (three normal work days)
- Check the statuses that should be valid for this SLA target. In this example, only "Message sent" should be in the column "Start or Running", all other statuses should be in column "Stop"
- Set other criterias for your issues, such as :
- Issue type : Support issue
- Save the SLA target
- Edit the SLA target
- Edit the "Projects and escalations" to define what should happen when the SLA Target is triggered, such as:
- Click the checkbox for the project you want to monitor (such as your support / help desk project)
- Click on the "Edit escalations" link on the right
- Add escalation and specify what should happen, such as changing owner or sending out an email
- In the example, we want to change the status to "Completed" when this issue is escalated when the SLA target is breached.
- Save escalation selection and SLA Target
- Create a SLA
- Set Title/name to "General"/"Default" (or something similar)
- Select "Active" checkbox
- Select "Default" checkbox (if this is indeed the default SLA in the project)
- Select the SLA Targets to use, select checkbox for the "Close after 3 days" checkbox created above
- Click Save
Now, issues in status "Message sent" will automatically be set to close after 3 work days.
Please note that the SLA monitoring above will only affect new issues created after the SLA/SLA Target has been updated!