Hi ,
I am trying to get the data from oDataModel before it gets bound to the list , in the view .I have tried to set my model in the attach request completed delegate method.
appC.oModel.attachRequestCompleted(function(evt){
alert("Request Completed" + "--");
var name = sap.ui.getCore().getModel().getData();
console.log(name);
});
I am invoking the REST service using oData Model constructor:
appC.oModel = new sap.ui.model.odata.ODataModel(sServiceUrl1,false, "usr", "pwd" , mHeaders);
I am expecting variable name should have , the data of the collection , but I am always getting null.
Regards
Nidhideep Bhandari