从 odata 中获取选择的数据 这是我的代码,我尝试过,但它不起作用
fnRecallsSearch: function() {
var Filters=[];
var sMarca = new sap.ui.model.Filter("Vtext", FilterOperator.EQ, oView.byId("idMarcass").getSelectedKey());
var sPais = new sap.ui.model.Filter("DbmCountry", FilterOperator.EQ, oView.byId("idPais").getSelectedKey());
Filters.push(sMarca);
Filters.push(sPais);
oData.read("/Entitype", {
filters:Filters,
success: function (result, data) {
// result.results.unshift({"Matnr":"", "Vtext":""});
var jModel = new JsonModel(result.results);
oView.byId("idmodeloss").setModel(jModel);
},
error: function (err) {
console.log(err);
}
});
},