diff --git a/include/action.common.inc.php b/include/action.common.inc.php index 7273fdd4e..8b64a5ac9 100644 --- a/include/action.common.inc.php +++ b/include/action.common.inc.php @@ -156,7 +156,7 @@ if ($sub_action == 'detail') echo $retour; echo ''; } - else if ($g_user->can_read_action($ag_id) == true) + else if ($g_user->can_read_action($ag_id) == true || $act->ag_dest == -1) { echo $act->Display('READ', false, $base, $retour); } diff --git a/include/ajax_get_profile.php b/include/ajax_get_profile.php index 468dd02df..104a43c27 100644 --- a/include/ajax_get_profile.php +++ b/include/ajax_get_profile.php @@ -80,9 +80,9 @@ Effacer ce profil'; echo "

Impression

"; $profile_menu->printing($p_id); echo $add_one; - echo "

Action gestion accessible

"; + echo "

Action gestion accessible

"; $profile_menu->available_profile($p_id); - echo "

Dépôt de stock accessible

"; + echo "

Dépôt de stock accessible

"; $profile_menu->available_repository($p_id); } diff --git a/include/class_follow_up.php b/include/class_follow_up.php index 15591c435..b9cbbfc98 100644 --- a/include/class_follow_up.php +++ b/include/class_follow_up.php @@ -1259,11 +1259,9 @@ class Follow_Up $query .= ' and ag_state in (2,3) '; if (isset($_GET['only_internal'])) $query .= ' and f_id_dest=0 '; - if (!isset($all_action)) + if ( isset($all_action)) { $query .=" and (ag_owner='" . $_SESSION['g_user'] . "' or ".self::sql_security_filter($cn, "R")." )"; - } else { - $query .= "and ".self::sql_security_filter($cn,'R'); } if (isset($date_start) && isDate($date_start) != null) { @@ -1273,7 +1271,7 @@ class Follow_Up { $query.=" and ag_timestamp <= to_date('$date_end','DD.MM.YYYY')"; } - if (isset($ag_dest_query)&& ! isset($all_action) && $ag_dest_query != -1) + if (isset($ag_dest_query)&& ! isset($all_action) ) { $query.= " and ag_dest = " . sql_string($ag_dest_query); } @@ -1281,6 +1279,7 @@ class Follow_Up { $query = " and ag_id= " . $ag_id; } + var_dump( $query.$str); return $query . $str; } diff --git a/include/dashboard.inc.php b/include/dashboard.inc.php index f5dd3e960..825747d7e 100644 --- a/include/dashboard.inc.php +++ b/include/dashboard.inc.php @@ -23,7 +23,7 @@ $Operation=new Follow_Up($cn); $last_operation=$Operation->get_today(); $Ledger=new Acc_Ledger($cn,0); $last_ledger=array(); -$last_ledger=$Ledger->get_last(10); +$last_ledger=$Ledger->get_last(20); ob_start(); require_once('template/dashboard.php');