Subversion Repositories eFlore/Applications.cel

Compare Revisions

Ignore whitespace Rev 570 → Rev 571

/trunk/widget/modules/carto/squelettes/carte_defaut.tpl.html
42,11 → 42,35
var markerClusterer = null;
var map = null;
var nt = '<?=$num_taxon?>';
var infoBulle = new google.maps.InfoWindow();
google.maps.event.addListener(infoBulle, 'domready', function() {
// Onglet Tableau : Jquery => TableSorter
if ($("#observations table").get() != '') {
$("#observations table").tablesorter();
// add parser through the tablesorter addParser method
$.tablesorter.addParser({
// Définition d'un id unique pour ce parsseur
id: 'date_cel',
is: function(s) {
// retourne false si le parsseur n'est pas autodétecté
return false;
},
format: function(s) {
// Transformation date jj/mm/aaaa en aaaa/mm/jj
s = s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/, "$3/$2/$1");
// Remplace la date par un nombre de millisecondes pour trier numériquement
return $.tablesorter.formatFloat(new Date(s).getTime());
},
// set type, either numeric or text
type: 'numeric'
});
$("#observations table").tablesorter({
headers: {
1: {
sorter:'date_cel'
}
}
});
}
// Onglet Liste : Jquery => FancyBox
if ($("#observations ol").get() != '') {
90,9 → 114,16
bounds.extend(maLatLng);
google.maps.event.addListener(point, 'click', function() {
var limites = map.getBounds();
var centre = limites.getCenter();
var nordEst = limites.getNorthEast();
var centreSudLatLng = new google.maps.LatLng(nordEst.lat(), centre.lng());
infoBulle.open(map, this);
afficherMsgChargement();
infoBulle.open(map, this);
chargerFormatObs(this.stationId, '*');
map.panTo(centreSudLatLng);
});
points.push(point);