RNVP : Utilisation source et source_id pour l'appel à la méthode getRNVP

This commit is contained in:
Michael RICOIS 2016-01-25 16:26:22 +00:00
parent de73cb7c69
commit bad3645f08

View File

@ -2279,10 +2279,11 @@ class IdentiteController extends Zend_Controller_Action
$this->view->assign('adresse', $session->getAdresse());
if ($this->view->hasRight) {
$ws = new Scores_Ws_Client('entreprise', '0.9');
$source = str_pad($session->getSource(), 3, '0', STR_PAD_LEFT);
$sourceId = str_pad($session->getSourceId(), 17, '0', STR_PAD_LEFT);
$ws = new Scores_Ws_Client('entreprise', '0.9');
$params = new stdClass();
$params->companyId = $this->siret;
$params->type = 'siren';
$params->companyId = $source . $sourceId;
$response = $ws->getRNVP($params);
if ($response === false) {
$this->view->Error = true;