fix bon de commande on devis and facture, location of devis on care certificate, Mr mme on care certifcate

This commit is contained in:
Tiavina 2025-01-20 19:19:37 +03:00
parent 65470424f0
commit 9158618c98
4 changed files with 21 additions and 5 deletions

View File

@ -97,6 +97,14 @@ class CertificateService {
$devisOfDefunt["configuration"] = $currentConfig; $devisOfDefunt["configuration"] = $currentConfig;
$devisOfDefunt["thanato_date_habilitation"] = new DateTimeImmutable($devisOfDefunt["thanato_date_habilitation"]); $devisOfDefunt["thanato_date_habilitation"] = new DateTimeImmutable($devisOfDefunt["thanato_date_habilitation"]);
$devisOfDefunt["devis_date"] = new DateTimeImmutable($devisOfDefunt["devis_date"]); $devisOfDefunt["devis_date"] = new DateTimeImmutable($devisOfDefunt["devis_date"]);
$locationOfDevis = "";
if($devisOfDefunt['lieu_nom'] != null){
$locationOfDevis .= $devisOfDefunt['lieu_nom'];
}
if($devisOfDefunt['lieu_adresse'] != null){
$locationOfDevis .= " ". $devisOfDefunt['lieu_adresse'];
}
$devisOfDefunt['location_of_devis'] = $locationOfDevis;
$clean_folder = html_entity_decode(string: $currentConfig->path).'/'; $clean_folder = html_entity_decode(string: $currentConfig->path).'/';
$careCertificateFolder = $this->getCareCertificateFolder($devisOfDefunt); $careCertificateFolder = $this->getCareCertificateFolder($devisOfDefunt);
$folderDestination = $clean_folder.$careCertificateFolder; $folderDestination = $clean_folder.$careCertificateFolder;

View File

@ -83,15 +83,15 @@ class CareCertificatePdfHandler extends FPDF {
$this->SetFont('Arial', '', 14); $this->SetFont('Arial', '', 14);
$this->MultiCell(0,7,FileExportHelpers::FormatTextForExport('La Société '. $this->devisOfDefunt['configuration']->entreprise. ' habilitée sous le numéro ' . $this->devisOfDefunt['thanato_reference'] . ' certifie par la présente que: ')); $this->MultiCell(0,7,FileExportHelpers::FormatTextForExport('La Société '. $this->devisOfDefunt['configuration']->entreprise. ' habilitée sous le numéro ' . $this->devisOfDefunt['thanato_reference'] . ' certifie par la présente que: '));
$this->SetFont('Arial', 'B', 14); $this->SetFont('Arial', 'B', 14);
$this->Cell(0,12, 'Mr/Mlle ' . FileExportHelpers::FormatTextForExport($this->devisOfDefunt['thanato_nom'] . ' ' . $this->devisOfDefunt['thanato_prenom']),0,1); $this->Cell(0,12, 'Mr/Mme ' . FileExportHelpers::FormatTextForExport($this->devisOfDefunt['thanato_nom'] . ' ' . $this->devisOfDefunt['thanato_prenom']),0,1);
$this->SetFont('Arial', '', 14); $this->SetFont('Arial', '', 14);
$this->MultiCell(0,7, FileExportHelpers::FormatTextForExport('Employé au sein de notre société et titulaire du diplôme national de Thanatopracteur a effectué des soins de conservation sur le corps du défunt:')); $this->MultiCell(0,7, FileExportHelpers::FormatTextForExport('Employé au sein de notre société et titulaire du diplôme national de Thanatopracteur a effectué des soins de conservation sur le corps du défunt:'));
$this->SetFont('Arial', 'B', 14); $this->SetFont('Arial', 'B', 14);
$this->Cell(0,12, 'M./Mme '.$this->devisOfDefunt['defunt_nom'],0,1); $this->Cell(0,12, 'Mr/Mme '.$this->devisOfDefunt['defunt_nom'],0,1);
$this->SetFont('Arial', '', 14); $this->SetFont('Arial', '', 14);
$this->Cell(0,12, FileExportHelpers::FormatTextForExport("Qui reposait à l'adresse suivante") . ': ',0,1); $this->Cell(0,12, FileExportHelpers::FormatTextForExport("Qui reposait à l'adresse suivante") . ': ',0,1);
$this->SetFont('Arial', 'B', 14); $this->SetFont('Arial', 'B', 14);
$this->Cell(0,12, FileExportHelpers::FormatTextForExport($this->devisOfDefunt['configuration']->adresse),0,1); $this->Cell(0,12, FileExportHelpers::FormatTextForExport($this->devisOfDefunt['location_of_devis']),0,1);
$this->SetFont('Arial', '', 14); $this->SetFont('Arial', '', 14);
$this->Cell(0,12, FileExportHelpers::FormatTextForExport("La présente attestion est établie pour faire valoir ce que de droit."),0,5); $this->Cell(0,12, FileExportHelpers::FormatTextForExport("La présente attestion est établie pour faire valoir ce que de droit."),0,5);
$this->Ln(5); $this->Ln(5);

View File

@ -190,7 +190,7 @@ class DevisPdfHandler extends FPDF {
$this->SetFont('Arial', '', 11); $this->SetFont('Arial', '', 11);
$ibanWidth = 90; $ibanWidth = 90;
$ibanCursorY = $this->GetY(); $ibanCursorY = $this->GetY();
$this->Cell($ibanWidth, 7, 'IBAN : FR76 1360 6000 1436 5418 1800 038', 1, 1, 'C'); $this->Cell($ibanWidth, 7, 'IBAN : FR76 3000 3030 7700 0200 2057 074', 1, 1, 'C');
$ibanCursorX = $this->GetX(); $ibanCursorX = $this->GetX();
$this->Cell($ibanWidth, 7, 'Code SWIFT : AGRI FR PP 836', 1, 1, 'C'); $this->Cell($ibanWidth, 7, 'Code SWIFT : AGRI FR PP 836', 1, 1, 'C');

View File

@ -213,6 +213,14 @@ class InvoicePdfHandler extends FPDF {
private function DrawBankAndTotalPriceInfo($totalPriceArray){ private function DrawBankAndTotalPriceInfo($totalPriceArray){
$this->SetY(210); $this->SetY(210);
$this->SetFont('Arial', '', 9); $this->SetFont('Arial', '', 9);
$devisComment = ($this->factureData['devis_comment'] == "Commentaire" || $this->factureData['devis_comment'] == "" ? "" : $this->factureData['devis_comment']);
if($devisComment != ""){
$this->SetFont('Arial', 'B', 9);
$this->Cell(0,5,"Bon de commande: ". $devisComment,0,1);
$this->Ln(3);
}
$this->SetFont('Arial', '', 9);
$this->MultiCell(0,5,utf8_decode(html_entity_decode("Paiement à votre convenance par chèque à l'ordre de ". $this->factureData['configuration']->entreprise))); $this->MultiCell(0,5,utf8_decode(html_entity_decode("Paiement à votre convenance par chèque à l'ordre de ". $this->factureData['configuration']->entreprise)));
$this->MultiCell(0,5,utf8_decode(html_entity_decode("en indiquant le numéro de facture, ou par virement :"))); $this->MultiCell(0,5,utf8_decode(html_entity_decode("en indiquant le numéro de facture, ou par virement :")));
@ -222,7 +230,7 @@ class InvoicePdfHandler extends FPDF {
$this->SetFont('Arial', '', 11); $this->SetFont('Arial', '', 11);
$ibanWidth = 90; $ibanWidth = 90;
$ibanCursorY = $this->GetY(); $ibanCursorY = $this->GetY();
$this->Cell($ibanWidth, 7, 'IBAN : FR76 1360 6000 1436 5418 1800 038', 1, 1, 'C'); $this->Cell($ibanWidth, 7, 'IBAN : FR76 3000 3030 7700 0200 2057 074', 1, 1, 'C');
$ibanCursorX = $this->GetX(); $ibanCursorX = $this->GetX();
$this->Cell($ibanWidth, 7, 'Code SWIFT : AGRI FR PP 836', 1, 1, 'C'); $this->Cell($ibanWidth, 7, 'Code SWIFT : AGRI FR PP 836', 1, 1, 'C');