Geolocation and HTTP requests in the background with Ionic 2

Asked

Viewed 136 times

1

I’m creating an app with Ionic 2 in this application I need to take the geolocation of the device and make HTTP requests to a web service that I have published.

I used Sqlite to store the information while offline, and send it when online. Even so beauty! The problem is that when I’m on Ios or Android if I press the "home" key or lock the devices simply stops recording the geolocation of the device and also stops making the HTTP requests. However, it is important that while you have a connection this information is sent, even with the locked device or the application "minimized".

I studied Ionic-Native plugins like Backgroundmode, and Backgroundgeolocation but it didn’t work. In the case of backgroundMode it simply doesn’t work on Ios, and Backgroundgeolocation even if it captures geolocation and stores in Sqlite does not run HTTP calls.

Does anyone know how I can treat this? I am using IONIC VIEW to perform the tests.

Thank you!

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.