update code
This commit is contained in:
parent
36f2c139e5
commit
d5df85fd3e
@ -26,7 +26,7 @@ require_once DOL_DOCUMENT_ROOT.'/stripe/class/stripe.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/compta/bank/class/account.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
if (!empty($conf->accounting->enabled)) {
|
||||
if (isModEnabled('accounting')) {
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingjournal.class.php';
|
||||
}
|
||||
|
||||
|
||||
@ -573,7 +573,7 @@ if ($action != 'edit' && $action != 'create') { // If not bank account yet, $ac
|
||||
}
|
||||
|
||||
// Accountancy code
|
||||
if (!empty($conf->accounting->enabled)) {
|
||||
if (isModEnabled('accounting')) {
|
||||
print '<tr><td>'.$langs->trans("AccountancyCode").'</td>';
|
||||
print '<td>'.$object->accountancy_code.'</td></tr>';
|
||||
}
|
||||
|
||||
@ -1155,7 +1155,7 @@ if ($action == 'create' || $action == 'adduserldap') {
|
||||
}
|
||||
|
||||
// Accountancy code
|
||||
if (!empty($conf->accounting->enabled)) {
|
||||
if (isModEnabled('accounting')) {
|
||||
print '<tr><td>'.$langs->trans("AccountancyCode").'</td>';
|
||||
print '<td>';
|
||||
print '<input type="text" class="maxwidthonsmartphone" name="accountancy_code" value="'.dol_escape_htmltag(GETPOST('accountancy_code', 'alphanohtml')).'">';
|
||||
@ -2540,7 +2540,7 @@ if ($action == 'create' || $action == 'adduserldap') {
|
||||
}
|
||||
|
||||
// Accountancy code
|
||||
if (!empty($conf->accounting->enabled)) {
|
||||
if (isModEnabled('accounting')) {
|
||||
print "<tr>";
|
||||
print '<td class="titlefieldcreate">'.$langs->trans("AccountancyCode").'</td>';
|
||||
print '<td>';
|
||||
|
||||
@ -201,7 +201,7 @@ if (isModEnabled("product") || isModEnabled("service")) {
|
||||
if (isModEnabled("propal") || isModEnabled('commande') || !empty($conf->ficheinter->enabled) || isModEnabled('contrat')) {
|
||||
$tmparray['comm/index.php?mainmenu=commercial&leftmenu='] = 'CommercialArea';
|
||||
}
|
||||
if (!empty($conf->comptabilite->enabled) || !empty($conf->accounting->enabled)) {
|
||||
if (!empty($conf->comptabilite->enabled) || isModEnabled('accounting')) {
|
||||
$tmparray['compta/index.php?mainmenu=compta&leftmenu='] = 'AccountancyTreasuryArea';
|
||||
}
|
||||
if (isModEnabled('adherent')) {
|
||||
|
||||
@ -83,7 +83,7 @@ class AccountingAccountTest extends PHPUnit\Framework\TestCase
|
||||
global $conf,$user,$langs,$db;
|
||||
$db->begin(); // This is to have all actions inside a transaction even if test launched without suite.
|
||||
|
||||
if (empty($conf->accounting->enabled)) {
|
||||
if (!isModEnabled('accounting')) {
|
||||
print __METHOD__." module accouting must be enabled.\n"; exit(-1);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user