diff --git a/htdocs/compta/propal.php b/htdocs/compta/propal.php index 8d6e414bb8e..f94a5981976 100644 --- a/htdocs/compta/propal.php +++ b/htdocs/compta/propal.php @@ -1,6 +1,7 @@ * Copyright (C) 2004 Destailleur Laurent + * Copyright (C) 2004 Eric Seigne * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -264,36 +265,38 @@ if ($_GET["propalid"]) } print ""; /* - * + * Que si le module commande est actif ! * */ - $nb_commande = sizeof($propal->commande_liste_array()); - if ($nb_commande > 0) - { - $coms = $propal->commande_liste_array(); - print '
'; - - if ($nb_commande == 1) - - { - print "\n"; - } - else - { - print "\n"; + if($conf->commande->enabled) { + $nb_commande = sizeof($propal->commande_liste_array()); + if ($nb_commande > 0) + { + $coms = $propal->commande_liste_array(); + print '
Commande rattachée : "; - print ''; - print img_file(); - print ' '.$coms[$i].""; - print "
Commandes rattachées
'; + + if ($nb_commande == 1) - for ($i = 0 ; $i < $nb_commande ; $i++) - { - print '\n"; - print "\n"; - } - } - print "
'.$coms[$i]."
"; - } + { + print "Commande rattachée : "; + print ''; + print img_file(); + print ' '.$coms[$i].""; + print "\n"; + } + else + { + print "Commandes rattachées\n"; + + for ($i = 0 ; $i < $nb_commande ; $i++) + { + print ''.$coms[$i]."\n"; + print "\n"; + } + } + print ""; + } + } /* *