Subversion Repositories eFlore/Applications.cel

Compare Revisions

Ignore whitespace Rev 2407 → Rev 2408

/trunk/widget/modules/saisie/squelettes/arbres-tetards/js/arbres-tetards.js
225,20 → 225,8
 
function initialiserGoogleMap(){
// Carte
if (NOM_SCI_PROJET == 'bdtxa') {
var latLng = new google.maps.LatLng(14.6, -61.08334);// Fort-De-France
var zoomDefaut = 8;
} else if (NOM_SCI_PROJET == 'isfan') {
var latLng = new google.maps.LatLng(29.28358, 10.21884);// Afrique du Nord
var zoomDefaut = 4;
} else if (NOM_SCI_PROJET == 'apd') {
var latLng = new google.maps.LatLng(8.75624, 1.80176);// Afrique de l'Ouest et du Centre
var zoomDefaut = 4;
} else {
//var latLng = new google.maps.LatLng(46.30871, 2.54395);// Centre de la France
var latLng = new google.maps.LatLng(45.1667, 5.7905);// Centre de l'Isère
var zoomDefaut = 8;
}
var latLng = new google.maps.LatLng(45.1667, 5.7905);// Centre de l'Isère
var zoomDefaut = 8;
 
var options = {
zoom: zoomDefaut,
498,7 → 486,7
 
function getUrlAutocompletionNomsSci() {
var mots = $('#taxon').val(),
url = SERVICE_AUTOCOMPLETION_NOM_SCI_URL_TPL.replace('{referentiel}',NOM_SCI_PROJET);
url = SERVICE_AUTOCOMPLETION_NOM_SCI_URL_TPL.replace('{referentiel}',NOM_SCI_REFERENTIEL);
url = url.replace('{masque}', mots);
return url;
}
666,26 → 654,8
var geocoderOptions = {},
addressSuffix = '';
 
switch(NOM_SCI_PROJET) {
case 'isfan':
// Si des résultats se trouvent dans ce rectangle, ils apparaîtront en premier.
// Ça marche moyen...
geocoderOptions.bounds = new google.maps.LatLngBounds(
new google.maps.LatLng(20.756114, -22.023927),
new google.maps.LatLng(38.065392, 33.78662)
);
break;
case 'apd':
geocoderOptions.bounds = new google.maps.LatLngBounds(
new google.maps.LatLng(-6.708254, -26.154786),
new google.maps.LatLng(27.488781, 30.490722)
);
break;
case 'bdtfx':
case 'bdtxa':
geocoderOptions.region = 'fr';
addressSuffix = ', France';
}
geocoderOptions.region = 'fr';
addressSuffix = ', France';
 
$('#carte-recherche').autocomplete({
//Cette partie utilise geocoder pour extraire des valeurs d'adresse
993,7 → 963,7
var numNomSel = ($('#taxon-liste').val() == '?') ? $('#taxon').data('numNomSel') : $('#taxon-liste').val(),
nomSpecial = $('#taxon-liste option:selected').hasClass('nom-special'),
taxon = ($('#taxon-liste').val() == '?') ? $('#taxon').val() : $('#taxon-liste option:selected').data('nom-a-sauver'),
referentiel = (numNomSel == undefined) ? '' : '['+NOM_SCI_PROJET+']',
referentiel = (numNomSel == undefined) ? '' : '['+NOM_SCI_REFERENTIEL+']',
commune = $('#commune-nom').text(),
codeInsee = $('#commune-code-insee').text(),
lat = $('input[name="latitude"]').val(),