on 07-12-2016 1:46 PM
Hello Experts,
I am new to SAP UI5 development.and facing issue in SAP WEBIDE app development.
On clicking of entry in master page details page is not loading with required data.
"This Order Not available" page is coming.
Using ODATA model service to create structure .
_onBindingChange : function () {
var oView = this.getView(),
oElementBinding = oView.getElementBinding();
// No data for the binding
if (!oElementBinding.getBoundContext()) {
this.getRouter().getTargets().display("detailObjectNotFound");
// if object could not be found, the selection in the master list
// does not make sense anymore.
this.getOwnerComponent().oListSelector.clearMasterListSelection();
return;
}
in above mention code:
oElementBinding.getBoundContext() is throwing null..
why its throwing null.
please help.
Regards,
Hari.
Did you bind your view in the onRouteMatched?
onRouteMatched: function(oEvent) {
var oParams = oEvent.getParameters(),
sPath = "/yourEntitySet("'"+oParams.arguments.yourProperty+"'");
this.getView().bindElement({
path: sPath,
events: {
change: this._onBindingChange.bind(this)
}
});
}
Regards,
Robin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Robin,
Many thanks for your response.
Yes.I am binding view onRouteMatched as follows.
this.getModel().metadataLoaded().then( function() {
var sObjectPath = this.getModel().createKey("Orders", {OrderID : sObjectId});
this._bindView("/" + sObjectPath);
}.bind(this));
As I mentioned in my query onBindChangeMethod
oElementBinding.getBoundContext() throwing null.
how to check which backend data it is checking and throwing msg as not found.
Order List is generating Master page from backend source(server:port:XMII/IlluminatorOData/Rowset(QueryTemplate=path/RowsetID=1)/Row) same order number is not coming in Details page.
how to check which backend data it is cheking and throwing msg as not found.
Appreciate your help.
Regards,
Hari
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.