Modification appel affichage de la raison sociale sur les commandes greffes

This commit is contained in:
Michael RICOIS 2010-08-20 14:51:07 +00:00
parent f9755858a4
commit fee05435b8
3 changed files with 9 additions and 21 deletions

View File

@ -270,7 +270,7 @@ function listStatus(){
*/
function raisonSociale($siren){
global $client;
$rs = '<a href="./?page=greffescmd&q=rs" alt="'.$siren.
$rs = '<a href="./?page=saisieajax&q=greffescmd/rs" alt="'.$siren.
'" class="rs">Obtenir la raison sociale</a>';
return $rs;
}

View File

@ -110,6 +110,14 @@ switch ( $action ) {
//echo $q->getSql();
//print_r($q->getFlattenedParams());
echo $rows = $q->execute();
} elseif ($params[1]=='rs') {
try {
$O = $client->getIdentite($_REQUEST['siren'], 0, false);
echo $O['result']['Nom'];
} catch (SoapFault $fault) {
require_once 'soaperror.php';
processSoapFault($client,$fault,$tabInfo);
}
}
break;
//Gestion des logos

View File

@ -1,29 +1,9 @@
<?php
/*
* Liste des commandes passées sur infogreffe
*
*/
if ( isset($_REQUEST['rs']) ){
$client = new SoapClient( null,
array( 'trace' => 1,
'soap_version' => SOAP_1_1,
'location' => WEBSERVICE_URL,
'uri' => WEBSERVICE_URI,
'login' => $_SESSION['tabInfo']['login'],
'password' => $_SESSION['tabInfo']['password']
));
try {
$O = $client->getIdentite($_REQUEST['siren'], 0, false);
echo $O['result']['Nom'];
} catch (SoapFault $fault) {
require_once 'soaperror.php';
processSoapFault($client,$fault,$tabInfo);
}
exit;
}
?>
<style type="text/css">
table {width:100%; border-collapse:collapse; margin:5px 0;}