diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php
index 850187c9dd3..92141599a9e 100644
--- a/htdocs/core/lib/functions.lib.php
+++ b/htdocs/core/lib/functions.lib.php
@@ -13351,7 +13351,23 @@ function show_actions_messaging($conf, $langs, $db, $filterobj, $objcon = '', $n
&& $actionstatic->code != 'AC_TICKET_MODIFY'
) {
$out .= '
';
- $out .= $histo[$key]['message'];
+ $truncateLines = getDolGlobalInt('MAIN_TRUNCATE_TIMELINE_MESSAGE', 3);
+ $truncatedText = dolGetFirstLineOfText($histo[$key]['message'], $truncateLines);
+ if ($truncateLines > 0 && strlen($histo[$key]['message']) > strlen($truncatedText)) {
+ $out .= '
';
+ } else {
+ $out .= $histo[$key]['message'];
+ }
+
$out .= '
';
}
@@ -13447,6 +13463,26 @@ function show_actions_messaging($conf, $langs, $db, $filterobj, $objcon = '', $n
$out .= "\n";
+ $out .= '';
+
+
if (empty($histo)) {
$out .= '