I want to display all table records when is there is filter field is empty or blank. Whenever there is value in USER Field, data is getting filtered based on value. Now I want to display all records if USER field is blank or empty. Could you please help. Below is the code
onSettingsSaveBtn: function (oEvent) {
var oModel = this._oSettingsDialog.getModel("SettingsContext"),
oData = oModel.getData(),
user = oData.StoreID;
var aTableSearchState = [];
aTableSearchState = [new Filter("DeliveryStatus", "EQ", user)];
var oBinding = this._oTable1.getBinding("items");
this._oSettingsDialog.close();
if (user === "") {
}
else {
oBinding.filter(aTableSearchState,"Application");
}
}
oBinding.filter([])
should do the trick