Skip to content
Snippets Groups Projects
Commit d4057c3f authored by aspangaro's avatar aspangaro
Browse files

Fixed: Correct problem of rights beetween tax and salaries module

parent c85b7932
No related branches found
No related tags found
No related merge requests found
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
/* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org> /* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2010 Regis Houssin <regis.houssin@capnetworks.com> * Copyright (C) 2005-2010 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2011-2014 Alexandre Spangaro <aspangaro.dolibarr@gmail.com> * Copyright (C) 2011-2016 Alexandre Spangaro <aspangaro.dolibarr@gmail.com>
* Copyright (C) 2011-2014 Juanjo Menent <jmenent@2byte.es> * Copyright (C) 2011-2014 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr> * Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr>
* *
...@@ -86,7 +86,7 @@ if (GETPOST("mode") != 'sconly') ...@@ -86,7 +86,7 @@ if (GETPOST("mode") != 'sconly')
} }
// Payment Salary // Payment Salary
if ($conf->salaries->enabled) if (! empty($conf->salaries->enabled) && $user->rights->salaries->read)
{ {
if (empty($_GET["mode"]) || $_GET["mode"] != 'sconly') if (empty($_GET["mode"]) || $_GET["mode"] != 'sconly')
{ {
...@@ -167,7 +167,7 @@ if ($conf->salaries->enabled) ...@@ -167,7 +167,7 @@ if ($conf->salaries->enabled)
} }
if ($conf->tax->enabled) if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire)
{ {
// Social contributions only // Social contributions only
if (GETPOST("mode") != 'sconly') if (GETPOST("mode") != 'sconly')
...@@ -278,7 +278,7 @@ if ($conf->tax->enabled) ...@@ -278,7 +278,7 @@ if ($conf->tax->enabled)
} }
// VAT // VAT
if ($conf->tax->enabled) if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire)
{ {
if (empty($_GET["mode"]) || $_GET["mode"] != 'sconly') if (empty($_GET["mode"]) || $_GET["mode"] != 'sconly')
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment