Subversion Repositories eFlore/Applications.coel-consultation

Compare Revisions

Ignore whitespace Rev 62 → Rev 61

/trunk/modeles/PersonneDao.php
23,14 → 23,11
* @return array un tableau contenant les informations sur la personne.
*/
public function getPersonne($id) {
$donnees = array();
if (is_numeric($id)) {
$url = $this->url_jrest.self::SERVICE_PERSONNE."/$id";
$json = file_get_contents($url);
$donnees = json_decode($json, true);
if ($donnees['nbElements'] == 1) {
$donnees = $donnees['personnes'][0];
}
$url = $this->url_jrest.self::SERVICE_PERSONNE."/$id";
$json = file_get_contents($url);
$donnees = json_decode($json, true);
if ($donnees['nbElements'] == 1) {
$donnees = $donnees['personnes'][0];
}
return $donnees;
}