Skip to Content
0
Former Member
May 17, 2016 at 11:32 PM

OData filtering a filtered table

85 Views

Hi,

maybe someone can help me a little bit.

I'm filtering an OData-Servive and fill a table with the filtered results by the following controller-function:

setTable: function ($this, $view, sCustomer, sVersion, sHierid, sFiscalYear) {

var sServiceURI = "/sap/opu/odata/xxx/A_0003_SRV";

var oModel = new ODataModel(sServiceURI, true);

$view.setModel(oModel, "oA0003Model");

var oDataFilters = [];

var oTblData = $view.byId("idTableD");

var oBindingData = oTblData.getBinding("items");

oDataFilters.push(new Filter('ApplicationPa', FilterOperator.EQ, 'A'));

oDataFilters.push(new Filter('CustomerPa', FilterOperator.EQ, sCustomer));

oDataFilters.push(new Filter('VersionPa', FilterOperator.EQ, sVersion));

oDataFilters.push(new Filter('HieridPa', FilterOperator.EQ, sHierid));

oDataFilters.push(new Filter('FiscalYearPa', FilterOperator.EQ, sFiscalYear));

oBindingData.filter(oDataFilters);

.......

}

Up to this point, it works fine.

Now I want to be able, to filter this table (with columns: "Unitid | Unitname | Value1 | Value2") again by a standard SeachField placed in a xml-view.

How can I do this ? Because for me, it seems that this would be a filter of a filter ?

Best regards

Achim