In this video we’re going to expand on our existing workflow and we would like to see that after the status has changed to accepted, the client will receive an e-mail.
I want to delay by two days and if the status is still accepted the system needs to send another e-mail.
If the status is anything else but accepted, it should do nothing.
At the end of our workflow we can add another task and I’m looking for a delay.
I’m going to choose delay by 2 days, add a task.
We can set how long the delay should be.
Our delay has now been set up.
We switch it on.
I would like to find out after the two days what is the current status of that client.
In order to do that I need to create a match to client task to find the current existing status of this client’s field.
If we go back to the first match to client task which we use to find the contact we can see the the existing state of the customer.
We do have the status ID, which is 2, so we need to find out what 2 is.
We can go back to the client, to Sylvie or any of the clients, right click and edit custom fields, add client status.
If we edit, we can see that there are certain IDs associated to these fields.
We know that accepted is status ID #2. I’m heading back to our workflow.
To match the client.
This window has matched so I switch it on and add an if statement.
If statement is if still accepted after two days.
We need to set up our if statement.
I’m going to be using our latest match to client task and looking for client status ID.
So if the ID contains 2 which is accepted.
When we run this task it shows true.
So we say that if statement works and then only if it’s true after two days send another e-mail.
We open up the e-mail task and send it again from Peter Pan.
We find the client ID in any of the match to client tasks or in the status change trigger.
If we go to match to client, the client ID is going to pull this through as well.
I’m sending it to the same client.
I navigate to the get contact task, we’re going to send it to that client and I would like to write a custom e-mail.
Hey there, I see you have not moved.
Here is our e-mail task that we’ve set up and I’m going to switch it on.
Every time a status changes, this workflow will create audit trail workflow notes so that you can see what has changed.
If changed to accepted, it matches to the client to pull the contact IDs to get the contact, which we can then send an e-mail.
It will delay for two days.
If the status is still accepted after two days, it’s going to send a second e-mail.
Let’s try that.
Let’s go to Sylvie.
I’m going to change the status to declined just to rerun our experiment.
What we should see is a normal workflow note that comes up to show what has changed, but I’m going to now change it to accepted to test our automation.
What we now expect to see is a work limit that says that it was changed from declined to accepted and an e-mail to be sent to the client.
Our e-mail has been sent.
If we go back to our workflow, if I look for my latest data record, I can see that this is where we are in the process.
It has processed everything.
It’s sent the e-mail, but now the system is waiting for two days before it continues with the rest of the process.
This is how you expand on your workflow to achieve bigger automations for what you need.