Fix #7335 #7365 Better fix

This commit is contained in:
Laurent Destailleur 2017-09-11 15:04:29 +02:00
parent e9bc5b719d
commit 44405e5415
2 changed files with 13 additions and 5 deletions

View File

@ -3156,6 +3156,14 @@ else if ($id > 0 || ! empty($ref))
$facthatreplace->fetch($objectidnext); $facthatreplace->fetch($objectidnext);
print ' (' . $langs->transnoentities("ReplacedByInvoice", $facthatreplace->getNomUrl(1)) . ')'; print ' (' . $langs->transnoentities("ReplacedByInvoice", $facthatreplace->getNomUrl(1)) . ')';
} }
if ($object->type == Facture::TYPE_CREDIT_NOTE || $object->type == Facture::TYPE_DEPOSIT) {
$discount = new DiscountAbsolute($db);
$result = $discount->fetch(0, $object->id);
if ($result > 0){
print '. '.$langs->trans("CreditNoteConvertedIntoDiscount", $object->getLibType(), $discount->getNomUrl(1, 'discount')).'<br>';
}
}
print '</td></tr>'; print '</td></tr>';
// Relative and absolute discounts // Relative and absolute discounts