@roma35 wrote:
hi everyone.
I have a problem with my Service Rest, not working in my emulator devices. but in my local host working well, like this
in my emulator devices not working well, like this
my code is this:
ionic.project file
{
"name": "zupaios",
"app_id": "",
"proxies": [{
"path": "/zupa",
"proxyUrl": "http://web.zupa.delivery/webservice/index.php/"
}]
}serveces.js file
(function(){
var zupaio = angular.module('zupaio.zupafactoryio', ['ngCordova']);zupaio.factory('zupafactoryio',function($http,$cordovaSQLite,ZupaPoint){ var storeShop = []; var storeProducts = []; db = window.openDatabase("zupas.db", "1.0", "Data Base ZUPA-PHONE", 200000); return { ZupaListCategory:function(){ return $http.get('/zupa/categories'); }, } // other functions
}
})();controller.js file
// list all categories
zupaio.controller('ListCategoryCtrl', function($scope,$http,zupafactoryio,$ionicLoading,$timeout) {$scope.loading = $ionicLoading.show({ content: '<ion-spinner icon="android"></ion-spinner>', animation: 'fade-in', showBackdrop: false, maxWidth: 50, showDelay: 0 }); $timeout(function () { zupafactoryio.ZupaListCategory().then(function(categories){ // CHARGE ALL CATEGORIES $scope.categories = categories.data; categoriesvar = categories.data; }); $ionicLoading.hide(); }, 3000); });
please help me I don't know why not show me in my emulator devices, but in local host working well
or I need to install a pluginthank for your attention.
Posts: 1
Participants: 1