Subversion Repositories eFlore/Applications.cel

Rev

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

Rev 1386 Rev 1425
Line 227... Line 227...
227
	*/
227
	*/
228
	private function formaterParametresObservation($parametres) {
228
	private function formaterParametresObservation($parametres) {
Line 229... Line 229...
229
		
229
		
Line 230... Line 230...
230
		if (($parametres['nom_sel_nn'] == '' || $parametres['nom_sel_nn'] == 0) && $parametres['nom_sel'] != '') {
230
		if (($parametres['nom_sel_nn'] == '' || $parametres['nom_sel_nn'] == 0) && $parametres['nom_sel'] != '') {
231
			
231
			
232
			$chercheur_infos_complementaires = new RechercheInfosTaxon($this->config);
232
			$chercheur_infos_complementaires = new RechercheInfosTaxonBeta($this->config);
Line 233... Line 233...
233
			// Utilisation d'un nom sans numéro nomenclatural, recherche d'une correspondance sur le nom
233
			// Utilisation d'un nom sans numéro nomenclatural, recherche d'une correspondance sur le nom
234
			$complement = $chercheur_infos_complementaires->rechercherInformationsComplementairesSurNom($parametres['nom_sel']);
234
			$complement = $chercheur_infos_complementaires->rechercherInformationsComplementairesSurNom($parametres['nom_sel']);
Line 239... Line 239...
239
				$parametres['nom_sel_nn'] = $complement[0][0];
239
				$parametres['nom_sel_nn'] = $complement[0][0];
240
			}
240
			}
Line 241... Line 241...
241
			
241
			
242
			$parametres['nom_referentiel'] = 'bdtfx_v1';
242
			$parametres['nom_referentiel'] = 'bdtfx_v1';
243
		}
243
		}
244
		
244
 
245
		if ($parametres['nom_sel_nn'] != '') {
245
		if ($parametres['nom_sel_nn'] != '') {
246
			// Utilisation d'un nom faisant parti du referentiel : recherche du nom valide correspondant
246
			// Utilisation d'un nom faisant parti du referentiel : recherche du nom valide correspondant
247
			$chercheur_infos_complementaires = new RechercheInfosTaxon($this->config);
247
			$chercheur_infos_complementaires = new RechercheInfosTaxonBeta($this->config);
248
			$complement = $chercheur_infos_complementaires->rechercherInformationsComplementairesSurNumNom($parametres['nom_sel_nn']);
-
 
249
			
248
			$complement = $chercheur_infos_complementaires->rechercherInformationsComplementairesSurNumNom($parametres['nom_sel_nn']);
250
			$parametres['nom_ret']=$complement['Nom_Retenu'];
249
			$parametres['nom_ret']=$complement['Nom_Retenu'];
251
	        $parametres['nom_ret_nn']=$complement['Num_Nom_Retenu'];
250
	        $parametres['nom_ret_nn']=$complement['Num_Nom_Retenu'];
252
	        $parametres['nt']=$complement['Num_Taxon'];
251
	        $parametres['nt']=$complement['Num_Taxon'];
Line 279... Line 278...
279
	            	$parametres['ce_zone_geo'] = $this->obtenirCodeInseeCommunePourNomEtDepartement($parametres['zone_geo'], $parametres['ce_zone_geo']);
278
	            	$parametres['ce_zone_geo'] = $this->obtenirCodeInseeCommunePourNomEtDepartement($parametres['zone_geo'], $parametres['ce_zone_geo']);
280
	        	} else {     	        	 
279
	        	} else {     	        	 
281
	        	 	$parametres['ce_zone_geo'] = $this->convertirCodeInseeVersCodeZoneGeo($parametres['ce_zone_geo']);
280
	        	 	$parametres['ce_zone_geo'] = $this->convertirCodeInseeVersCodeZoneGeo($parametres['ce_zone_geo']);
282
	        	}
281
	        	}
283
        	}
282
        	}
284
        }  
283
        }
285
 
-
 
286
        //echo '<pre>'.print_r($parametres,true).'</pre>';exit;
-
 
Line 287... Line 284...
287
 
284
 
288
        // TODO : voir si l'on peut utiliser un des fonctions de la classe cel
285
        // TODO : voir si l'on peut utiliser un des fonctions de la classe cel
289
        if (isset($parametres['date_observation']) && $parametres['date_observation']!="null") {
286
        if (isset($parametres['date_observation']) && $parametres['date_observation']!="null") {
290
        	list($jour,$mois,$annee)=explode("/",$parametres['date_observation']);
287
        	list($jour,$mois,$annee)=explode("/",$parametres['date_observation']);