Fix: droit invalide

This commit is contained in:
Regis Houssin 2006-03-07 15:39:34 +00:00
parent 406ca23dd1
commit b376fda6c6
2 changed files with 2 additions and 2 deletions

View File

@ -59,7 +59,7 @@ $sql .= " WHERE s.fk_stcomm = st.id AND s.client=1";
if ($socidp) $sql .= " AND s.idp = $socidp";
if ($user->societe_id) $sql .= " AND s.idp = " .$user->societe_id;
if (!$user->rights->commercial->voir) $sql .= " AND s.idp = sc.fk_soc AND sc.fk_user = " .$user->id;
if (!$user->rights->commercial->client->voir) $sql .= " AND s.idp = sc.fk_soc AND sc.fk_user = " .$user->id;
if ($search_nom) $sql .= " AND s.nom like '%".addslashes(strtolower($search_nom))."%'";
if ($search_ville) $sql .= " AND s.ville like '%".addslashes(strtolower($search_ville))."%'";

View File

@ -98,7 +98,7 @@ class modCommercial extends DolibarrModules
$this->rights[$r][1] = 'Consulter tous les clients';
$this->rights[$r][2] = 'r';
$this->rights[$r][3] = 0;
$this->rights[$r][4] = 'main';
$this->rights[$r][4] = 'client';
$this->rights[$r][5] = 'voir';
$r++;
}