monitoring/list/comments: Enhance PDF layout

This commit is contained in:
Johannes Meyer 2022-02-28 17:31:32 +01:00
parent b50d68553f
commit 298f2a3061
2 changed files with 8 additions and 2 deletions

View File

@ -20,6 +20,12 @@
data-icinga-multiselect-url="<?= $this->href('monitoring/comments/show') ?>"
data-icinga-multiselect-related="<?= $this->href("monitoring/comments") ?>"
data-icinga-multiselect-data="comment_id">
<thead class="print-only">
<tr>
<th><?= $this->translate('Type') ?></th>
<th><?= $this->translate('Comment') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($comments->peekAhead($this->compact) as $comment): ?>
<tr href="<?= $this->href('monitoring/comment/show', array('comment_id' => $comment->id)) ?>">
@ -40,7 +46,7 @@
</tbody>
</table>
<?php if ($comments->hasMore()): ?>
<div class="action-links">
<div class="dont-print action-links">
<?= $this->qlink(
$this->translate('Show More'),
$this->url()->without(array('showCompact', 'limit')),

View File

@ -63,7 +63,7 @@
$textId = 'comment-' . $uniqId;
$deleteButton = clone $delCommentForm;
/** @var \Icinga\Module\Monitoring\Forms\Command\Object\DeleteCommentCommandForm $deleteButton */
$deleteButton->setAttrib('class', $deleteButton->getAttrib('class') . ' remove-action');
$deleteButton->setAttrib('class', $deleteButton->getAttrib('class') . ' remove-action dont-print');
$deleteButton->populate(
array(
'comment_id' => $comment->id,