Merge pull request #7115 from atm-florian/dev_fix_accountancy
FIX accountancy right management on setup pages
This commit is contained in:
commit
441c4b9b71
@ -46,7 +46,7 @@ if ($cat_id == 0) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Security check
|
// Security check
|
||||||
if (! empty($user->rights->accountancy->chartofaccount))
|
if (empty($user->rights->accounting->chartofaccount))
|
||||||
{
|
{
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -57,7 +57,7 @@ $rowid=GETPOST('rowid','alpha');
|
|||||||
$code=GETPOST('code','alpha');
|
$code=GETPOST('code','alpha');
|
||||||
|
|
||||||
// Security access
|
// Security access
|
||||||
if (! empty($user->rights->accountancy->chartofaccount))
|
if (empty($user->rights->accounting->chartofaccount))
|
||||||
{
|
{
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -42,7 +42,7 @@ $langs->load("salaries");
|
|||||||
$langs->load("loan");
|
$langs->load("loan");
|
||||||
|
|
||||||
// Security check
|
// Security check
|
||||||
if (! empty($user->rights->accountancy->chartofaccount))
|
if (empty($user->rights->accounting->chartofaccount))
|
||||||
{
|
{
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -38,7 +38,7 @@ $langs->load("admin");
|
|||||||
$langs->load("accountancy");
|
$langs->load("accountancy");
|
||||||
|
|
||||||
// Security check
|
// Security check
|
||||||
if (empty($user->admin) || ! empty($user->rights->accountancy->chartofaccount))
|
if (empty($user->admin) && empty($user->rights->accounting->chartofaccount))
|
||||||
{
|
{
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -266,7 +266,7 @@ if (! empty($user->admin))
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Param a user $user->rights->accountancy->chartofaccount can access
|
// Param a user $user->rights->accounting->chartofaccount can access
|
||||||
foreach ($list as $key)
|
foreach ($list as $key)
|
||||||
{
|
{
|
||||||
print '<tr class="oddeven value">';
|
print '<tr class="oddeven value">';
|
||||||
|
|||||||
@ -41,7 +41,7 @@ $rowid=GETPOST('rowid','alpha');
|
|||||||
$code=GETPOST('code','alpha');
|
$code=GETPOST('code','alpha');
|
||||||
|
|
||||||
// Security access
|
// Security access
|
||||||
if (! empty($user->rights->accountancy->chartofaccount))
|
if (empty($user->rights->accounting->chartofaccount))
|
||||||
{
|
{
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user