Subversion Repositories eFlore/Applications.cel

Rev

Rev 490 | Rev 492 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 490 Rev 491
Line 33... Line 33...
33
		<!-- Javascript : appli carto -->
33
		<!-- Javascript : appli carto -->
34
		<script type="text/javascript">
34
		<script type="text/javascript">
35
		//<![CDATA[
35
		//<![CDATA[
36
			var markerClusterer = null;
36
			var markerClusterer = null;
37
			var map = null;
37
			var map = null;
-
 
38
			var nt = '<?=$num_taxon?>';
38
			var infoBulle = new google.maps.InfoWindow();
39
			var infoBulle = new google.maps.InfoWindow();
39
			google.maps.event.addListener(infoBulle, 'domready', function() {
40
			google.maps.event.addListener(infoBulle, 'domready', function() {
40
				if ($("#observations table").get() != 'undefined') {
41
				if ($("#observations table").get() != 'undefined') {
41
					$("#observations table").tablesorter();
42
					$("#observations table").tablesorter();
42
				}
43
				}
Line 86... Line 87...
86
 
87
 
87
			function chargerFormatObs(stationId, format) {
88
			function chargerFormatObs(stationId, format) {
88
				var url = '<?=$url_base?>carto?carte=observations'+
89
				var url = '<?=$url_base?>carto?carte=observations'+
89
					'&utilisateur=<?=$utilisateur?>'+
90
					'&utilisateur=<?=$utilisateur?>'+
90
					'&projet=<?=$projet?>'+
91
					'&projet=<?=$projet?>'+
91
					'&num_taxon=<?=$num_taxon?>'+
92
					'&num_taxon='+nt+
92
					'&dept=<?=$dept?>'+
93
					'&dept=<?=$dept?>'+
93
					'&format='+format+'&station='+stationId;
94
					'&format='+format+'&station='+stationId;
94
				$.get(url, function(observations){
95
				$.get(url, function(observations){
95
					infoBulle.setContent(observations);
96
					infoBulle.setContent(observations);
Line 113... Line 114...
113
				document.getElementById('panneau-lateral').style.display = 'none';
114
				document.getElementById('panneau-lateral').style.display = 'none';
114
				document.getElementById('pl-ouverture').style.display = 'block';
115
				document.getElementById('pl-ouverture').style.display = 'block';
115
				google.maps.event.trigger(map, 'resize');
116
				google.maps.event.trigger(map, 'resize');
116
			};
117
			};
Line 117... Line 118...
117
 
118
 
118
			function filtrerParTaxon(nt) {
119
			function filtrerParTaxon(num_taxon) {
119
				var url = '<?=$url_cel_carto?>/carte-defaut-json/<?=$utilisateur?>/<?=$projet?>/<?=$dept?>/'+nt+'?formatRetour=jsonp&callback=?';
120
				var url = '<?=$url_cel_carto?>/carte-defaut-json/<?=$utilisateur?>/<?=$projet?>/<?=$dept?>/'+num_taxon+'?formatRetour=jsonp&callback=?';
120
				$.getJSON(url, function (observations) {
121
				$.getJSON(url, function (observations) {
121
					obs = observations;
122
					obs = observations;
122
					alert(obs.nombre);
123
					nt = num_taxon;
123
					refreshMap();
124
					refreshMap();
124
				});
125
				});
Line 125... Line 126...
125
			};
126
			};
Line 166... Line 167...
166
			<div id="pl-entete">
167
			<div id="pl-entete">
167
				<div id="pl-ouverture">Panneau >></div>
168
				<div id="pl-ouverture">Panneau >></div>
168
				<div id="pl-fermeture"><< Fermer [x]</div>
169
				<div id="pl-fermeture"><< Fermer [x]</div>
169
			</div>
170
			</div>
170
			<div id="pl-corps">
171
			<div id="pl-corps">
171
				<ul>
172
				<ol>
172
				<? foreach ($taxons as $taxon) : ?>
173
				<? foreach ($taxons as $taxon) : ?>
173
					<li>
174
					<li>
174
						<a href="#" onclick="filtrerParTaxon(<?=$taxon['nt']?>);">
175
						<a href="#" onclick="filtrerParTaxon(<?=$taxon['nt']?>);">
175
							<?=$taxon['nom']?> 
176
							<?=$taxon['nom']?> 
176
							<span class="famille"><?=$taxon['famille']?></span>
177
							<span class="famille"><?=$taxon['famille']?></span>
177
						</a>
178
						</a>
178
					</li>
179
					</li>
179
				<? endforeach; ?>
180
				<? endforeach; ?>
180
				</ul>
181
				</ol>
181
			</div>
182
			</div>
182
		</div>
183
		</div>
183
		<div id="carte"></div>
184
		<div id="carte"></div>
Line 184... Line 185...
184
		
185