- 
						home page
			
		
- 
				vtenext - Official Forum
				
			
- 
				vtenext CE
				
			
- 
				Google Maps
				
			
	
	
						Google Maps		
	
	
	
		
	
	
		
	
	
	
	
		
		
				
	
		Riduci
		Di più
		
			
									- 
						Messaggi: 29					
- 
						Ringraziamenti ricevuti 1					
- 
											
- 
											
 
	 
		 
		
			
	
						12/08/2021 11:15				#3745
		da graziano.ribichesu@gmail.com
	
	
		
			
			
				Hello, I created the google maps api key to be able to use the service on the Vtenext app I also entered the key limitations on the domains used. But by doing so I can't use it on the app. If I use the app with app.vtecrm.net I can authorize this domain and it works but not with the native app for android or ios. Anyone know how to fix? Thank you			
					 
	 
			Si prega Accedi  a partecipare alla conversazione.
	
		
			 		
													 
	 
	
		
				
	
		Riduci
		Di più
		
			
									- 
						Messaggi: 380					
- 
						Ringraziamenti ricevuti 26					
- 
											
- 
											
 
	 
		 
		
			
	
						13/08/2021 17:23		 -  13/08/2021 17:29		#3746
		da dende
	
	
		
			
			
				Hi Graziano,
you have to set an override so the app fetch the setted key.
To do so, create a new JS file in modules/Touch/overrides and write this code inside:
(function() {
 
	if (Vtecrm && Vtecrm.app) {
 
		if (window.google && window.google.maps) {
			delete window.google.maps;
			window.google = {
				maps: { 
					Map: function() {}
				},
			};
		}
 
		var head = document.getElementsByTagName('head')[0];
		var script = document.createElement('script');
		script.setAttribute('type', 'text/javascript');
		script.setAttribute('src', 'https://maps.googleapis.com/maps/api/js?libraries=panoramio,places&key=MY_GOOGLE_APIKEY');
		head.appendChild(script); 
 
	}
})();
Replace with the correct api key before saving the new file.
Then, logout and login into APP.
On next release there are no need to do this.
Thanks			
 
	 
	
		Ultima Modifica 13/08/2021 17:29  da 
dende.			
Si prega Accedi  a partecipare alla conversazione.
	
		
			 		
													 
	 
	
		
				
	
		Riduci
		Di più
		
			
									- 
						Messaggi: 29					
- 
						Ringraziamenti ricevuti 1					
- 
											
- 
											
 
	 
		 
		
			
	
						19/08/2021 19:10		 -  19/08/2021 19:27		#3748
		da graziano.ribichesu@gmail.com
	
	
		
			
			
				sorry the file name for the override to create is: Geolocalization.js
thank you			
					 
	 
	
			Si prega Accedi  a partecipare alla conversazione.
	
		
			 		
													 
	 
 
	
		
	
	
	
	
	
	
 
	
		- 
						home page
			
		
- 
				vtenext - Official Forum
				
			
- 
				vtenext CE
				
			
- 
				Google Maps
				
			
		Tempo creazione pagina: 0.163 secondi