on ā2014 Nov 19 8:03 AM
Hi All,
I have table to which I am binding data. Also there are 4-5 filter which I am applying on table.
Everything work well but now condition is that, there is one Column name "STATUS". While binding data I don't want status with value "A" to get binded to table.
so I add filter as
var aFilter = [];
aFilter.push( new sap.ui.model.Filter("STATUS", sap.ui.model.FilterOperator.NE, "A"));
which is working fine.
now there is one more filter which is user define. so that when user select particular status only that rows should get bind to table
so I add one more value as
aFilter.push( new sap.ui.model.Filter("STATUS", sap.ui.model.FilterOperator.EQ, "B"));//Where B= user selected status
but this is not working. As both filter filter are on same column called "STATUS"
But when I remove first filter("A") then 2nd filter("B") filter work perfectly.
how can I add multiple filter on same column.
Such as I want STATUS != "A" AND STATUS = "B"(user define status)
Any help is appreciated
Thanks in Advanced.
Request clarification before answering.
create a new filter which will perform AND on the aFilter array,
var combinedFilter = new sap.ui.model.Filter(aFilter, true); // true --> AND
JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.ui.model.Filter
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 9 | |
| 5 | |
| 4 | |
| 4 | |
| 4 | |
| 3 | |
| 3 | |
| 3 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.