94,7 → 94,14 |
if ((count($this->ressources)) == 0){ |
$table_retour_json=array(); |
$table_retour_json['entete'] = $this->ajouterEnteteResultat(); |
$table_retour_json['resultat'] = $this->formaterResultats($resultat); |
} else { |
$table_retour_json = $resultat[0]; |
} |
return $table_retour_json; |
} |
|
public function formaterResultats($resultat) { |
foreach ($resultat as $tab) { |
$num = $tab['cle']; |
unset($tab['cle']); |
102,8 → 109,7 |
$resultat_json[$num][$param] = $valeur; |
} |
} |
$table_retour_json['resultat'] = $resultat_json; |
return $table_retour_json; |
return $resultat_json; |
} |
public function ajouterEnteteResultat() { |
|