Hide Workorders if there aren't any

If you use the “Create Work Order” functionality in Forms to allow users to report problems, you might want to show that there are active problem reports.
Or you might want to hide that info if there are no error reports.
We have now added variables that allow this.

Before the fix, the button (=Function) for error reports (Felanmälningar) was visible with (0):

After the fix:

The magic is in the use of Rules:

…and the Work Order variable: $var:workorders.object_activetotal$
NOTE: YOU NEED TO ADD A VARIABLE WITH VARIABLE TYPE WORKORDERS IN ORDER FOR THIS TAB TO APPEAR.

…and setting the rule to only show the function if there are more than zero work orders:

When there is a problem report, the button will appear: