From 13cb2e478f80058327b898b6ab9dae20c58b3af6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Doursenaud?= Date: Fri, 16 May 2014 14:41:52 +0200 Subject: [PATCH] Contracts module configuration: missing translation string --- .../contract/doc/pdf_strato.modules.php | 21 +++++++++---------- htdocs/langs/en_US/contracts.lang | 2 ++ 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/htdocs/core/modules/contract/doc/pdf_strato.modules.php b/htdocs/core/modules/contract/doc/pdf_strato.modules.php index 57d86558bf3..5fc0eb6dd2a 100644 --- a/htdocs/core/modules/contract/doc/pdf_strato.modules.php +++ b/htdocs/core/modules/contract/doc/pdf_strato.modules.php @@ -24,7 +24,7 @@ /** * \file htdocs/core/modules/contract/doc/pdf_strato.modules.php * \ingroup ficheinter - * \brief Fichier de la classe permettant de generer les fiches d'intervention au modele Strato + * \brief Strato contracts template class file */ require_once DOL_DOCUMENT_ROOT.'/core/modules/contract/modules_contract.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; @@ -64,7 +64,7 @@ class pdf_strato extends ModelePDFContract $this->db = $db; $this->name = 'strato'; - $this->description = $langs->trans("DocumentModelStandard"); + $this->description = $langs->trans("StandardContractsTemplate"); // Dimension page pour format A4 $this->type = 'pdf'; @@ -116,7 +116,6 @@ class pdf_strato extends ModelePDFContract $outputlangs->load("dict"); $outputlangs->load("companies"); $outputlangs->load("contracts"); - $outputlangs->load("interventions"); if ($conf->contrat->dir_output) { @@ -171,10 +170,10 @@ class pdf_strato extends ModelePDFContract $pdf->SetDrawColor(128,128,128); $pdf->SetTitle($outputlangs->convToOutputCharset($object->ref)); - $pdf->SetSubject($outputlangs->transnoentities("InterventionCard")); + $pdf->SetSubject($outputlangs->transnoentities("ContractCard")); $pdf->SetCreator("Dolibarr ".DOL_VERSION); $pdf->SetAuthor($outputlangs->convToOutputCharset($user->getFullName($outputlangs))); - $pdf->SetKeyWords($outputlangs->convToOutputCharset($object->ref)." ".$outputlangs->transnoentities("InterventionCard")); + $pdf->SetKeyWords($outputlangs->convToOutputCharset($object->ref)." ".$outputlangs->transnoentities("ContractCard")); if (! empty($conf->global->MAIN_DISABLE_PDF_COMPRESSION)) $pdf->SetCompression(false); $pdf->SetMargins($this->marge_gauche, $this->marge_haute, $this->marge_droite); // Left, Top, Right @@ -408,13 +407,13 @@ class pdf_strato extends ModelePDFContract if (empty($hidebottom)) { $pdf->SetXY(20,230); - $pdf->MultiCell(66,5, $outputlangs->transnoentities("NameAndSignatureOfInternalContact"),0,'L',0); + $pdf->MultiCell(66,5, $outputlangs->transnoentities("ContactNameAndSignature", $this->emetteur->name),0,'L',0); $pdf->SetXY(20,235); $pdf->MultiCell(80,25, '', 1); $pdf->SetXY(110,230); - $pdf->MultiCell(80,5, $outputlangs->transnoentities("NameAndSignatureOfExternalContact"),0,'L',0); + $pdf->MultiCell(80,5, $outputlangs->transnoentities("ContactNameAndSignature", $this->recipient->name),0,'L',0); $pdf->SetXY(110,235); $pdf->MultiCell(80,25, '', 1); @@ -565,11 +564,11 @@ class pdf_strato extends ModelePDFContract // On peut utiliser le nom de la societe du contact if (! empty($conf->global->MAIN_USE_COMPANY_NAME_OF_CONTACT)) $socname = $object->contact->socname; else $socname = $object->client->nom; - $carac_client_name=$outputlangs->convToOutputCharset($socname); + $this->recipient->name=$outputlangs->convToOutputCharset($socname); } else { - $carac_client_name=$outputlangs->convToOutputCharset($object->client->nom); + $this->recipient->name=$outputlangs->convToOutputCharset($object->client->nom); } $carac_client=pdf_build_address($outputlangs, $this->emetteur, $object->client, (isset($object->contact)?$object->contact:''), $usecontact, 'target'); @@ -591,11 +590,11 @@ class pdf_strato extends ModelePDFContract // Show recipient name $pdf->SetXY($posx+2,$posy+3); $pdf->SetFont('','B', $default_font_size); - $pdf->MultiCell($widthrecbox, 4, $carac_client_name, 0, 'L'); + $pdf->MultiCell($widthrecbox, 4, $this->recipient->name, 0, 'L'); // Show recipient information $pdf->SetFont('','', $default_font_size - 1); - $pdf->SetXY($posx+2,$posy+4+(dol_nboflines_bis($carac_client_name,50)*4)); + $pdf->SetXY($posx+2,$posy+4+(dol_nboflines_bis($this->recipient->name,50)*4)); $pdf->MultiCell($widthrecbox, 4, $carac_client, 0, 'L'); } } diff --git a/htdocs/langs/en_US/contracts.lang b/htdocs/langs/en_US/contracts.lang index 622c8ca89d9..8a554a9770b 100644 --- a/htdocs/langs/en_US/contracts.lang +++ b/htdocs/langs/en_US/contracts.lang @@ -89,6 +89,8 @@ ListOfServicesToExpireWithDuration=List of Services to expire in %s days ListOfServicesToExpireWithDurationNeg=List of Services expired from more than %s days ListOfServicesToExpire=List of Services to expire NoteListOfYourExpiredServices=This list contains only services of contracts for third parties you are linked to as a sale representative. +StandardContractsTemplate=Standard contracts template +ContactNameAndSignature=For %s, name and signature: ##### Types de contacts ##### TypeContact_contrat_internal_SALESREPSIGN=Sales representative signing contract