0
doubledp created
I have tried to determine what I am doing wrong, but can't seem to find the difference between my controller/app service combo and the dashboard example.
I am getting the following JavaScript error when calling the method inside my service from the angular controller:
TypeError: Object doesn't support property or method 'success'
When I use the following, I get no JavaScript error:
function Test() {
appService.getTest()
.then(function(result) {
var test = result;
});
}
But when I use the following code, I get the JavaScript error:
function Test() {
appService.getTest()
.success(function(result) {
var test = result;
});
}
What could be the reason for this?
2 Answer(s)
-
0
Nevermind, it appears that the implementation has changed on the new version of ASP.NET Zero versus the older version of it.
You use to be able to call .success(), but will call .then() from now on.
-
0
Thanks for the feedback @DoubleDP, yes success is deprecatead for angular.