From 2850479c09f75e5fa234097c5526bc52daee46b5 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Fri, 5 Nov 2010 18:33:46 +0000 Subject: [PATCH] Fix: view only action of his company (external user) --- htdocs/comm/action/index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/comm/action/index.php b/htdocs/comm/action/index.php index 80924e10759..a65c70dad7f 100644 --- a/htdocs/comm/action/index.php +++ b/htdocs/comm/action/index.php @@ -185,7 +185,7 @@ $sql.= ', '.MAIN_DB_PREFIX.'user as u'; $sql.= ' WHERE a.fk_action = ca.id'; $sql.= ' AND a.fk_user_author = u.rowid'; $sql.= ' AND u.entity in (0,'.$conf->entity.')'; // To limit to entity -if ($user->societe_id) $sql.= ' AND u.fk_societe = '.$user->societe_id; // To limit to user company +if ($user->societe_id) $sql.= ' AND a.fk_soc = '.$user->societe_id; // To limit to external user company if ($pid) $sql.=" AND a.fk_project=".addslashes($pid); if ($_GET["action"] == 'show_day') {