on 04-24-2015 12:46 AM
Hello,
I am just following the exercise to create offline scenario. I was able to do READ, but when I tried to open the online store, I am keep getting the error ( screenshot attached).
I am using the standard code from excersie but wonering what's is wrong. I tried to increase the log level on SMP to DEBUG, but no entries are found in log related offline.
Please help. Here is the piece of code I am using to open the store
function openStore() {
if (!haveAppId()) {
return;
}
var authStr = "Basic " + btoa(applicationContext.registrationContext.user + ":" + applicationContext.registrationContext.password);
updateStatus2("store.open called");
startTime = new Date();
var properties = {
"name": "ProductsOfflineStore",
"host": applicationContext.registrationContext.serverHost,
"port": applicationContext.registrationContext.serverPort,
"https": applicationContext.registrationContext.https,
//"serviceRoot" : "http://hcpms-p1zzxxxxxtrial.hanatrial.ondemand.com/com.xyz.test", //appId,
"serviceRoot": applicationContext.applicationEndpointURL,
// "serviceRoot": "com.slb.mobile",
"customHeaders" : {
"X-SMP-APPCID" : applicationContext.applicationConnectionId
},
"streamParams" : "custom_header=Authorization: Basic " + authStr + ";",
"definingRequests" : {
"ProductsDR" : "/Products"
}
};
store = sap.OData.createOfflineStore(properties);
store.open(openStoreSuccessCallback, errorCallback/*, options*/);
}
I just updated SMP SDK version to latest and looks like it is working. I still need to do more testing. I will let you know guys if I encounter any issues. Tune in please.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.