diff --git a/htdocs/contrat/card.php b/htdocs/contrat/card.php index 872dbc07784..911d1556225 100644 --- a/htdocs/contrat/card.php +++ b/htdocs/contrat/card.php @@ -1442,7 +1442,7 @@ else print '
| '.$langs->trans("ServiceNb",$cursorline).' | '; print ''.$langs->trans("VAT").' | '; print ''.$langs->trans("PriceUHT").' | '; + if (!empty($conf->multicurrency->enabled)) { + print ''.$langs->trans("PriceUHTCurrency").' | '; + } print ''.$langs->trans("Qty").' | '; if ($conf->global->PRODUCT_USE_UNITS) print ''.$langs->trans("Unit").' | '; print ''.$langs->trans("ReductionShort").' | '; @@ -1509,8 +1512,12 @@ else } // TVA print ''.vatrate($objp->tva_tx,'%',$objp->info_bits).' | '; - // Prix + // Price print ''.($objp->subprice != '' ? price($objp->subprice) : '')." | \n"; + // Price multicurrency + if (!empty($conf->multicurrency->enabled)) { + print ''.price($objp->multicurrency_subprice).' | '; + } // Quantite print ''.$objp->qty.' | '; // Unit @@ -1949,6 +1956,8 @@ else { $var = true; + $forcetoshowtitlelines=1; + // Add free products/services $object->formAddObjectLine(1, $mysoc, $soc); @@ -2075,7 +2084,7 @@ $db->close(); ?> margin->enabled && $action == 'editline') +if (! empty($conf->margin->enabled) && $action == 'editline') { ?> diff --git a/htdocs/core/tpl/objectline_create.tpl.php b/htdocs/core/tpl/objectline_create.tpl.php index c7ebe5b7b8b..26086f04725 100644 --- a/htdocs/core/tpl/objectline_create.tpl.php +++ b/htdocs/core/tpl/objectline_create.tpl.php @@ -37,7 +37,7 @@ if (! empty($conf->margin->enabled) && ! empty($object->element) && in_array($ob $usemargins=1; } -global $dateSelector, $forceall, $senderissupplier, $inputalsopricewithtax; +global $dateSelector, $forceall, $forcetoshowtitlelines, $senderissupplier, $inputalsopricewithtax; if (! isset($dateSelector)) $dateSelector=1; // For backward compatibility elseif (empty($dateSelector)) $dateSelector=0; if (empty($forceall)) $forceall=0; @@ -53,7 +53,7 @@ if (in_array($object->element,array('propal', 'supplier_proposal','facture','fac lines) == 0); +$nolinesbefore=(count($this->lines) == 0 || $forcetoshowtitlelines); if ($nolinesbefore) { ?>