diff --git a/src/app/pages/home/home.page.html b/src/app/pages/home/home.page.html
index 614e3f1..7c01afe 100644
--- a/src/app/pages/home/home.page.html
+++ b/src/app/pages/home/home.page.html
@@ -119,7 +119,7 @@
-
+ 0">
diff --git a/src/app/pages/home/home.page.ts b/src/app/pages/home/home.page.ts
index f0d0361..03e9e5b 100644
--- a/src/app/pages/home/home.page.ts
+++ b/src/app/pages/home/home.page.ts
@@ -24,6 +24,7 @@ export class HomePage implements OnInit {
offerBanner = "https://www.wrenchboard.com/assets/images/apps/offer.jpg";
walletDescription:string ="";
walletData:any;
+ enableTracking:number=0;
constructor(
@@ -39,6 +40,7 @@ export class HomePage implements OnInit {
this.firstname = this.sessionDataProviderService.firstname;
this.blogData = this.blogDataService.blogData;
this.active_job_count = this.sessionDataProviderService.active_job_count;
+ this.enableTracking = this.sessionDataProviderService.tracking;
}
ngOnInit() {
diff --git a/src/app/services/loc-trc.service.ts b/src/app/services/loc-trc.service.ts
index f91a290..17ccbd0 100644
--- a/src/app/services/loc-trc.service.ts
+++ b/src/app/services/loc-trc.service.ts
@@ -12,6 +12,9 @@ export class LocTrcService {
}
async startTracking(){
+ if ( this.sessionDataProviderService.tracking == 0 ){
+ return; // dont do if mnot enabled
+ }
const coordinates = await Geolocation.getCurrentPosition();
//debugger;
console.log('Current position 0000:', coordinates);
diff --git a/src/app/store/session-data-provider.service.ts b/src/app/store/session-data-provider.service.ts
index 17a0acf..6237841 100644
--- a/src/app/store/session-data-provider.service.ts
+++ b/src/app/store/session-data-provider.service.ts
@@ -74,6 +74,7 @@ export class SessionDataProviderService {
pref_phone:number=0;
promo:number=0;
active_job_count:number =0;
+ tracking:number = 0;
session_contructed:boolean = false;
@@ -106,6 +107,7 @@ export class SessionDataProviderService {
this.pref_phone = loginResult.pref_phone;
this.promo=loginResult.promo;
this.active_job_count = loginResult.active_job_count;
+ this.tracking = loginResult.tracking;
//this.pushNotificationProvider.tagUser(this.session);
this.session_contructed = true;