From c8bd77ddd7b1ace9c2fe3a065d3fb4ae88382263 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 5 Jun 2012 23:12:40 +0200 Subject: [PATCH] Fix: Missing permission check --- htdocs/compta/bank/ligne.php | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/htdocs/compta/bank/ligne.php b/htdocs/compta/bank/ligne.php index cbcc4451883..277f45e7c94 100644 --- a/htdocs/compta/bank/ligne.php +++ b/htdocs/compta/bank/ligne.php @@ -75,7 +75,7 @@ if ($action == 'confirm_delete_categ' && $confirm == "yes" && $user->rights->ban } } -if ($action == 'class') +if ($user->rights->banque->modifier && $action == 'class') { $sql = "DELETE FROM ".MAIN_DB_PREFIX."bank_class WHERE lineid = ".$rowid." AND fk_categ = ".$_POST["cat1"]; if (! $db->query($sql)) @@ -90,7 +90,7 @@ if ($action == 'class') } } -if ($action == "update") +if ($user->rights->banque->modifier && $action == "update") { $error=0; @@ -584,8 +584,11 @@ print ''; print ''; print ''; print ''.$langs->trans("Rubriques").''; -print ' '; -print ''; +if ($user->rights->banque->modifier) +{ + print ' '; + print ''; +} print ""; print "";