Filter builder
OFilterBuilderComponent
Directive: o-filter-builder
Component hierarchy
- o-filter-builder
- o-filter-builder-menu
Inputs
Name | Since | Description | Default |
---|---|---|---|
attr string |
| Field identifier. Registry property if component is inside a form. |
|
expression-builder (values: Array<{ attr, value }>) => Expression |
| Funtion called for creating the expression. The function receives an array of objects that contains the target column attribute and the value of the respective form component and must return an instance of |
|
filters string |
| List of pairs of target component colums and form component attributes. Separated by ‘;’. Example: “targetColumn1:componentAttr1;targetColumn2:componentAttr2”. |
|
query-on-change yes | no | true | false |
| Indicates whether or not to trigger the target component refresh when a filter component change event is fired. You can define the change event in attribute | no |
query-on-change-delay number |
| Delay time in milliseconds | 0 |
query-on-change-event-type onValueChange' | onChange |
| If query-on-change-event-type is | onValueChange |
target OServiceComponent |
| Component whose that will be filtered. |
|
Outputs
Name | Since | Description |
---|---|---|
onClear | Event triggered when the clear action is excuted | |
onFilter | Event triggered when the filter action is executed |
Methods
clearFilter |
---|
Clears the form fields used by the filter builder to create the filter. |
getBasicExpression |
---|
Returns an `IBasicExpression` object with the filter. |
Returns |
The `IBasicExpression` object with the filter. |
getExpression |
---|
Returns an `Expression` object with the filter. |
Returns |
The `Expression` object with the filter. |
getTargetComponent |
---|
Returns the filter builder target component. |
Returns |
The target component. |
triggerReload |
---|
Trigger the `reloadData` method from the target component. |
Filter builder menu
Directive: o-filter-builder-menu
Inputs
Name | Since | Description | Default |
---|---|---|---|
icon string |
| Name of google icon (see Google material design icons) |
|
oFilterBuilder oFilterBuilderComponent |
| Indicates which filter creator triggers the action |
|
show-clear-option [yes|no|true|false] |
| Indicates whether or not show clear option in the filter builder menu | yes |
show-filter-option [yes|no|true|false] |
| Indicates whether or not show filter option in the filter builder menu | yes |
svg-icon string |
| Name of svg icon | ontimize:more_vert |