on 04-07-2016 3:23 PM
Hi
I have an issue with the call function of V2 Model. While calling the function import, the console errors out saying
"uncaught (promise) undefined
(anonymous function @ODataModel.js
My function call is as below
var entry = {
'CountBack':'X',
'CountBack_Lvl':'X',
'CountBack_SLvl':' ',
'Def_No_Of_Hu':'2'
};
oModel.callFunction("/DemoEWM","GET",entry,null,function(oData,oResponse){
alert("success:"+oResponse);
},function(oError){
alert("error"+oError);
});
I tried with POST too, but same results.
What is missing here. I am using 1.34 version of UI5
Thanks
Sandip
Hi,
Maybe try setting the parameters explicitly. I'm using the callFunction method as follows (adapted it to have your values):
oModel.callFunction("/DemoEWM", {
"method": "GET",
urlParameters: {
CountBack: 'X',
CountBack_Lvl: 'X',
CountBack_SLvl: ' ',
Def_No_Of_Hu: '2'
},
success: function(oData, oResponse){
//Handle Success
},
error: function(oError){
//Handle Error
}
});
Regards
Albert Volschenk
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You may need to get x-csrf token first.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
10 | |
7 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.