Subversion Repositories eFlore/Applications.coel-consultation

Rev

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

Rev 31 Rev 67
Line 7... Line 7...
7
 * @category	php 5.2
7
 * @category	php 5.2
8
 * @author		Jean-Pascal MILCENT <jpm@tela-botanica.org>
8
 * @author		Jean-Pascal MILCENT <jpm@tela-botanica.org>
9
 * @copyright	2010 Tela-Botanica
9
 * @copyright	2010 Tela-Botanica
10
 * @license		http://www.cecill.info/licences/Licence_CeCILL_V2-fr.txt Licence CECILL
10
 * @license		http://www.cecill.info/licences/Licence_CeCILL_V2-fr.txt Licence CECILL
11
 * @license		http://www.gnu.org/licenses/gpl.html Licence GNU-GPL
11
 * @license		http://www.gnu.org/licenses/gpl.html Licence GNU-GPL
12
 * @version		SVN: $Id: StructureDao.php 31 2010-04-07 15:06:53Z jpm $
12
 * @version		SVN: $Id: StructureDao.php 67 2010-05-06 16:51:04Z jpm $
13
 *
13
 *
14
 */
14
 */
15
class StructureDao extends ColModele {
15
class StructureDao extends ColModele {
16
	const SERVICE_STRUCTURE = 'CoelStructure';
16
	const SERVICE_STRUCTURE = 'CoelStructure';
17
	const SERVICE_STRUCTURE_A_PERSONNE = 'CoelStructureAPersonne';
17
	const SERVICE_STRUCTURE_A_PERSONNE = 'CoelStructureAPersonne';
Line 50... Line 50...
50
	 */
50
	 */
51
	public function getPersonnel($id) {
51
	public function getPersonnel($id) {
52
		$url = $this->url_jrest.self::SERVICE_STRUCTURE_A_PERSONNE."/$id";
52
		$url = $this->url_jrest.self::SERVICE_STRUCTURE_A_PERSONNE."/$id";
53
		$json = file_get_contents($url);
53
		$json = file_get_contents($url);
54
		$donnees = json_decode($json, true);
54
		$donnees = json_decode($json, true);
55
		$this->nettoyerTableauDeTableauxAssoc($donnees);
55
		$this->nettoyerTableauDeTableauxAssoc($donnees['structuresAPersonne']);
56
		return $donnees;
56
		return $donnees['structuresAPersonne'];
57
	}
57
	}
58
}
58
}
59
?>
59
?>
60
60