From 0475cb8018e86aefa3b62e5281dcbbc3b13861b6 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 9 Apr 2018 10:47:26 +0200 Subject: [PATCH] FIX Permission for bookkeeper --- htdocs/admin/dict.php | 1 + htdocs/compta/bank/list.php | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/admin/dict.php b/htdocs/admin/dict.php index ee09d3458a7..d8d2382a59f 100644 --- a/htdocs/admin/dict.php +++ b/htdocs/admin/dict.php @@ -53,6 +53,7 @@ $code=GETPOST('code','alpha'); $allowed=$user->admin; if ($id == 7 && ! empty($user->rights->accounting->chartofaccount)) $allowed=1; // Tax page allowed to manager of chart account if ($id == 10 && ! empty($user->rights->accounting->chartofaccount)) $allowed=1; // Vat page allowed to manager of chart account +if ($id == 17 && ! empty($user->rights->accounting->chartofaccount)) $allowed=1; // Dictionary with type of expense report and accounting account allowed to manager of chart account if (! $allowed) accessforbidden(); $acts[0] = "activate"; diff --git a/htdocs/compta/bank/list.php b/htdocs/compta/bank/list.php index 54e011d9db3..e3c2a5b94a9 100644 --- a/htdocs/compta/bank/list.php +++ b/htdocs/compta/bank/list.php @@ -54,7 +54,8 @@ $optioncss = GETPOST('optioncss','alpha'); // Security check if ($user->societe_id) $socid=$user->societe_id; -$result=restrictedArea($user,'banque'); +if (! empty($user->rights->accounting->chartofaccount)) $allowed=1; // Dictionary with list of banks accounting account allowed to manager of chart account +if (! $allowed) $result=restrictedArea($user,'banque'); $diroutputmassaction=$conf->bank->dir_output . '/temp/massgeneration/'.$user->id;