Controlling Visibility of UI widgets

0
hello i started using mendix just last week and coming from a different platform (Oracle ADF) I want to control visibility, I thought I can define a variable in a microflow and set a boolean to it.  Then somehow make this variable exposed so it can be used in the visibility property.  Am i thinking in the correct line? The variable that determines the visibility is not dependent on the data model directly. For example, if the JOB of an employee is MANAGER is want to hide the SALARY? Therefore, i created a variable in a mircroflow, then set the value of the variable to true or false depending on the value of JOB.  On the textbox i want to hide, i tried to set visibility based on expression,  but i could not find the Variable Name!  can i extend the scope of the variable  beyond the microflow.     help please      
asked
1 answers
0

Ammar,

No, you can’t extend the scope of microflow variables – these variables exist only within the microflow.

If JOB is an attribute of EMPLOYEE, you can control visibility via an expression, like this:

Otherwise, you can

  • add an attribute to the entity to control visibility
  • control visibility via user roles
  • create different pages for Managers and Employees
  • use one of the widgets in the appstore like Show By Condition

and there are probably other ways to accomplish this that I am not thinking of now.

Hope that helps,

Mike

answered