Advanced Workflow
Description
Plugin for flexible configuration and automation of business processes. It allows you to configure and automatically execute complex scenarios that go beyond the standard Redmine workflows. And the flexible "Custom Rules" system allows you to set specific restrictions.
Key Features
- New custom field format: "Date and Time"
- Custom Rules
- Automatic Actions
Compatibility
Redmine: 5.0 - 6.1
Web Browsers: Chrome, Firefox, Safari, Edge
Databases: MySQL 5.7, MySQL 8.0, PostgreSQL 14-16, SQLite
Plugins: redmine_kanban, redmine_advanced_checklists, advanced_charts, appearance_custom, module_manager, periodic_reminder, user_group_editor, queries_perfect, selectbox_autocompiler, cost_calculator.
Installation and Update
- Remove the old version of the plugin from Redmine, if it exists.
cd redmine/plugins rm -r advanced_workflow - Copy the new
advanced_workflowplugin folder toredmine/plugins/ - Run migrations in the Redmine root directory
bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=advanced_workflow - Stop and start Redmine. (In some Redmine installations (e.g., in Docker), it is important to stop and start the server, not just restart it.)
Removal
- Execute the deletion command in the Redmine root directory
bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=advanced_workflow VERSION=0
- Remove the
advanced_workflowplugin folder fromredmine/plugins/
rm -r advanced_workflow
- Stop and start Redmine.
Configuration
-
Configure user roles under Administration -> Roles and Permissions.
-
Enable the "Advanced Workflows" module for projects in each project's settings.
-
Check and modify other plugin settings under Administration -> Modules -> Advanced Workflows.
Administration
Section "Roles and Permissions"
- Manage project-level rules - Access to edit rules and actions within the project.
Section "Custom fields"
The Advanced Workflows plugin adds a new custom field format "Date and Time"


"Date and Time" can be used as a filter (condition)

Available options:
- Next hour - The filter includes those issues where the "Date and Time" field value falls within the next hour from the current UTC time.

Section "Modules"
In Administration -> Modules -> Advanced Workflows you can configure:
-
Run as user - Ability to select the administrator on whose behalf the actions will be performed according to the schedule
-
Maximum number of issues when performing scheduled actions

Section "Custom rules"
Custom rules allow you to set restrictions on issue assignment for users under specific conditions.
In Administration -> Custom rules you can create and configure rules:

Creating a rule
When creating, specify the name and activity:

Editing rules
After creating a rule, the ability to edit conditions and restrictions appears.

Possible Conditions:
-
Project
-
Tracker
-
Version
-
Author
-
Current user
-
Assigned to group
-
Author group
-
Assigned to role
-
Current user's role
-
Issue status
-
Parent issue tracker
-
Parent issue version
-
Custom fields "Issues" with types "List", "Text", "Float", "Integer", "Date", "Date and Time".
-
Custom fields "Projects" with types "List", "Text", "Float", "Integer", "Date".


Possible Restrictions:
- Assignee
- Assigned to group
- Assignee's role
- Due date
- Tracker
- Version

Section "Automatic actions"
Automatic actions allow you to run selected actions when saving an issue or on a schedule, within specified conditions.
In Administration -> Automatic actions you can create and configure Actions:

Creating actions
When creating, specify the name, execution method, and activity.
Actions can be performed in two different ways:
-
On save - actions will be performed instantly when creating/editing the issue.
-
Cron job - rules will be executed periodically according to the cron schedule.

Editing actions
After creating an action, the ability to edit conditions and actions appears.

Possible conditions:
-
Standard issue filters
-
Custom issue filters
Possible actions:
- Assignee
- Disable save
- Send mail
- Status
- Tracker
- Version
- Version of open subissues
- Watchers
- Webhook (GET)
- Webhook Mattermost
- Webhook Telegram
- Checklist (if plugin :redmine_advanced_checklists is installed)


For actions "Send mail", "Webhook (GET)", "Webhook Mattermost" and "Webhook Telegram" action variables are available.

Usage
Enabling rules and actions
After creating rules and actions, you need to separately enable them in the project settings.
To do this, go to:
Project -> Settings -> Custom rules, enable those rules that are needed in this project.

Project -> Settings -> Automatic actions, enable those actions that are needed in this project.

Custom Rules
Available restrictions that will be applied when the conditions are met:
Assignee:
The issue can only be assigned to selected users.

Assignee's group:
The issue can only be assigned to those users who are members of the selected groups.

Assignee's role:
The issue can only be assigned to users with the selected role for the project.

Due date:
The issue due date can only be specified within a given date range.

Tracker:
Issues can only have selected trackers.

Version:
Issues can only have selected versions.

Automatic Actions
Execution method "Cron job"
Actions will be executed periodically according to the cron schedule.
For the automatic action to work correctly, you need to add a new command to the server's crontab, which executes the command bundle exec rake advanced_workflows:run_actions
Command example:
*/5 * * * * cd /absolute/path/to/redmine && redmine bundle exec rake advanced_workflows:run_actions >> /absolute/path/to/redmine/logs/cron_advanced_workflows.log
Add this command to cron on behalf of the user under which Redmine is running, replacing /absolute/path/to/redmine with the absolute path to your Redmine installation folder.
The cron command will run every 5 minutes */5 * * * *
All standard messages will be appended to the file .../logs/cron_advanced_workflows.log
Available actions that will be performed when the conditions are met:
Webhook (GET):
Sends a GET request to the specified URL. Used for integration with external systems, for example, for synchronization with Jira.
Supports all issue field variables.

Webhook Mattermost:
Sends a message to the specified URL in Mattermost format. For integration with Mattermost.
Supports all issue field variables. 
Webhook Telegram
Sends a message to the specified URL in Telegram format. For integration with Telegram
Supports all issue field variables.
Send mail:
Sends an email to specified users or users in groups.
Supports all issue field variables.

Version:
Automatically changes the issue version.
- Replace with the version of the current issue - Replace the issue version with the current (actual) version of the project.

Version of open subissues:
-
Change to - Changes the version of all open subissues to the specified one.
-
Set equal to the version of the issue - Changes the version of all open subissues to the version of the issue.

Disable save:
Disables creating/editing the issue. 
Watchers:
Adds the specified watchers to the issue. 
Status:
Changes the issue status to the specified one. 
Tracker:
Changes the issue tracker to the specified one. 
Checklist:
Available if plugin :redmine_advanced_checklists is installed.
Automatically creates a checklist from templates when the conditions are met.
Use pre-prepared templates. 
If you have any problems or questions, write us an email [email protected]