update code toward php8 compliance
This commit is contained in:
parent
1ab58434c2
commit
608dda677a
@ -53,7 +53,7 @@ $langs->loadLangs(array("admin", "compta"));
|
|||||||
if ($user->socid > 0) {
|
if ($user->socid > 0) {
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
if (empty($user->rights->accounting->fiscalyear->write)) { // If we can read accounting records, we should be able to see fiscal year.
|
if (!$user->hasRight('accounting', 'fiscalyear', 'write')) { // If we can read accounting records, we should be able to see fiscal year.
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -34,7 +34,7 @@ $langs->loadLangs(array("admin", "compta"));
|
|||||||
if ($user->socid > 0) {
|
if ($user->socid > 0) {
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
if (empty($user->rights->accounting->fiscalyear->write)) {
|
if (!$user->hasRight('accounting', 'fiscalyear', 'write')) {
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -45,7 +45,7 @@ $langs->loadLangs(array("companies", "compta", "accountancy", "products"));
|
|||||||
if (!isModEnabled('accounting')) {
|
if (!isModEnabled('accounting')) {
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
if (empty($user->rights->accounting->bind->write)) {
|
if (!$user->hasRight('accounting', 'bind', 'write')) {
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user