0
votes

I've a Smart Filterbar in my SAPUI5 application which bind to an entity set.

And I need to filter data which bind to the smart filterbar to display the appropriate suggestion values which related to a specific user.

How to filter the datasource and bind it to the smart filter bar

<smartFilterBar:SmartFilterBar id="filterBar" entitySet="MyEntitySet" persistencyKey="myListFilterBar_Persis" liveMode="true" ></smartFilterBar:SmartFilterBar>
                 
1

1 Answers

-1
votes

You can create custom field in smartfilterbar and set filters in binding params like that

{ path: '/companies', 
        filters: [{path: 'city', operator: 'StartsWith', value1: 'B'},
            {path: 'revenue', operator: 'LT', value1: 150000000}]}

Or you can get in controller bindingcontext of control, set filter and bind to that control again