disable tracking

This commit is contained in:
CHIEFSOFT\ameye
2023-10-26 21:18:25 -04:00
parent 958a3e64b0
commit 192356a507
4 changed files with 8 additions and 1 deletions
+1 -1
View File
@@ -119,7 +119,7 @@
<!-- <ion-title>{{walletDescription}}</ion-title>-->
</ion-toolbar>
<ion-card class="map-sec">
<ion-card class="map-sec" *ngIf="enableTracking > 0">
<app-tracking></app-tracking>
<ion-card-content>
<ion-list>
+2
View File
@@ -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() {
+3
View File
@@ -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);
@@ -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;