Koha/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-note.inc
Marcel de Rooy c3dce50a4f
Bug 34478: Changes for opac-dismiss-message / opac-note.inc
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2024-03-01 10:57:39 +01:00

22 lines
1.2 KiB
HTML

[% IF patron_messages.filter_by_unread.count OR opacnote %]
<div class="alert alert-info">
<h3>Messages for you</h3>
<ul>
[% FOREACH message IN patron_messages.filter_by_unread %]
<li>
<strong>[% message.message | html | html_line_break %]</strong><br>
&nbsp;&nbsp;&nbsp;<em>Written on [% message.message_date | $KohaDates %] by [% Branches.GetName(message.branchcode) | html %]</em>
</li>
<form id="dismiss-message-form" action="/cgi-bin/koha/opac-dismiss-message.pl" method="post">
[% INCLUDE 'csrf-token.inc' %]
<input type="hidden" name="message_id" value="[% message.message_id | html %]">
<input type="hidden" name="patron_id" value="[% message.borrowernumber | html %]">
<input type="hidden" name="op" value="cud-update" />
<button type="submit" class="dismiss-message-button btn btn-primary"><i class="fa fa-trash" aria-hidden="true"></i> Dismiss</button>
</form>
[% END %]
[% IF ( opacnote ) %]<li>[% opacnote | html | html_line_break %]</li>[% END %]
</ul>
</div>
[% END %]