Ajout de la fonction extract
This commit is contained in:
parent
915d54a719
commit
5bcee45652
@ -49,6 +49,20 @@ Class Ciblage
|
||||
}
|
||||
}
|
||||
|
||||
public function extract($structure)
|
||||
{
|
||||
$resultats = $this->execute(true);
|
||||
$total = array(
|
||||
'total' => count($resultats),
|
||||
'insee' => $this->calculRedevanceInsee(),
|
||||
'result'=> $resultats
|
||||
);
|
||||
foreach ($total['result']['matches'] as $element) {
|
||||
$siret[] = $element['attrs']['siren'].$element['attrs']['nic'];
|
||||
}
|
||||
return ($siret);
|
||||
}
|
||||
|
||||
public function calculRedevanceInsee()
|
||||
{
|
||||
$this->sphinx->SetFilter('presentrcs', array(0));
|
||||
|
Loading…
Reference in New Issue
Block a user