diff --git a/htdocs/langs/en_US/contracts.lang b/htdocs/langs/en_US/contracts.lang index 8d209623c1b..ab94a63bcc3 100644 --- a/htdocs/langs/en_US/contracts.lang +++ b/htdocs/langs/en_US/contracts.lang @@ -80,7 +80,7 @@ ConfirmDeleteContractLine=Are you sure you want to delete this contract line? MoveToAnotherContract=Move service into another contract. ConfirmMoveToAnotherContract=I choosed new target contract and confirm I want to move this service into this contract. ConfirmMoveToAnotherContractQuestion=Choose in which existing contract (of same third party), you want to move this service to? -PaymentRenewContractId=Renew contract line (number %s) +PaymentRenewContractId=Renew contract %s (service %s) ExpiredSince=Expiration date NoExpiredServices=No expired active services ListOfServicesToExpireWithDuration=List of Services to expire in %s days diff --git a/htdocs/public/payment/newpayment.php b/htdocs/public/payment/newpayment.php index b61a2e22a06..14d455b5496 100644 --- a/htdocs/public/payment/newpayment.php +++ b/htdocs/public/payment/newpayment.php @@ -1353,7 +1353,7 @@ if ($source == 'contractline') { // Object $text = ''.$langs->trans("PaymentRenewContractId", $contract->ref, $contractline->ref).''; - if ($contractline->fk_product) { + if ($contractline->fk_product > 0) { $contractline->fetch_product(); $text .= '
'.$contractline->product->ref.($contractline->product->label ? ' - '.$contractline->product->label : ''); } @@ -1364,8 +1364,8 @@ if ($source == 'contractline') { // $text.='
'.$langs->trans("DateEndPlanned").': '; // $text.=dol_print_date($contractline->date_fin_validite); //} - if ($contractline->date_fin_validite) { - $text .= '
'.$langs->trans("ExpiredSince").': '.dol_print_date($contractline->date_fin_validite); + if ($contractline->date_end) { + $text .= '
'.$langs->trans("ExpiredSince").': '.dol_print_date($contractline->date_end); } if (GETPOST('desc', 'alpha')) { $text = ''.$langs->trans(GETPOST('desc', 'alpha')).'';