Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3523

Unable to access xsjs service in SAP Web IDE

$
0
0

Hi Experts ,

 

I have created 2 projects The first one is a XSJS project which has the web-service using hana web based development workbench . The second one is a UI5 application project created in SAP WEB IDE .now the controller in the UI project,calls the web-service from the XSJS project, below is the url for xsjs service that i have to utilize in my UI5 application

 

https://sXXhanaxs.hanatrial.ondemand.com/pXXXXXXXtrial/hanadb/hihana/hana/GetUser.xsjs

 

its a simple xsjs service with a select statement , and while trying to call this service in my UI5 page i am getting 404 file not found error

 

below is the code so far :

 

 

$.get( "https://sXXhanaxs.hanatrial.ondemand.com/pXXXXXXXtrial/hanadb/hihana/hana/GetUser.xsjs",

function( data ) {


   $( ".result" ).html( data );

   var jsonModel = new sap.ui.model.json.JSONModel();

   jsonModel.setData(data);

   sap.ui.getCore().setModel(jsonModel, "dataModel");

   var oModel1 = new sap.ui.model.json.JSONModel(); 


  //Getting of Model from Core.


   var aData = sap.ui.getCore().getModel("dataModel").getProperty("/results");

  oModel1.setData({modelData : aData});

  var oSelect = sap.ui.getCore().byId("plant"); 

   oSelect.setModel(oModel1);

  oSelect.bindAggregation("items","/modelData",item);

});

 

Please suggest where i went wrong


Viewing all articles
Browse latest Browse all 3523

Trending Articles