forked from Wavyzz/dolibarr
Use isModEnabled
This commit is contained in:
@@ -63,7 +63,7 @@ $hookmanager->initHooks(array('sellsjournal'));
|
||||
$parameters = array();
|
||||
|
||||
// Security check
|
||||
if (empty($conf->accounting->enabled)) {
|
||||
if (!isModEnabled('accounting')) {
|
||||
accessforbidden();
|
||||
}
|
||||
if ($user->socid > 0) {
|
||||
|
||||
@@ -83,7 +83,7 @@ if (!is_array($journal_data)) {
|
||||
}
|
||||
|
||||
// Security check
|
||||
if (empty($conf->accounting->enabled)) {
|
||||
if (!isModEnabled('accounting')) {
|
||||
accessforbidden();
|
||||
}
|
||||
if ($user->socid > 0) {
|
||||
|
||||
@@ -42,7 +42,7 @@ $codeventil = GETPOST('codeventil', 'int');
|
||||
$id = GETPOST('id', 'int');
|
||||
|
||||
// Security check
|
||||
if (empty($conf->accounting->enabled)) {
|
||||
if (!isModEnabled('accounting')) {
|
||||
accessforbidden();
|
||||
}
|
||||
if ($user->socid > 0) {
|
||||
|
||||
@@ -89,7 +89,7 @@ if (!$sortorder) {
|
||||
$formaccounting = new FormAccounting($db);
|
||||
|
||||
// Security check
|
||||
if (empty($conf->accounting->enabled)) {
|
||||
if (!isModEnabled('accounting')) {
|
||||
accessforbidden();
|
||||
}
|
||||
if ($user->socid > 0) {
|
||||
|
||||
@@ -106,7 +106,7 @@ $accountingAccount = new AccountingAccount($db);
|
||||
$chartaccountcode = dol_getIdFromCode($db, $conf->global->CHARTOFACCOUNTS, 'accounting_system', 'rowid', 'pcg_version');
|
||||
|
||||
// Security check
|
||||
if (empty($conf->accounting->enabled)) {
|
||||
if (!isModEnabled('accounting')) {
|
||||
accessforbidden();
|
||||
}
|
||||
if ($user->socid > 0) {
|
||||
|
||||
Reference in New Issue
Block a user