backport de #cc85a1a
This commit is contained in:
parent
181ee31c47
commit
3a2b48f16c
1 changed files with 2 additions and 1 deletions
|
|
@ -1640,7 +1640,8 @@ class pdf_sponge extends ModelePDFFactures
|
|||
// Total remise
|
||||
$total_line_remise = 0;
|
||||
foreach ($object->lines as $i => $line) {
|
||||
$total_line_remise += pdfGetLineTotalDiscountAmount($object, $i, $outputlangs, 2); // TODO: add this method to core/lib/pdf.lib
|
||||
$resdiscount = pdfGetLineTotalDiscountAmount($object, $i, $outputlangs, 2);
|
||||
$total_line_remise += (is_numeric($resdiscount) ? $resdiscount : 0);
|
||||
// Gestion remise sous forme de ligne négative
|
||||
if ($line->total_ht < 0) {
|
||||
$total_line_remise += -$line->total_ht;
|
||||
|
|
|
|||
Loading…
Reference in a new issue