Skip to content
Snippets Groups Projects
Commit a3a6b6df authored by Charles Benke's avatar Charles Benke
Browse files

Update box_ficheinter.php

External user show only is own intervention
parent 9291544e
No related branches found
No related tags found
No related merge requests found
......@@ -72,8 +72,10 @@ class box_ficheinter extends ModeleBoxes
$sql.= ", ".MAIN_DB_PREFIX."fichinter as f";
$sql.= " WHERE f.fk_soc = s.rowid ";
$sql.= " AND f.entity = ".$conf->entity;
if (! $user->rights->societe->client->voir)
if (! $user->rights->societe->client->voir && !$user->societe_id)
$sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
if($user->societe_id) $sql.= " AND s.rowid = ".$user->societe_id;
$sql.= " ORDER BY f.tms DESC";
$sql.= $db->plimit($max, 0);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment