Abstract / Use Case
In some cases it makes sense to show or hide smartcontainers underneath objects or to activate or deactivate functions for objects.
The requirements for such use cases are different in projects / from customer side.
For that reason there are configuration possibilities to build up such functionalities via configuration.
General definition of object filter
An object filter compares a property or status of an passed object with the given value und returns:
|true||Object property fulfills the filter operation|
|false||Object propertiy does not fulfill the filter operation|
|null||Object does not support the defined property|
A filter definition consists of following parts:
obr.filter.<FILTER_NAME> = <OTYPE>;[PRP | FLG];<PRP | FLG_NAME>;<DATA_TYPE>;<VALUE>;<OPERATION>;[INVERT]
The integration of the filter in ECTR is based on the filter name.
name of the Filter
|<OTYPE>||Defines the object type of the filtered objects|
|[PRP | FLG]||Defines if the filter processes a status flags or a property|
|<PRP | FLG_NAME>||The name of the property / status flag. If no specific object type is defined, it is also possible to tose the keyword $OBJECT_TYPE to filter specific object types|
|<DATA_TYPE>||The data type of the property / status flag|
|<VALUE>||The value to compare with the property / status flag. It is possible to use defined keywords.|
|<OPERATION>||Either a logical comparator or comparison by regular expression.|
|[INVERT]||Optional Parameter that inverts the result when set|
my_filter_1 will return true if the property object type of the object equals "MAT".
Object filter for smartcontainer and functions
Through configuration of an object filter it is possible
- to hide or show a smartcontainer underneath of a referenced object, depending on properties of the referenced object
- to deactivate or active a function for an object, depending on properties of the referenced object
Object filter for smartcontainers
There are two possibilities to use an object filter for smartcontainers.
plm.smart.container.<CONTAINER_NAME>.includeFilter = <FILTER_NAME>
Using an include filter, the smartcontainer is only visible, when the filter evaluation returns true
plm.smart.container.<CONTAINER_NAME>.excludeFilter = <FILTER_NAME>
Using an exclude filter, the smartcontainer is only visible, when the filter evaluation returns not true (false or null).
The Smartcontainer for Assigned Change Numbers (ASGND_ECN) is hided, when there is no value for property CHANGE_NUMBER.
Object filter for functions
There are also possibilities to use an object filter for functions.
The object filter can used directly in combination with the function:
obr.filter.<FUNCTION_NAME> = <FILTER_VALUES>
The function "Open for Edit" is deactivated when the value for property STATUS is "FR".