Skip to main content

When trying to deploy an event calling a workflow i get the following error : 

 

When looking at the event, i have : 

 

If deploying the event in Validation type i do not have this issue.

I think the errorMessage is not compatible with the processEnrichment workflow type.

 

How to deploy a process enrichment with error message to show to user please?

 

Thank’s in advance

Hi ​@IFSRUNINNOVAL ,

What are you trying to archive? can you give a bit more context?

in theory, If an ifs failure event type element is used that can only be used with a Validation type workflow. The error is consistent with trying to deploy such a “validation workflow” as a process enrichment workflow 


@kamnlk thank you 

I am working on deploying calculations for a loyalty program. When adding a customer discount, the workflow is triggered, and based on specific criteria, the user will either be able to apply the discount or receive a blocking message explaining why the discount cannot be applied.

 

How can I display a message to the user when utilizing a process enrichment type?


Hi ​@IFSRUNINNOVAL,

From what you explained this seems to be a use case for a validation workflow 

Validation Workflows are designed to conditionally prevent a user from completing an action within the system

ref:What are Workflows? - Technical Documentation For IFS Cloud

 

 

How can I display a message to the user when utilizing a process enrichment type?

not a direct way but I can say there is an approach mentioned on another community post how to show custom error messages in workflow? | IFS Community


@kamnlk the link says :

Process Enrichment Workflows provide the functionality where data is required to be created, altered or deleted.

 

Will i be able to add/delete/modify data when using the validation type please?


hi,

Yes you should be able to do add/delete/modify data when using the validation type. But as a practice try not to do too much complex logic inside the validation workflow 

 

Alternatively, you can also split the workflow into two separate workflows. one for validation logic and one for the process enrichment logic. both set to be triggered for the same event/projection action. in that case you can separate the concerns properly


@kamnlk thank’s.

How to pass values from one workflow to another to make sure that the tests are correct?

Would the validation abort the second event if the tests are not OK?


Yes, if both workflows are triggered due to the same event, The validation wf will cause the 2nd workflow to abort as well if the tests fail 


@kamnlk thnak’s i’ll try that


Reply