EspoCRM – Open Source CRM Application
PHP calendarcontactscrmcrm-platformcrm-systemcustomer-portalcustomer-supportcustomizabledocumentsemail-marketingkanbanleadsopen-sourcephpplatformsales-automationsingle-page-applicationsupport
Dompdf attachment mime type
Yurii0bfb67e7e60f
diff --git a/application/Espo/Tools/Pdf/Dompdf/EntityPrinter.php b/application/Espo/Tools/Pdf/Dompdf/EntityPrinter.phpindex 7e74bb940e..787ce9f619 100644--- a/application/Espo/Tools/Pdf/Dompdf/EntityPrinter.php+++ b/application/Espo/Tools/Pdf/Dompdf/EntityPrinter.php@@ -88,8 +88,9 @@ class EntityPrinter implements EntityPrinterInterface$name = $attachment->getName() ?? 'file-' . $i;$description = $attachmentWrapper->getDescription() ?? '';+ $mimeType = $attachment->getType() ?? 'application/octet-stream';- $cPdf->addEmbeddedFile($path, $name, $description);+ $cPdf->addEmbeddedFile($path, $name, $description, $mimeType, [$cPdf->catalogId => 'Data']);}}}