Giter VIP home page Giter VIP logo

cordova-plugin-background-geolocation-example's People

Contributors

mauron85 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cordova-plugin-background-geolocation-example's Issues

get as many points (lat, long) as long as the app is connected

Hi, I would like to congratulate,
of all libs q I tested your was the q got better results.
I have a question,
I would like to get as many points (lat, long) as long as the app is connected ... I store the data locally so I do not have to worry about ajax requests.
What is the best setting for this case?
thank you so much.

Stop on "Connecting to Google Play Services"

Hi,

I am not able to make than the example works with the ANDROID_ACTIVITY_PROVIDER.

With the classical provider all is OK.

The enviroment where i'm testing is Visual Studio Emulator for Android, running a device with API 23 (same results with other APIs).

Always I have this log results (ANDROID_ACTIVITY_PROVIDER):

%c[2016/09/29 13:13:12] %ccom.marianhello.bgloc.ActivityRecognitionLocationProvider:Connecting to Google Play Services
%c[2016/09/29 13:13:12] %ccom.marianhello.bgloc.ActivityRecognitionLocationProvider:Start recording
#```
Thanks in advance


Fails to build fresh install

Cloned fresh from github with latest npm, cordova installed. Ran npm install; npm run build

It seems to have trouble compiling the es6 code (e.g. static and =>, etc)

