Skip to Content

Implementing all the filter to work togather


I need the functionality where the user enters the customer Id, EAN, Category into the multiInput and the filter should filter the tuples satisfying all the user entries togather and my filters are working individually currently. also I should remove or add further filtersgroups.

<fb:FilterGroupItem groupName="__$INTERNAL$" name="c" label="Customer ID" id='idCustomer' partOfCurrentVariant="true" visibleInFilterBar="true">


<MultiInputtype="Text"placeholder="Enter Customer id" showValueHelp="true" valueHelpRequest="onF4Help"></MultiInput>



<fb:FilterGroupItem groupName="__$INTERNAL$" name="e" label="EAN / UPC" id ="idEan" partOfCurrentVariant="true" visibleInFilterBar="true">


<MultiInputtype="Text"placeholder="Enter EAN / UPC" showValueHelp="true" valueHelpRequest="onF4Help"></MultiInput>



<fb:FilterGroupItem groupName="__$INTERNAL$" name="ef" label="Category" id = "idGroupName" partOfCurrentVariant="true" visibleInFilterBar="true">


<MultiInputtype="Text"placeholder="Enter Category" showValueHelp="true" valueHelpRequest="onF4Help"></MultiInput>



And corrosponding to its controller.js file i have written as...

Like for customers input checking...

if (customer != '') { var oFilter1 = new sap.ui.model.Filter( "customer", sap.ui.model.FilterOperator.Contains, customer); oTableSearchState.push(oFilter1); };... same for rest of 3's input boxes...


var oFilter3 = new sap.ui.model.Filter( "customer", sap.ui.model.FilterOperator.NE, customer ); if (oTableSearchState.length == 0) { oTableSearchState.push(oFilter3); };

var oFilter = new sap.ui.model.Filter({ filters: oTableSearchState, and: false });

I am also popping dialog box for selecting more then one input from multiInput that user is entering ...

fieldId: "",

cityPopup: null,

supplierPopup: null,

onF4Help: function(oEvent){

this.fieldId = oEvent.getSource().getId();

if(this.cityPopup === null){

this.cityPopup = new sap.ui.xmlfragment("sap.ui.demo.worklist.Fragment.CustomerInputDialog", this);

var oSorter = new sap.ui.model.Sorter('customer');


path: "REPGR>/repgr", sorter: oSorter, template: new sap.m.DisplayListItem({

label: "{REPGR>customer}", value: "{REPGR>Product_Ean}", info: "{REPGR>Product_Ean}"

}) });





Your help is awaited..

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

0 Answers

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.