How to Automatically Manage Workflows on Related Objects in M-Files

Introduction

Document management platforms like M-Files offer immense potential for streamlining business processes, especially when it comes to automating repetitive tasks that otherwise consume valuable time.

One such example in M-Files is changing workflow states on related objects.

Manually finding all related objects and changing their workflow states can be a tiresome and time-consuming task, not to mention the possibility of overlooking some objects.

Fortunately, you can automate this process with an appropriate add-on, such as Extension Kit.

One of the powerful capabilities of Extension Kit’s Property Operations module is that you can manipulate the properties of other objects. This means you can also manipulate other object’s workflows. For example, based on a trigger on one object, you can automatically change the workflow states on all related objects.

Through this blog post, you’ll learn how to set up an automatic change of a workflow state on related objects using Extension Kit’s Property Operations. We’ll walk you through the configuration on a specific use case scenario.

Let’s get started.

Automatically change workflow states on related objects

In M-Files, workflows represent a document’s (or other object’s) lifecycle, comprising different states such as In Review, Approved, Finalized, etc.

There are cases where object types are related to one another, having codependent workflow states. So when one object’s state transitions to another, the states of related objects should change, too.

Let’s delve into the example where the trigger event of one object type initiates a change in another object type.

Use case

Consider a scenario where M-Files serves as a CRM system.

Before sending an offer to a customer, a user creates opportunities within the platform. When the customer accepts the offer, the user manually transfers the state of all opportunities related to the accepted offer to Won. Manually managing these transitions can be time-consuming and prone to errors.

However, using Property Operations, such processes can be automated. So here we want to automatically change the state of all related opportunities to Won.

Configuration

We’ve created a rule in the Property Operations module, stating that all opportunities related to the accepted offer should transition to the state Won: “Set Opportunity to Won when Offer is Accepted.” For this rule to work, each document in a class Offer must have a property Opportunity, as it will be the referenced property. The configuration mode here needs to be advanced.

First, we define the trigger type and trigger source (Picture 1):

  • The trigger type is Object entered state because we want to react when the offer is in the state Accepted.
  • For the trigger source, we specify the object type (Document), class (Offer), workflow (Offer), and state (Accepted).
Define the trigger type and trigger source.
Picture 1: Define the trigger type and trigger source.

Then we need to define the target (Picture 2).

  • In this case, we need to find targets via property because we want to find the target via Opportunity property. Selecting ViaProperty means that Extension Kit will look for a reference.
  • To find the opportunity via reference, we set the reference to Opportunity.
  • After that, we define properties to copy on the reference object. Here we set the property State to the specific static value Won, and we take the value from Source.
Define the target.
Picture 2: Define the target.

And this is it. All the opportunities related to the accepted offer will automatically move to the state Won, and the user no longer needs to do it manually.

Configuration Overview

  1. Open M-Files Admin.
  2. Open Document Vault → Configuration → Extension Kit → Property Operations.
  3. Set Configuration mode to Advanced.
  4. Choose Object entered state as Trigger.
  5. Specify Trigger source.
  6. Under Target, choose Find targets ViaProperty.
  7. Set Reference to Opportunity.
  8. Under Properties, define State: Property = State, Value from = Source.
  9. Under State, define Value: Mode = Static value, Static value = Won.

User’s Perspective

We’ve set up another example to show how this configuration works in M-Files from a user’s perspective.

  • Here we have objects New offer for video and a Demo opportunity for video. Opportunity is now in a state New.
Opportunity is in the state New.
  • When we move the Offer to the state Accepted, you can see that the Offer is in a workflow Offer in a state Accepted, meaning that this will now trigger the Extension Kit rule.
Offer is Accepted.
  • After the rule execution, you can see that the Opportunity is in the state Won.
Opportunity is in the state Won.

Conclusion

Minimizing manual interventions and automating repetitive tasks within your document management platform represents a step up in enhancing business efficiency.

Automating tasks in M-Files with Extension Kit not only enhances accuracy but also frees up valuable time for more strategic activities.

This blog post has provided insights into the setup of automatic workflow state changes on related objects within M-Files, using a specific use case as an example. Configuring such a rule with Extension Kit’s Property Operations module is simple, requiring no coding expertise.

Extension Kit expands the possibilities of M-Files and enables more use cases. If you’re interested in how it can simplify and accelerate your M-Files implementation, sign up for a free trial and download our demo vault to experience Extension Kit firsthand.

You can also watch the entire configuration in this video:

Schedule a consultation

Let’s talk about the ways we can help your business thrive. 

WATCH THE WEBINAR

Introducing AI Document Kit: Add-on for AI-driven Document Management