ERROR in ./node_modules/react-navigation/src/views/TabView/TabView.js
Module parse failed: Unexpected token (10:22)
You may need an appropriate loader to handle this file type.
| 
| class TabView extends React.PureComponent {
|   static defaultProps = {
|     lazy: true,
|     removedClippedSubviews: true,
 @ ./node_modules/react-navigation/src/react-navigation.js 84:11-45
 @ ./src/BrowserNavigator.js
 @ ./src/CordovaApp.js
 @ multi babel-polyfill ./src/CordovaApp.js

ERROR in ./node_modules/react-navigation/src/navigators/SwitchNavigator.js
Module parse failed: Unexpected token (11:13)
You may need an appropriate loader to handle this file type.
| 
|   const navigator = createNavigator(router, routeConfigMap, switchConfig)(
|     props => <SwitchView {...props} />
|   );
| 
 @ ./node_modules/react-navigation/src/react-navigation.js 26:11-50
 @ ./src/BrowserNavigator.js
 @ ./src/CordovaApp.js
 @ multi babel-polyfill ./src/CordovaApp.js

How run example on Cordova

Hello.

I am trying to start this app in cordova and I do not know if there is a problem but there is no file in the www folder. Can someone confirm if this example can be executed correctly?

Thank you!

best regards!

White screen on Android

Hi there,
I just checked out the code, followed the instructions and compiled an Android debug apk. When it was installed on the device (Android 8.0.0), I ended up with white screen.
Console log says:

TypeError: (0 , o.default)(...).darken(...).hex is not a function app.js:1 at Object.get statusBarColor [as statusBarColor] (file:///android_asset/www/app.js:1:4701) at file:///android_asset/www/app.js:1:36865 at fr (file:///android_asset/www/app.js:1:27433) at file:///android_asset/www/app.js:1:36667 at Function.ll (file:///android_asset/www/app.js:1:52475) at e (file:///android_asset/www/app.js:11:234047) at file:///android_asset/www/app.js:11:234184 at file:///android_asset/www/app.js:1:36862 at fr (file:///android_asset/www/app.js:1:27433) at file:///android_asset/www/app.js:1:36667

Any help would be appreciated.

Crash on Huawei

As the title says, the app crashes whenever you try to activate and use geolocation foreground or background.

It only happens in Huawei devices. I guess this is maybe related to the problems the company not beign able to use Google services now..?

Thank you

Edit: I tried 3 different models of Huawei.

Crashs on API 29 - API 28

Hello people.
I have an IONIC 4 application and to perform the migration to meet API 28 and 29, I upgraded the version of cordova-plugin-background-geolocation to 3.0.1 (previously used 2.3.6).
I am getting the error below on Android:

Process: br.com.kdcare.professional, PID: 8005
    android.app.RemoteServiceException: Bad notification for startForeground: java.lang.RuntimeException: invalid channel for service notification: Notification (channel = null pri = 0 contentView = null vibrate = null sound = null defaults = 0x0 flags = 0x62 color = 0xffff0000 vis = PRIVATE)
        at android.app.ActivityThread $ H.handleMessage (ActivityThread.java:1938)
        at android.os.Handler.dispatchMessage (Handler.java:107)
        at android.os.Looper.loop (Looper.java:214)
        at android.app.ActivityThread.main (ActivityThread.java:7319)
        at java.lang.reflect.Method.invoke (Native Method)
        at com.android.internal.os.RuntimeInit $ MethodAndArgsCaller.run (RuntimeInit.java:492)
        at com.android.internal.os.ZygoteInit.main (ZygoteInit.ja
va: 934)

My AndroidManifest.xml already contains the line below:

Anyone else with this problem that can help?

Thanks!

AAPT: No ressource found that matches the given name

When I execute cordova build android, I get the following error message:

:processDebugResourcesC:\cordova-plugin-background\platforms\android\res\xml\aut
henticator.xml:5:19-31: AAPT: No resource found that matches the given name (at
'icon' with value '@mipmap/icon').
     FAILED

C:\cordova-plugin-background\platforms\android\res\xml\authenticator.xml:6:24-36
: AAPT: No resource found that matches the given name (at 'smallIcon' with value
 '@mipmap/icon').


FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':processDebugResources'.
> com.android.ide.common.process.ProcessException: org.gradle.process.internal.E
xecException: Process 'command 'C:\Users\olivier\AppData\Local\Android\sdk\buil
d-tools\23.0.3\aapt.exe'' finished with non-zero exit value 1

* Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.
BUILD FAILED

Total time: 12.83 secs
Error: cmd: Command failed with exit code 1 Error output:
C:\cordova-plugin-background\platforms\android\res\xml\authenticator.xml:5:19-31
: AAPT: No resource found that matches the given name (at 'icon' with value '@mi
pmap/icon').

C:\cordova-plugin-background\platforms\android\res\xml\authenticator.xml:6:24-36
: AAPT: No resource found that matches the given name (at 'smallIcon' with value
 '@mipmap/icon').


FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':processDebugResources'.
> com.android.ide.common.process.ProcessException: org.gradle.process.internal.E
xecException: Process 'command 'C:\Users\olivier\AppData\Local\Android\sdk\buil
d-tools\23.0.3\aapt.exe'' finished with non-zero exit value 1

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.

Thank you for your help,

Olivier.

Android Build Problem / Package missing

Hi All,

I included this plugin in my Ionic/Angular/Capacitor project.
When building it in Android Studio the following error occurs for BackgroundLocation.java file:

error: package android.support.v4.util does not exist
import android.support.v4.util.TimeUtils;
                              ^

Could someone advice me about how to fix this package problem?
Thanks in advance!
Stedenko

Build error on windows

There is an error, not working:

C:\work\cpgps>npm ERR! code ELIFECYCLE
npm ERR! errno 255
npm ERR! [email protected] clean: rimraf www/*!(gitignore)
npm ERR! Exit status 255
npm ERR!
npm ERR! Failed at the [email protected] clean script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Luca\AppData\Roaming\npm-cache_logs\2018-05-01T14_21_45_630Z-debug.log

Fix for build issue on windows

Hey guys,
Windows has a 255 character limit for paths so when you are building the application you may encounter an error relating to some very long path to fix this simply rename the downloaded folder name from cordova-plugin-background-geolocation-example -> something_shorter then try building again

Hope it helps.

Folde www is empty?

how to edit variable GOOGLE_MAPS_API_KEY in www / index.html if the www folder is empty?

Can’t latch onto lifecycle

I am trying to access the watcher of the exit stationary region but it says any of the functions I try to access done exist.
this.backgroundGeolocation.on('stationary', (stationaryLocation) => { // handle stationary locations here });
When i try to do the above i get the error: Property 'on' does not exist on type 'BackgroundGeolocation'.

Your Environment

Plugin version: 2.3.3
Platform: iOS
OS version: iOS 11
Device manufacturer and model: iPhone 7
Cordova version (cordova -v):8.0.0
Cordova platform version (cordova platform ls):4.5.4
Plugin configuration options:
desiredAccuracy: 10, stationaryRadius: 5, distanceFilter: 5, interval: 2000, httpHeaders: { 'Content-Type': 'application/json', 'Authorization': getAuthToken() }, url: this.updateLocURL, debug: true, // enable this hear sounds for background-geolocation life-cycle. stopOnTerminate: false, // enable this to clear background location settings when the app terminates

background tracking not working

i'm trying to use the background tracking.
I don't have any errors, but the javascript callback is not called (probably this is normale when app is in background) but also the http post request is not called.

i've configured it like this:

window.backgroundGeolocation.configure(
   watchPositionSuccessCallback,
   watchPositionErrorCallback,
   {
       desiredAccuracy: 0,
       interval: 10,
       activityType: 'AutomotiveNavigation',

       notificationTitle: 'My App',
       notificationText: 'My Text',

       url: api_domain+'/orders/'+order_uuid+'/route',
       httpHeaders: {
           'Authorization': sessionStorage.getItem('http_auth')
       },

       pauseLocationUpdates: false,
   }
);
$scope.startBackgroundGeolocation();

at least I should receive an HTTP POST on my server, but this doesn't happen.

cordova run android --device - app.js

I tried to run the demo on my android device but it gives me an error.
Failed to load resource: net::ERR_FILE_NOT_FOUND app.js

npm i
npm run build

cordova platform add android
cordova plugin add cordova-plugin-mauron85-background-geolocation
cordova build android

cordova run android --device

blank page.

add IMEI in Json Post

Greetings @mauron85 , I am trying to modify the cordova code-plugin-background-geolocation-example to upload in the parseJson by POST another element to display, this time the device IMEI, but I do not know java, Can you give me some idea where I can modify this?
Thank you.

BCordova Build fails

Build of alpha50 android fails with following message.
After fallback to 2.3.6 and cordova clean, build is OK

I will revert to v2 for now, but maybe there is a suggestion to fix.


FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'.

java.lang.RuntimeException: java.lang.RuntimeException: com.android.builder.dexing.DexArchiveMergerException: Unable to merge dex

Your config.xml file does not have a <content> element.

ionic build android

throw error.

Error happened [Error:
Your config.xml file does not have a <content> element.
Add something like: <content src="index.html"/>]
Error:
Your config.xml file does not have a <content> element.
Add something like: <content src="index.html"/>
    at /usr/local/lib/node_modules/ionic/node_modules/ionic-app-lib/lib/config-xml.js:64:15
    at _fulfilled (/usr/local/lib/node_modules/ionic/node_modules/q/q.js:787:54)
    at self.promiseDispatch.done (/usr/local/lib/node_modules/ionic/node_modules/q/q.js:816:30)
    at Promise.promise.promiseDispatch (/usr/local/lib/node_modules/ionic/node_modules/q/q.js:749:13)
    at /usr/local/lib/node_modules/ionic/node_modules/q/q.js:557:44
    at flush (/usr/local/lib/node_modules/ionic/node_modules/q/q.js:108:17)
    at doNTCallback0 (node.js:417:9)
    at process._tickCallback (node.js:346:13)

BUILD FAILED in 5s

Just cloned, installed, and tried to build for Android. Got the next error:

razs-MacBook:mauron-geolocation razbuchnik$ cordova build android
Android Studio project detected
copying res/icons/mappointer_small.png to platforms/android/app/src/main/res/drawable/mappointer_small.png
copying res/icons/mappointer_large.png to platforms/android/app/src/main/res/drawable/mappointer_large.png
ANDROID_HOME=/Users/razbuchnik/Library/Android/sdk
JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_111.jdk/Contents/Home
studio
Subproject Path: CordovaLib
Subproject Path: app
publishNonDefault is deprecated and has no effect anymore. All variants are now published.

FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring project ':CordovaLib'.
> No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 5s
/Users/razbuchnik/Projects/mauron-geolocation/platforms/android/gradlew: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring project ':CordovaLib'.
> No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 5s
razs-MacBook:mauron-geolocation razbuchnik$ 

problem with iOS

hello,

i used the last version 3.1.0 but with your example on ios when I kill application after want again go in app crashed. In this case I need remove, and then works, after that again not works. Need again removed app aind again works.

What is problem?

ionic 4 when app minimize it not work

i try it but it giving issue i started it on click but it not working in background? Like this

startBackgroundGeolocation() {
const config: BackgroundGeolocationConfig = {
desiredAccuracy: 10,
stationaryRadius: 1,
distanceFilter: 1,
interval:15000,
debug: true, // enable this hear sounds for background-geolocation life-cycle.
stopOnTerminate: false // enable this to clear background location settings when the app terminates

};

this.backgroundGeolocation.configure(config).then(() => {
  this.backgroundGeolocation
    .on(BackgroundGeolocationEvents.location)
    .subscribe((location: BackgroundGeolocationResponse) => {
      // alert(location.longitude);
      this.sendGPS(location);

      // IMPORTANT:  You must execute the finish method here to inform the native plugin that you're finished,
      // and the background-task may be completed.  You must do this regardless if your operations are successful or not.
      // IF YOU DON'T, ios will CRASH YOUR APP for spending too much time in the background.
    });
});

// start recording location
this.backgroundGeolocation.start();

// If you wish to turn OFF background-tracking, call the #stop method.
// this.backgroundGeolocation.stop();

}

sendGPS(location) {
if (location.speed == undefined) {
location.speed = 0;
}
let timestamp = new Date(location.time);

this.http
  .post(
    this.gps_update_link, // backend api to post
    {
      lat: location.latitude,
      lng: location.longitude,
      speed: location.speed,
      timestamp: timestamp
    },
    {}
  )
  .then(data => {
    this.Data.push({lat : location.latitude , lon : location.longitude , spe : location.speed , time : location.timestamp});
    console.log(data.status);
    console.log(data.data); // data received by server
    console.log(data.headers);
    this.backgroundGeolocation.finish(); // FOR IOS ONLY
  })
  .catch(error => {
    alert(error.status);
    alert(error.error); // error message as string
    alert(error.headers);
    this.backgroundGeolocation.finish(); // FOR IOS ONLY
  });

}

This is a code i am using please inform me what i am doing wrong?

Question about config in background options.

Hello!

I have a question about the configuration of this example.

Why these options in 'interval', 'fastestInterval' and 'activitiesInterval'?

In the documentation it says that it is a millisecond configuration. With this configuration, do you try to update at full speed? Greetings and thank you

var bgOptions = {
...
interval: 10,
fastestInterval: 5,
activitiesInterval: 10,
...
};

Is there a non-React example?

I am updating a very simple app that was built using 1.x I followed the migration guide from 1.x to 2.x and then to 3.x.

Is there an example of the 3.x that is not React based?

Thank you!

Crahs on Android 8.1.0

Hi,
Should this plugin work on Andoid 8.1.0?. For 7.x version it is working for me, but for 8.1.0, the app crashes whenever I call to start method of this plugin.
This is the error I get on Android Studio logcat:

E/AndroidRuntime: FATAL EXCEPTION: main
                                                                      Process: com.suez.galiaMovile, PID: 31963
                                                                      android.app.RemoteServiceException: Bad notification for startForeground: java.lang.RuntimeException: invalid channel for service notification: Notification(channel=null pri=0 contentView=null vibrate=null sound=null defaults=0x0 flags=0x62 color=0x00000000 number=0 vis=PRIVATE semFlags=0x0 semPriority=0 semMissedCount=0)
                                                                          at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1893)
                                                                          at android.os.Handler.dispatchMessage(Handler.java:106)
                                                                          at android.os.Looper.loop(Looper.java:164)
                                                                          at android.app.ActivityThread.main(ActivityThread.java:6960)
                                                                          at java.lang.reflect.Method.invoke(Native Method)
                                                                          at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:441)
                                                                          at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1408)

App crashes on Android after installing the apk

I had the same issue referred on this link. So to resolve the issue i did what klaus-donnert did,and also went here to download the latest plugin.... below is my xml file:

<preference name="phonegap-version" value="cli-6.4.0" /> 
<plugin name="cordova-plugin-mauron85-background-geolocation" spec="^2.2.5">
        <variable name="ALWAYS_USAGE_DESCRIPTION" value="This app requires background tracking enabled to calculate the distance between you and Ecocompub partners" /> 
</plugin>

Next step was to test the app on my android, so after uploading the zip on phonegap.build, i read the qr code as usual, and .... the app crashed! it opens for a few seconds, but then closes...if i simply don´t use the plugin, the app runs well...does anybody experienced this problem?, i´m completely stuck.

Regards

Building in Ionic AppFlow gives error

I have an Ionic 4 Cordova app and I'm trying to build in AppFlow, but it fails with the error:

/Users/ionic/builds/project-0/platforms/ios/MyApp/Plugins/cordova-plugin-background-geolocation/CDVBackgroundGeoLocation.m:8:9: fatal error: 'Cordova/CDVJSON.h' file not found

Any ideas why it wouldn't be able to find this file?

White Screen on iOS iPhone 6

I am trying to track down a crash bug in the background geolocation plugin that's occurring in my app (ionic). My thought was to compare it to the behavior of the example before filing a bug report.

I have signed up for a google maps key and have followed the instructions in the README.

I ran into the "No development team" issue but Xcode would not allow me to use the default widget id so I changed it to

<widget id="com.yml.bgexampleapp"

in config.xml and then selected my personal development team in Xcode.

The application built, installed, and ran without errors but shows nothing but a white screen.

The log from Xcode is:

2018-06-05 13:22:03.730483-0400 BG Example[6226:1734737] DiskCookieStorage changing policy from 2 to 0, cookie file: file:///private/var/mobile/Containers/Data/Application/03A690A1-12EB-4F1D-B1BF-2157C58436FD/Library/Cookies/Cookies.binarycookies
2018-06-05 13:22:04.054628-0400 BG Example[6226:1734737] Apache Cordova native platform version 4.5.3 is starting.
2018-06-05 13:22:04.056406-0400 BG Example[6226:1734737] Multi-tasking -> Device: YES, App: YES
2018-06-05 13:22:04.073272-0400 BG Example[6226:1734737] 

Started backup to iCloud! Please be careful.
Your application might be rejected by Apple if you store too much data.
For more information please read "iOS Data Storage Guidelines" at:
https://developer.apple.com/icloud/documentation/data-storage/
To disable web storage backup to iCloud, set the BackupWebStorage preference to "local" in the Cordova config.xml file
2018-06-05 13:22:04.536318-0400 BG Example[6226:1734737] Using UIWebView
2018-06-05 13:22:04.545475-0400 BG Example[6226:1734737] [CDVTimer][console] 0.177979ms
2018-06-05 13:22:04.545894-0400 BG Example[6226:1734737] [CDVTimer][handleopenurl] 0.286937ms
2018-06-05 13:22:04.552436-0400 BG Example[6226:1734737] [CDVTimer][intentandnavigationfilter] 6.468892ms
2018-06-05 13:22:04.552713-0400 BG Example[6226:1734737] [CDVTimer][gesturehandler] 0.180960ms
2018-06-05 13:22:04.606457-0400 BG Example[6226:1734737] +backgroundSessionConfiguration: is deprecated. Please use +backgroundSessionConfigurationWithIdentifier: instead
2018-06-05 13:22:04:603 BG Example[6226:1734737] Backing up original handler.
2018-06-05 13:22:04:604 BG Example[6226:1734737] Setting new handler.
2018-06-05 13:22:04.677347-0400 BG Example[6226:1734737] [CDVTimer][backgroundgeolocation] 124.503970ms
2018-06-05 13:22:04.677452-0400 BG Example[6226:1734737] [CDVTimer][TotalPluginStartup] 132.636070ms
2018-06-05 13:22:06.331310-0400 BG Example[6226:1734737] Resetting plugins due to page load.
2018-06-05 13:22:07.092845-0400 BG Example[6226:1734737] Finished load of: file:///var/containers/Bundle/Application/D1361D84-FEF5-4D4E-9274-7DE0FA90058B/BG%20Example.app/www/index.html
2018-06-05 13:23:00.115821-0400 BG Example[6226:1734737] Status bar could not find cached time string image. Rendering in-process.
2018-06-05 13:24:00.024981-0400 BG Example[6226:1734737] Status bar could not find cached time string image. Rendering in-process.
2018-06-05 13:26:00.021501-0400 BG Example[6226:1734737] Status bar could not find cached time string image. Rendering in-process.

My config is:

Node version: v9.4.0

Cordova version: 8.0.0

Config.xml file: 

<?xml version='1.0' encoding='utf-8'?>
<widget id="com.yml.bgexampleapp" version="2.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
    <name>BG Example</name>
    <description>
        A minimal example of Cordova BackgroundGeolocation plugin.
    </description>
    <author>
        mauron85
    </author>
    <access origin="*" />
    <allow-intent href="http://*/*" />
    <allow-intent href="https://*/*" />
    <allow-intent href="tel:*" />
    <allow-intent href="sms:*" />
    <allow-intent href="mailto:*" />
    <allow-intent href="geo:*" />
    <allow-navigation href="http://192.168.0.103:8100" />
    <platform name="android">
        <content src="index.html" />
        <allow-intent href="market:*" />
        <hook src="scripts/res_android.js" type="after_prepare" />
        <icon density="ldpi" src="res/android/icon-36-ldpi.png" />
        <icon density="mdpi" src="res/android/icon-48-mdpi.png" />
        <icon density="hdpi" src="res/android/icon-72-hdpi.png" />
        <icon density="xhdpi" src="res/android/icon-96-xhdpi.png" />
        <icon density="xxhdpi" src="res/android/icon-144-xxhdpi.png" />
        <icon density="xxxhdpi" src="res/android/icon-192-xxxhdpi.png" />
    </platform>
    <platform name="ios">
        <content src="index.html" />
        <allow-intent href="itms:*" />
        <allow-intent href="itms-apps:*" />
        <icon height="180" src="res/ios/icon-60-3x.png" width="180" />
        <icon height="60" src="res/ios/icon-60.png" width="60" />
        <icon height="120" src="res/ios/icon-60-2x.png" width="120" />
        <icon height="76" src="res/ios/icon-76.png" width="76" />
        <icon height="152" src="res/ios/icon-76-2x.png" width="152" />
        <icon height="40" src="res/ios/icon-40.png" width="40" />
        <icon height="80" src="res/ios/icon-40-2x.png" width="80" />
        <icon height="57" src="res/ios/icon.png" width="57" />
        <icon height="114" src="res/ios/icon-2x.png" width="114" />
        <icon height="72" src="res/ios/icon-72.png" width="72" />
        <icon height="144" src="res/ios/icon-72-2x.png" width="144" />
        <icon height="29" src="res/ios/icon-small.png" width="29" />
        <icon height="58" src="res/ios/icon-small-2x.png" width="58" />
        <icon height="50" src="res/ios/icon-50.png" width="50" />
        <icon height="100" src="res/ios/icon-50-2x.png" width="100" />
    </platform>
    <plugin name="cordova-plugin-whitelist" spec="^1.3.3" />
    <plugin name="cordova-plugin-device" spec="^1.1.7" />
    <plugin name="cordova-plugin-mauron85-background-geolocation" spec="^3.0.0-alpha.37">
        <variable name="GOOGLE_PLAY_SERVICES_VERSION" value="11+" />
        <variable name="ANDROID_SUPPORT_LIBRARY_VERSION" value="26+" />
        <variable name="ICON" value="@mipmap/icon" />
        <variable name="SMALL_ICON" value="@mipmap/icon" />
        <variable name="ACCOUNT_NAME" value="@string/app_name" />
        <variable name="ACCOUNT_LABEL" value="@string/app_name" />
        <variable name="ACCOUNT_TYPE" value="$PACKAGE_NAME.account" />
        <variable name="CONTENT_AUTHORITY" value="$PACKAGE_NAME" />
    </plugin>
    <engine name="ios" spec="^4.5.4" />
    <engine name="android" spec="^7.1.0" />
</widget>


Plugins: 

cordova-plugin-device,cordova-plugin-mauron85-background-geolocation,cordova-plugin-whitelist

iOS platform:

Xcode 9.3.1
Build version 9E501

Any pointers as to what to try would be greatly appreciated. Thanks.

Obfuscate

I can build the example without obfuscate the app.js?

Sending Data

Just want to ask something about data sending, i am using asp.net as server to retrieve data from
cordova-plugin-background-geolocation mobile apps. i try to use request.param to read the data but ufortunately i did'nt get the data from
postTemplate: {
lat: '@latitude',
lon: '@longitude',
act:'APOKONO',
provider: '@Provider',
locationProvider: '@locationProvider',
time: '@time',
accuracy: '@accuracy',
speed: '@speed',
altitude: '@altitude',
bearing: '@bearing'
}
only retrieve data from header
httpHeaders: {
'AUTH': 'JSDFSDS77SDF8SD56S5DF86SD9F799SAD7U'
}

so can i know how the actual this plugin work to send the data to server?

how to use with capacitor and vue js

Hi,
Thank you for this project, I would like to know if it is possible to use this plugin with capacitor and vue js if so It would really great to see a few pointers on how to do it

unable to get data into server

I am able to build the app and run
the app runs perfectly on my device and also tracking location well

i am unable to send the location to the server
have tried sending it to the server you have provided using node.js and also my localhost and am unable to get the result

please help have tried it for a week now

Could not install from "@mauron85/cordova-plugin-background-geolocation@~3.1.0" as it does not contain a package.json file.

{ Error: npm: Command failed with exit code 1 Error output:
npm ERR! code ENOLOCAL
npm ERR! Could not install from "@mauron85/cordova-plugin-background-geolocation@~3.1.0" as it does not contain a package.json file.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/mit/.npm/_logs/2020-01-30T09_33_11_614Z-debug.log
at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-common/src/superspawn.js:135:23)
at ChildProcess.emit (events.js:198:13)
at maybeClose (internal/child_process.js:982:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
stderr:
'npm ERR! code ENOLOCAL\nnpm ERR! Could not install from "@mauron85/cordova-plugin-background-geolocation@~3.1.0" as it does not contain a package.json file.\n\nnpm ERR! A complete log of this run can be found in:\nnpm ERR!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.