Subversion Repositories eFlore/Applications.coel

Compare Revisions

Ignore whitespace Rev 1690 → Rev 1691

/trunk/jrest/services/CoelStructure.php
68,8 → 68,14
$whereClause = array();
if(isset($p['id_projet'])) $whereClause[] = "cs_ce_projet = {$p['id_projet']}";
if(isset($p['id_structure'])) $whereClause[] = "cs_id_structure = {$p['id_structure']}";
if(isset($p['recherche'])) $whereClause[] = "(" . implode(" OR ", array("cs_nom LIKE {$p['recherche']}", "cs_ville LIKE {$p['recherche']}")) . ")";
 
if(isset($p['recherche'])) {
if(@$this->searchCity && trim($this->searchCity) == true) {
$whereClause[] = "(" . implode(" OR ", array("cs_nom LIKE {$p['recherche']}", "cs_ville LIKE {$p['recherche']}")) . ")";
} else {
$whereClause[] = "cs_nom LIKE {$p['recherche']}";
}
}
 
// Construction de la requĂȘte
$requete = sprintf(