Ajout information rechRefType

This commit is contained in:
Michael RICOIS 2011-12-12 09:35:01 +00:00
parent 00fb6eba2a
commit 451701afa0

View File

@ -236,10 +236,16 @@ class WsScore
{ {
$iDbCrm = new WDB('sdv1'); $iDbCrm = new WDB('sdv1');
$rep=$iDbCrm->select( $rep=$iDbCrm->select(
'utilisateurs u, clients c', 'utilisateurs u, clients c',
'u.login, u.id, u.email, u.password, u.idClient, u.typeCompte, u.actif, u.filtre_ip, u.civilite, u.nom, u.prenom, u.tel, u.fax, u.mobile, u.profil, u.raisonSociale, u.siret, u.adrNum, u.adrIndRep, u.adrTypeVoie, u.adrLibVoie, u.adrCp, u.adrVille, u.adrComp, u.tel, u.fax, u.mobile, u.pref, u.profil, u.dateInscription, u.dateValidation, u.nombreConnexions, u.dateDerniereConnexion, u.droits, u.referenceParDefaut, u.nbReponses, u.formatMail, u.dateDebutCompte, u.dateFinCompte, u.maxFicheId, c.droits AS droitsClients, c.test AS clientTest, c.typeScore, c.timeout', 'u.login, u.id, u.email, u.password, u.idClient, u.typeCompte, u.actif, u.filtre_ip, u.civilite,'.
"u.login='$login' AND u.idClient=c.id AND u.actif=1 AND u.deleted=0 AND c.actif='Oui'", ' u.nom, u.prenom, u.tel, u.fax, u.mobile, u.profil, u.raisonSociale, u.siret, u.adrNum,'.
false, MYSQL_ASSOC ' u.adrIndRep, u.adrTypeVoie, u.adrLibVoie, u.adrCp, u.adrVille, u.adrComp, u.tel, u.fax,'.
' u.mobile, u.pref, u.rechRefType, u.profil, u.dateInscription, u.dateValidation, u.nombreConnexions,'.
' u.dateDerniereConnexion, u.droits, u.referenceParDefaut, u.nbReponses, u.formatMail,'.
' u.dateDebutCompte, u.dateFinCompte, u.maxFicheId, c.droits AS droitsClients, c.test AS clientTest,'.
' c.typeScore, c.timeout',
"u.login='$login' AND u.idClient=c.id AND u.actif=1 AND u.deleted=0 AND c.actif='Oui'",
false, MYSQL_ASSOC
); );
$tabRep = $rep[0]; $tabRep = $rep[0];
if (count($rep)>0) if (count($rep)>0)
@ -251,48 +257,49 @@ class WsScore
{ {
$timeOutSec=$tabRep['timeout']*60; $timeOutSec=$tabRep['timeout']*60;
if ($timeOutSec==0) $timeOutSec=1800; if ($timeOutSec==0) $timeOutSec=1800;
$this->tabInfoUser=array( $this->tabInfoUser = array(
'login'=> $login, 'login' => $login,
'id'=> $tabRep['id'], 'id' => $tabRep['id'],
'email'=> $tabRep['email'], 'email' => $tabRep['email'],
'typeCompte'=> $tabRep['typeCompte'], 'typeCompte' => $tabRep['typeCompte'],
'idClient'=> $tabRep['idClient'], 'idClient' => $tabRep['idClient'],
'filtre_ip'=> $tabRep['filtre_ip'], 'filtre_ip' => $tabRep['filtre_ip'],
'ipPasserelle'=> '', 'ipPasserelle' => '',
'ipConnexion'=> $ipConnexion, 'ipConnexion' => $ipConnexion,
'civilite'=> $tabRep['civilite'], 'civilite' => $tabRep['civilite'],
'nom'=> $tabRep['nom'], 'nom' => $tabRep['nom'],
'prenom'=> $tabRep['prenom'], 'prenom' => $tabRep['prenom'],
'raisonSociale'=> $tabRep['raisonSociale'], 'raisonSociale' => $tabRep['raisonSociale'],
'siret'=> $tabRep['siret'], 'siret' => $tabRep['siret'],
'adrNum'=> $tabRep['adrNum'], 'adrNum' => $tabRep['adrNum'],
'adrIndRep'=> $tabRep['adrIndRep'], 'adrIndRep' => $tabRep['adrIndRep'],
'adrTypeVoie'=> $tabRep['adrTypeVoie'], 'adrTypeVoie' => $tabRep['adrTypeVoie'],
'adrLibVoie'=> $tabRep['adrLibVoie'], 'adrLibVoie' => $tabRep['adrLibVoie'],
'adrCp'=> $tabRep['adrCp'], 'adrCp' => $tabRep['adrCp'],
'adrVille'=> $tabRep['adrVille'], 'adrVille' => $tabRep['adrVille'],
'adrComp'=> $tabRep['adrComp'], 'adrComp' => $tabRep['adrComp'],
'tel'=> $tabRep['tel'], 'tel' => $tabRep['tel'],
'fax'=> $tabRep['fax'], 'fax' => $tabRep['fax'],
'mobile'=> $tabRep['mobile'], 'mobile' => $tabRep['mobile'],
'pref'=> $tabRep['pref'], 'pref' => $tabRep['pref'],
'profil'=> $tabRep['profil'], 'rechRefType' => $tabRep['rechRefType'],
'dateInscription'=> $tabRep['dateInscription'], 'profil' => $tabRep['profil'],
'dateValidation'=> $tabRep['dateValidation'], 'dateInscription' => $tabRep['dateInscription'],
'nombreConnexions'=> $tabRep['nombreConnexions'], 'dateValidation' => $tabRep['dateValidation'],
'dateDerniereConnexion'=> $tabRep['dateDerniereConnexion'], 'nombreConnexions' => $tabRep['nombreConnexions'],
'droits'=> $tabRep['droits'], 'dateDerniereConnexion' => $tabRep['dateDerniereConnexion'],
'droitsClients'=> $tabRep['droitsClients'], 'droits' => $tabRep['droits'],
'timeout'=> $timeOutSec, 'droitsClients' => $tabRep['droitsClients'],
'clientTest'=> $tabRep['clientTest'], 'timeout' => $timeOutSec,
'typeScore'=> $tabRep['typeScore'], 'clientTest' => $tabRep['clientTest'],
'nbReponses'=> $tabRep['nbReponses'], 'typeScore' => $tabRep['typeScore'],
'formatMail'=> $tabRep['formatMail'], 'nbReponses' => $tabRep['nbReponses'],
'referenceParDefaut'=> $tabRep['referenceParDefaut'], 'formatMail' => $tabRep['formatMail'],
'dateDebutCompte'=> $tabRep['dateDebutCompte'], 'referenceParDefaut' => $tabRep['referenceParDefaut'],
'dateFinCompte'=> $tabRep['dateFinCompte'], 'dateDebutCompte' => $tabRep['dateDebutCompte'],
'maxFicheId'=> $tabRep['maxFicheId'], 'dateFinCompte' => $tabRep['dateFinCompte'],
'typeScore' => $tabRep['typeScore'], 'maxFicheId' => $tabRep['maxFicheId'],
'typeScore' => $tabRep['typeScore'],
); );
debugLog('W',"CheckAuth $login/$password OK", __LINE__,__FILE__, __FUNCTION__, __CLASS__); debugLog('W',"CheckAuth $login/$password OK", __LINE__,__FILE__, __FUNCTION__, __CLASS__);
return true; return true;