Subversion Repositories eFlore/Applications.cel

Rev

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

Rev 2462 Rev 2560
Line 117... Line 117...
117
					" AND (".
117
					" AND (".
118
					$this->construireWhereRectangleStationOR()." OR ".
118
					$this->construireWhereRectangleStationOR()." OR ".
119
					$this->construireWhereRectangleCommuneOR().") ".
119
					$this->construireWhereRectangleCommuneOR().") ".
120
					$this->construireWhereDept().
120
					$this->construireWhereDept().
121
                    $this->construireWhereCommune().
121
                    $this->construireWhereCommune().
-
 
122
                    $this->construireWherePays().
122
                    $this->construireWhereUtilisateur().
123
                    $this->construireWhereUtilisateur().
123
					$this->construireWhereNumTaxonAvecSousTaxons().
124
					$this->construireWhereNumTaxonAvecSousTaxons().
124
					$this->construireWhereNomTaxon().
125
					$this->construireWhereNomTaxon().
125
					$this->construireWhereReferentiel().
126
					$this->construireWhereReferentiel().
126
					$this->construireWhereDate().
127
					$this->construireWhereDate().
Line 155... Line 156...
155
					" AND (".
156
					" AND (".
156
					$this->construireWhereRectangleStationOR()." OR ".
157
					$this->construireWhereRectangleStationOR()." OR ".
157
					$this->construireWhereRectangleCommuneOR().") ".
158
					$this->construireWhereRectangleCommuneOR().") ".
158
					$this->construireWhereDept().
159
					$this->construireWhereDept().
159
                    $this->construireWhereCommune().
160
                    $this->construireWhereCommune().
-
 
161
                    $this->construireWherePays().
160
                    $this->construireWhereUtilisateur().
162
                    $this->construireWhereUtilisateur().
161
					$this->construireWhereNumTaxonAvecSousTaxons().
163
					$this->construireWhereNumTaxonAvecSousTaxons().
162
					$this->construireWhereNomTaxon().
164
					$this->construireWhereNomTaxon().
163
					$this->construireWhereReferentiel().
165
					$this->construireWhereReferentiel().
164
					$this->construireWhereDate().
166
					$this->construireWhereDate().
Line 340... Line 342...
340
						'	LEFT JOIN cel_zones_geo AS zg '.
342
						'	LEFT JOIN cel_zones_geo AS zg '.
341
						"		ON (zg.nom = co.zone_geo AND zg.id_zone_geo = co.ce_zone_geo) ".
343
						"		ON (zg.nom = co.zone_geo AND zg.id_zone_geo = co.ce_zone_geo) ".
342
						"WHERE transmission = '1' ".
344
						"WHERE transmission = '1' ".
343
						(($this->communeEstDemandee()) ? $this->construireWhereCommuneSansCoordonneesAvecSensibles() : $this->construireWhereCoordonneesSansSensibles()).
345
						(($this->communeEstDemandee()) ? $this->construireWhereCommuneSansCoordonneesAvecSensibles() : $this->construireWhereCoordonneesSansSensibles()).
344
						$this->construireWhereDept().
346
						$this->construireWhereDept().
-
 
347
						$this->construireWherePays().
345
						$this->construireWhereUtilisateur().
348
						$this->construireWhereUtilisateur().
346
						$this->construireWhereNumTaxonAvecSousTaxons().
349
						$this->construireWhereNumTaxonAvecSousTaxons().
347
						$this->construireWhereNomTaxon().
350
						$this->construireWhereNomTaxon().
348
						$this->construireWhereReferentiel().
351
						$this->construireWhereReferentiel().
349
						$this->construireWhereDate().
352
						$this->construireWhereDate().
Line 487... Line 490...
487
					'		ON (zg.nom = co.zone_geo AND zg.id_zone_geo = co.ce_zone_geo) '.
490
					'		ON (zg.nom = co.zone_geo AND zg.id_zone_geo = co.ce_zone_geo) '.
488
					"WHERE transmission = '1' ".
491
					"WHERE transmission = '1' ".
489
					"	AND nom_ret != '' ".
492
					"	AND nom_ret != '' ".
490
					$this->construireWhereDept().
493
					$this->construireWhereDept().
491
                    $this->construireWhereCommune().
494
                    $this->construireWhereCommune().
-
 
495
                    $this->construireWherePays().
492
                    $this->construireWhereUtilisateur().
496
                    $this->construireWhereUtilisateur().
493
					$this->construireWhereNumTaxon().
497
					$this->construireWhereNumTaxon().
494
					$this->construireWhereNomTaxon().
498
					$this->construireWhereNomTaxon().
495
					$this->construireWhereReferentiel().
499
					$this->construireWhereReferentiel().
496
					$this->construireWhereDate().
500
					$this->construireWhereDate().
Line 754... Line 758...
754
			($type == 'commentaire.obs' ? "	AND co.commentaire LIKE $param " : '').
758
			($type == 'commentaire.obs' ? "	AND co.commentaire LIKE $param " : '').
755
			($type == 'commentaire.*' ? " AND (co.commentaire LIKE $param OR ci.commentaire LIKE $param) " : '').
759
			($type == 'commentaire.*' ? " AND (co.commentaire LIKE $param OR ci.commentaire LIKE $param) " : '').
756
			$this->construireWhereCoordonnees().
760
			$this->construireWhereCoordonnees().
757
			$this->construireWhereDept().
761
			$this->construireWhereDept().
758
			$this->construireWhereCommune().
762
			$this->construireWhereCommune().
-
 
763
			$this->construireWherePays().
759
			$this->construireWhereUtilisateur().
764
			$this->construireWhereUtilisateur().
760
			$this->construireWhereNumTaxon().
765
			$this->construireWhereNumTaxon().
761
			$this->construireWhereNomTaxon().
766
			$this->construireWhereNomTaxon().
762
			$this->construireWhereReferentiel().
767
			$this->construireWhereReferentiel().
763
			$this->construireWhereProjet().
768
			$this->construireWhereProjet().
Line 921... Line 926...
921
			$zonegeo = Cel::db()->proteger($zonegeo);
926
			$zonegeo = Cel::db()->proteger($zonegeo);
922
			$sql = " AND ce_zone_geo = $zonegeo";
927
			$sql = " AND ce_zone_geo = $zonegeo";
923
		}
928
		}
924
		return $sql;
929
		return $sql;
925
	}
930
	}
-
 
931
	
-
 
932
	private function construireWherePays() {
-
 
933
		$sql = '';
-
 
934
		extract($this->parametres);
-
 
935
		if (isset($this->parametres['pays']) && !$this->etreNull($pays)) {
-
 
936
			$pays = Cel::db()->proteger($pays);
-
 
937
			$sql = " AND pays = $pays";
-
 
938
		}
-
 
939
		return $sql;
-
 
940
	}
Line 926... Line 941...
926
 
941
 
927
	private function construireWhereCommuneSansCoordonneesAvecSensibles() {
942
	private function construireWhereCommuneSansCoordonneesAvecSensibles() {
928
		$sql = '';
943
		$sql = '';
929
		// Récupération des coordonnées depuis l'id station
944
		// Récupération des coordonnées depuis l'id station