Modification du retour de la méthode extract

This commit is contained in:
Michael RICOIS 2012-02-22 09:29:53 +00:00
parent 9a8d4b6967
commit c88eb0c2fb

View File

@ -49,18 +49,19 @@ Class Ciblage
}
}
public function extract($structure)
public function extract()
{
$resultats = $this->execute(true);
$total = array(
'total' => count($resultats),
'insee' => $this->calculRedevanceInsee(),
'result'=> $resultats
);
foreach ($total['result']['matches'] as $element) {
$siret = array();
foreach ($resutlats['matches'] as $element) {
$siret[] = $element['attrs']['siren'].$element['attrs']['nic'];
}
return ($siret);
$total = array(
'total' => count($resultats),
'insee' => $this->calculRedevanceInsee(),
'result'=> $siret
);
return $total;
}
public function calculRedevanceInsee()