From ba4b75f59a6e61e5f85d1a86cd2da9e41d5c8831 Mon Sep 17 00:00:00 2001 From: Dany De Bontridder Date: Fri, 4 Sep 2015 10:50:58 +0200 Subject: [PATCH] Esthetic : message is nothing found in menu --- html/direct.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/html/direct.php b/html/direct.php index 242e3d9ea..1c6ef2048 100644 --- a/html/direct.php +++ b/html/direct.php @@ -27,7 +27,7 @@ global $g_user; $g_user=new User($cn); $g_user->Check(); $g_user->check_dossier($_GET['gDossier']); -$res=$cn->exec_sql("select distinct code,description from get_profile_menu($1) where code ~* $2 or description ~* $3 limit 8",array($g_user->login,$_POST['acs'],$_POST['acs'])); +$res=$cn->exec_sql("select code,description from get_profile_menu($1) where code ~* $2 or description ~* $3 limit 8",array($g_user->get_profile(),$_POST['acs'],$_POST['acs'])); $nb=Database::num_row($res); echo ""; +if ( $nb == 0 ) { + echo _('Aucune correspondance'); +} ?>