Formulaire recherche actionnaire

This commit is contained in:
Michael RICOIS 2011-07-08 15:14:42 +00:00
parent a246df0e00
commit d86eb9a03d
2 changed files with 5 additions and 31 deletions

View File

@ -31,23 +31,11 @@ foreach (array('siret',
<div class="fieldgrp">
<label>RAISON SOCIALE / NOM</label>
<input type="text" name="formR[actNom]" value="<?=$formR['actNom']?>" size="30" maxlength="40" style="vertical-align:middle;" />
<input type="text" name="formR[actNom]" value="<?=$formR['actNomRs']?>" size="30" maxlength="40" style="vertical-align:middle;" />
</div>
<div class="fieldgrp">
<label>PRENOM</label>
<input type="text" name="formR[actPrenom]" value="<?=$formR['actPrenom']?>" size="30" maxlength="40" />
</div>
<div class="fieldgrp">
<label>DATE NAISSANCE</label>
<input type="text" name="formR[naissJJ]" value="<?=$formR['naisJJ']?>" size="2" maxlength="2" /> /
<input type="text" name="formR[naissMM]" value="<?=$formR['naisMM']?>" size="2" maxlength="2" /> /
<input type="text" name="formR[naissAAAA]" value="<?=$formR['naisMM']?>" size="4" maxlength="4" />
</div>
<div class="fieldgrp">
<label>CP OU D&Eacute;P. / VILLE DE NAISSANCE</label>
<label>CP OU D&Eacute;P. / VILLE</label>
<input type="text" name="formR[cpVille]" value="<?=$formR['cpVille']?>" size="30" maxlength="250" />
</div>

View File

@ -154,25 +154,11 @@ if ($typeRech == 'ent') {
}
} elseif ($typeRech == 'act') {
$actNom = trim($formR['actNom']);
$actPrenom = trim($formR['actPrenom']);
$d = array();
$d[] = preg_replace('/[^0-9]/', '', trim($formR['naissAAAA']));
$d[] = preg_replace('/[^0-9]/', '', trim($formR['naissMM']));
$d[] = preg_replace('/[^0-9]/', '', trim($formR['naissJJ']));
$dateNaiss = '';
$i = 0;
foreach ($d as $item) {
if (empty($item)) break;
if ($i>0 && $i<count($d)) $dateNaiss.= '-';
$dateNaiss.= $item;
$i++;
}
$actNomRs = trim($formR['actNomRs']);
$pays = $formR['pays'];
$pctMin = preg_replace('/[^0-9]/', '', trim($formR['pctMin']));
$pctMax = preg_replace('/[^0-9]/', '', trim($formR['pctMax']));
$lieuNaiss = preg_replace('/ +/',' ', preg_replace('/[^0-9A-Z]/', ' ',
strtoupper(cleanstring($formR['cpVille']))));
$cpVille = preg_replace('/ +/',' ', preg_replace('/[^0-9A-Z]/', ' ',strtoupper(cleanstring($formR['cpVille']))));
}
@ -244,7 +230,7 @@ if ($typeRech=='ent' && $siret<>'') {
} elseif ($typeRech=='act') {
try {
$O = $client->searchAct(
$actNom, $actPrenom, $dateNaiss, $lieuNaiss, $siret, $pays, $pctMin, $pctMax,
$actNomRs, $cpVille, $siret, $pays, $pctMin, $pctMax,
$tabInfo['nbReponses'], 200, false
);
echo '<!-- '.print_r($formR,1).' -->';