All product information in wiki.bizagi.com is only valid for Bizagi BPM Suite 9.1.X.
For newer Bizagi BPM Suite versions (10.X and up) please visit the User Guide.
 

Application Expressions

From Business Process Management, BPM and Workflow Automation Wiki | BizAgi BPMS

Jump to: navigation, search

Applies to ENTERPRISE .NET EDITION

<keywords content="keywords">organize, reuse, reutilize, expression, application</keywords>

Contents

Application Expressions

Application Expressions are those that are created for an entire application. This allows the user who is designing to utilize the expression from a specific application in any of the processes and subprocesses that form part of the application.

Using expressions classified as Application is important because it saves time when the project is being designed and when the application is being maintained. Users are only need to create one expression that they will use more than once in an application, and then they will only require to associate the existing expression where it is required. Maintaining this type of expressions will also be helpful because instead of modifying multiple expressions in multiple instances, the user will only make the change in one expression and the change will be reflected in every instance the expression is used.

How to create an Application Expression

Application expressions can only be created from the modules view. The following video will show the procedure.

<videoflash>AV0kD28AA1I&hl|640|505|</videoflash>

Application Expression Example

The Administrative Application has a group of processes that execute purchasing requisitions. According to the types of products that might be requested by employees of the company, a purchase requistion may be classified as a requistion that is a sole source purchase or not. A sole source purchase indicates that the supplier for that requisition is already determined and no quotations and selection process is required.

In the Administrative application an expression that determines if the case is a sole source purchase or not is often required in most, if not all, of the processes related to Purchase Requisitions. This expression is often going to be used to define properties and conditions for fields in the forms and to determine sequence flow paths in the processes.

In this example we will create a Boolean expression that will return True if the requisition is a sole source purchase and False otherwise.

To create this expression follow these steps:

1. Once you are in Bizagi Studio in the main wizard click on the Module button.



2. In the new window click on Business Rules in the left panel and then select the application where the expression will be created. In this case Administrative. Open the subgroup under the selected application and click on the option Expressions.



3. Right click on the family where you would like to create the expression, and select New Expression. If the expression does not go under any family, just right click on Expressions and select New Expression.



4. A New Expression Wizard window will open. Select the type of expression that will be created. In the current example, the expression is only meant to return True or False, so Boolean will be selected, and then we will click on the Next button.



5. An expression that will return True when the case is a sole source purchase must be included using attributes from the left box and dragging them to the right If box.



6. The only attribute that will be needed is Sole Source Purchase which is under the application entity Purchase Requisition. This attribute should be dragged to the first box that reads "insert a value".



7. Then using the drop down lists in the following boxes complete the expression so it looks like the image below.



8. Click on Properties to complete the basic information of the expression, name, display name and description. Then click on Finish.


9. The expression will be visible within the family (if used) in which it was created.



10. Before we associate the expression to the process, this is how the web application should look when a user consults a case. As you can see, this case is not a sole source purchase and so it is showing the Supplier Information without any information in it. To correct this we need to go to the form and include the expression we just created as a visibility rule for the whole group.



11. The form we were verifying in the web application is the Global Form of the Purchase Requisition Process. If you already know the name of the Global Form of the Process go to step 14. To find the name of the Global Form go to Processes in the left panel, and then select the application, in this case Administrative, and the process, in this case Purchase Requisition. Now right click on the active version of the process.



12. Click on Properties.



13. In the Process Properties window we can observe that the name of the form we will modify is GlobalFormPurchaseReq. Once you have the name click on Cancel.



14. Go to Entities in the left panel and then select the Application entity and select the option Forms. There you must search for the Global Form of the process Purchase Requisition. Double click on the form.



15. The Bizagi Form Modeler window will open. right click on the Supplier Information group. First select the Visible option, and then select Expression.



16. In the Boolean Expression window, click on Cancel to select an existing expression.



17. Open the Application group, then open the family group where the expression was created (Purchase Order), and then select the expression Is Sole Source Purchase? Then click OK.



18. Now that the expression is associated to the process, we can test the results in the web application. When a case that is not a Sole Source Purchase is checked the Supplier Information is no longer visible.



19. One of the advantages of Application Expressions is that the same expression can be used in other processes within the same application. Include the expression in the Quotations process which is also part of the Administrative Application. The Sole Source Purchase expression will be part of the first exclusive gateway in the process. Go the the Process Wizard  and select the Fourth Step: Define Expressions.


20. Go to the Transition where the rule will be required. In this case, if it is a sole source purchase, the quotation process should end.Select the arrow pointing to the End Shape and select the Expression. (Click on Cancel to close the new window and choose the correct one)



21. Click Cancel to select an existing expression.



22. In the Application section, select the Expression we created at the beginning of the example, Is Sole Source Purchase? Then click on OK.



Related Articles

Expressions

Expression Family

Global Forms

Global Expressions

Process Expressions

Default Expressions


<comments />