Hi,
I am using ionic in my project which about to complete, but i get strange type of response from angular-dreamfactory. On authentication process, i send http request to dsp which is in our server, for getting data from api services. All works well, even i can see the response body in chrome tool, but the function
DreamFactory.api.user.login(postData,
function (data) {
UserService.setUser(data);
$scope.mediaLoading(2);
$rootScope.$broadcast('user:loggedIn');
$scope.loginModal.hide();
//insert other request for data to fill app
},
function (errors) {
alert("in errors");
if (errors.error[0].code != 400) {
$scope.mediaLoading(2);
...
when a user enters incorrect login, it fails properly, but in second attempt in just stops responding in the app inside DreamFactory.api.user.login(postData,…) and doesnt seem to come out.
For reference:
__in 1st attempt console gives:
POST http://dsp.oshno.tj:7070/rest/user/session 400 (Bad Request) dsp.oshno.tj:7070/rest/user/session:1 // as expected
__in 2nd attempt:
http://domain_name/rest/user/session 400 (Bad Request) ionic.bundle.js:18526 // and then hangs in that function
//not expected
Please, anybody help on injecting DreamFactory properly ???