Use isModEnabled
This commit is contained in:
parent
502078cf37
commit
7aa371815a
@ -170,7 +170,7 @@ if (empty($reshook)) {
|
||||
$error++;
|
||||
}
|
||||
|
||||
if (!empty($conf->banque->enabled)) {
|
||||
if (isModEnabled('banque')) {
|
||||
// If bank module is on, account is required to enter a payment
|
||||
if (GETPOST('accountid') <= 0) {
|
||||
setEventMessages($langs->transnoentities('ErrorFieldRequired', $langs->transnoentities('AccountToCredit')), null, 'errors');
|
||||
@ -244,7 +244,7 @@ if (empty($reshook)) {
|
||||
$multicurrency_code[$key] = $tmpinvoice->multicurrency_code;
|
||||
}
|
||||
|
||||
if (!empty($conf->banque->enabled)) {
|
||||
if (isModEnabled('banque')) {
|
||||
// If the bank module is active, an account is required to input a payment
|
||||
if (GETPOST('accountid', 'int') <= 0) {
|
||||
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentities('AccountToCredit')), null, 'errors');
|
||||
@ -492,7 +492,7 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie
|
||||
|
||||
// Bank account
|
||||
print '<tr>';
|
||||
if (!empty($conf->banque->enabled)) {
|
||||
if (isModEnabled('banque')) {
|
||||
if ($facture->type != 2) {
|
||||
print '<td><span class="fieldrequired">'.$langs->trans('AccountToCredit').'</span></td>';
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user