diff --git a/CHANGELOG.md b/CHANGELOG.md index ad7b5ef..4850b94 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [Unreleased] + +### Fixed + +- Fix image rendering in Change/Problem descriptions and Problem task PDF exports + ## [4.1.3] - 2026-06-24 ### Fixed diff --git a/inc/change.class.php b/inc/change.class.php index f66e41a..a9f436b 100644 --- a/inc/change.class.php +++ b/inc/change.class.php @@ -298,7 +298,7 @@ public static function pdfMain(PluginPdfSimplePDF $pdf, Change $job) $pdf->displayText( '' . sprintf(__s('%1$s: %2$s') . '', __s('Description'), ''), - Toolbox::stripTags($job->fields['content']), + $job->fields['content'], 1, ); diff --git a/inc/common.class.php b/inc/common.class.php index a883614..403da09 100644 --- a/inc/common.class.php +++ b/inc/common.class.php @@ -59,6 +59,8 @@ public function addStandardTab($itemtype, array &$ong, array $options) $withtemplate = $options['withtemplate']; } + // $itemtype has no native type hint; PHPDoc-inferred class-string type isn't enforced at runtime + /** @phpstan-ignore-next-line function.impossibleType */ if (!is_numeric($itemtype) && ($obj = $dbu->getItemForItemtype($itemtype)) && (method_exists($itemtype, 'displayTabContentForPDF'))) { $titles = $obj->getTabNameForItem($this->obj, $withtemplate); if (!is_array($titles)) { diff --git a/inc/problem.class.php b/inc/problem.class.php index f2ce73b..2484950 100644 --- a/inc/problem.class.php +++ b/inc/problem.class.php @@ -298,7 +298,7 @@ public static function pdfMain(PluginPdfSimplePDF $pdf, Problem $job) $pdf->displayText( '' . sprintf(__s('%1$s: %2$s'), __s('Description') . '', ''), - Toolbox::stripTags($job->fields['content']), + $job->fields['content'], 1, ); diff --git a/inc/problemtask.class.php b/inc/problemtask.class.php index 0d19cc8..f89d506 100755 --- a/inc/problemtask.class.php +++ b/inc/problemtask.class.php @@ -124,7 +124,7 @@ public static function pdfForProblem(PluginPdfSimplePDF $pdf, Problem $job) ); $pdf->displayText( '' . sprintf(__s('%1$s: %2$s') . '', __s('Description'), ''), - Toolbox::stripTags($data['content']), + $data['content'], 1, ); }