YouTrack Standalone 7.0 Help

Due Date

This workflow helps you set deadlines for resolving issues.

File Namejetbrains-youtrack-dueDate
Auto-attachedno
RulesDon't allow to submit issue without Due date set (stateless)
Notify assignee about overdue issues (schedule)

Use Case

This workflow requires that every reporter sets a due date for resolving an issue and notifies the assignee when an issue is overdue.

To use this workflow, you should either add a Due Date field to your project or create another date-type field and modify the reference to the Due Date field in the default workflow.

This workflow was originally taken from a submitted request (JT-5998).

The user who submitted this issue wanted to make a field required for all new issues so that it could be used as the basis for a report.

Rules

The first rule prevents the creation of an issue unless the due date is set. If the Due Date field is empty, a warning is displayed.

Don't allow to submit issue without Due date set

First, the rule verifies that the issue has not been reported. This means the warning is displayed when the user is still creating the issue or working with an issue draft. If true, it checks for a value in the Due Date field with the required method.

  • If the Due Date field is empty, a warning is displayed. The required field is highlighted. The user cannot create the issue.
  • If the Due Date is set, the user can create the issue.
rule Don't allow to submit issue without Due date set when !isReported() { Due Date.required(l10n ( You must set the Due date! )); }

Notify assignee about overdue issues

The second rule checks the value in the Due Date field at 10:00. If the issue is overdue and unassigned, notification is sent to the Project Lead. If the issue is assigned, notification is sent to the assignee.

schedule rule Notify assignee about overdue issues daily at 10:00:00 [now > issue.Due Date] { if (!isResolved()) { var user; if (issue.Assignee == null) { user = issue.project.leader; } else { user = issue.Assignee; } user.notify(l10n ( [YouTrack, Issue is overdue] ), l10n ( Issue became overdue on <i> {Due Date.format(mediumDate)}</i>: <a href=\" {getUrl()} \"></a> <a href=\" {getUrl()} \"> {summary} </a><p style=\"color: gray;font-size: 12px;margin-top: 1em;border-top: 1px solid #D4D5D6\">Sincerely yours, YouTrack</p> )); } }
Last modified: 2 February 2017