Skip to Content
Dec 13, 2013 at 09:17 PM

Problem with filter


I have a list of employees that I'm trying to filter based on a department id. I've used the following statement in the createContent function to create the filter:

var oFilter1 = new sap.ui.model.Filter("department", sap.ui.model.FilterOperator.EQ, "100");

The app runs fine without this line except that it doesn't filter the employee list. However, when I insert this statement the app displays nothing and in Chrome I get the following error on the filter statement:

Uncaught TypeError: Cannot read property 'EQ' of undefined.

Any ideas would be greatly appreciated.