diff --git a/htdocs/comm/propal/card.php b/htdocs/comm/propal/card.php index fb75b3f0c6b..553e3e8ea9c 100644 --- a/htdocs/comm/propal/card.php +++ b/htdocs/comm/propal/card.php @@ -6,7 +6,7 @@ * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2006 Andre Cianfarani * Copyright (C) 2010-2016 Juanjo Menent - * Copyright (C) 2010-2021 Philippe Grand + * Copyright (C) 2010-2022 Philippe Grand * Copyright (C) 2012-2013 Christophe Battarel * Copyright (C) 2012 Cedric Salvador * Copyright (C) 2013-2014 Florian Henry @@ -448,7 +448,7 @@ if (empty($reshook)) { $object->origin_id = GETPOST('originid'); // Multicurrency - if (!empty($conf->multicurrency->enabled)) { + if (isModEnabled("multicurrency")) { $object->multicurrency_code = GETPOST('multicurrency_code', 'alpha'); } @@ -1653,7 +1653,7 @@ if ($action == 'create') { $objectsrc->fetch_optionals(); $object->array_options = $objectsrc->array_options; - if (!empty($conf->multicurrency->enabled)) { + if (isModEnabled("multicurrency")) { if (!empty($objectsrc->multicurrency_code)) { $currency_code = $objectsrc->multicurrency_code; } @@ -1663,7 +1663,7 @@ if ($action == 'create') { } } } else { - if (!empty($conf->multicurrency->enabled) && !empty($soc->multicurrency_code)) { + if (isModEnabled("multicurrency") && !empty($soc->multicurrency_code)) { $currency_code = $soc->multicurrency_code; } } @@ -1865,7 +1865,7 @@ if ($action == 'create') { print ""; // Multicurrency - if (!empty($conf->multicurrency->enabled)) { + if (isModEnabled("multicurrency")) { print ''; print ''.$form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0).''; print ''; @@ -1937,7 +1937,7 @@ if ($action == 'create') { } print ''.$langs->trans('AmountTTC').''.price($objectsrc->total_ttc, 0, $langs, 1, -1, -1, $conf->currency).""; - if (!empty($conf->multicurrency->enabled)) { + if (isModEnabled("multicurrency")) { print ''.$langs->trans('MulticurrencyAmountHT').''.price($objectsrc->multicurrency_total_ht).''; print ''.$langs->trans('MulticurrencyAmountVAT').''.price($objectsrc->multicurrency_total_tva).""; print ''.$langs->trans('MulticurrencyAmountTTC').''.price($objectsrc->multicurrency_total_ttc).""; @@ -2518,7 +2518,7 @@ if ($action == 'create') { print ''; // Multicurrency - if (!empty($conf->multicurrency->enabled)) { + if (isModEnabled("multicurrency")) { // Multicurrency code print ''; print ''; @@ -2649,7 +2649,7 @@ if ($action == 'create') { print ''; - if (!empty($conf->multicurrency->enabled) && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) { + if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) { // Multicurrency Amount HT print ''; print '';
'.$form->editfieldkey('MulticurrencyAmountHT', 'multicurrency_total_ht', '', $object, 0).''.price($object->multicurrency_total_ht, '', $langs, 0, - 1, - 1, (!empty($object->multicurrency_code) ? $object->multicurrency_code : $conf->currency)).'