View | Details | Raw Unified | Return to bug 17386
Collapse All | Expand All

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-note.inc (-12 / +14 lines)
Lines 1-13 Link Here
1
<div class="alert alert-info">
1
[% IF patron_messages.count OR opacnote %]
2
    <h3>Messages for you</h3>
2
    <div class="alert alert-info">
3
    <ul>
3
        <h3>Messages for you</h3>
4
        [% FOREACH message IN patron_messages %]
4
        <ul>
5
            <li>
5
            [% FOREACH message IN patron_messages %]
6
                <strong>[% message.message %]</strong><br>
6
                <li>
7
                &nbsp;&nbsp;&nbsp;<i>Written on [% message.message_date | $KohaDates %] by [% Branches.GetName(message.branchcode) %]</i>
7
                    <strong>[% message.message %]</strong><br>
8
            </li>
8
                    &nbsp;&nbsp;&nbsp;<i>Written on [% message.message_date | $KohaDates %] by [% Branches.GetName(message.branchcode) %]</i>
9
        [% END %]
9
                </li>
10
            [% END %]
10
11
11
        [% IF ( opacnote ) %]<li>[% opacnote %]</li>[% END %]
12
            [% IF ( opacnote ) %]<li>[% opacnote %]</li>[% END %]
12
    </ul>
13
        </ul>
13
</div>
14
    </div>
15
[% END %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt (-3 / +2 lines)
Lines 40-48 Using this account is not recommended because some parts of Koha will not functi Link Here
40
                        </div>
40
                        </div>
41
                    [% END %]
41
                    [% END %]
42
42
43
                    [% IF ( bor_messages ) %]
43
                    [% INCLUDE 'opac-note.inc' %]
44
                        [% INCLUDE 'opac-note.inc' %]
44
45
                    [% END %]
46
                    <h2>Hello, [% INCLUDE 'patron-title.inc' category_type = BORROWER_INFO.category_type firstname = BORROWER_INFO.firstname surname = BORROWER_INFO.surname othernames = BORROWER_INFO.othernames cardnumber = BORROWER_INFO.cardnumber %]
45
                    <h2>Hello, [% INCLUDE 'patron-title.inc' category_type = BORROWER_INFO.category_type firstname = BORROWER_INFO.firstname surname = BORROWER_INFO.surname othernames = BORROWER_INFO.othernames cardnumber = BORROWER_INFO.cardnumber %]
47
                    </h2>
46
                    </h2>
48
47
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt (-3 / +1 lines)
Lines 166-174 Link Here
166
                        [% IF ( patronid ) %]
166
                        [% IF ( patronid ) %]
167
                            [% IF ( validuser ) %]
167
                            [% IF ( validuser ) %]
168
                                <div class="alert alert-info">You are logged in as [% borrowername %].</div>
168
                                <div class="alert alert-info">You are logged in as [% borrowername %].</div>
169
                                [% IF ( bor_messages ) %]
169
                                [% INCLUDE 'opac-note.inc' %]
170
                                    [% INCLUDE 'opac-note.inc' %]
171
                                [% END %]
172
                            [% END %]
170
                            [% END %]
173
171
174
                            [% IF ( nouser ) %]
172
                            [% IF ( nouser ) %]
(-)a/opac/opac-user.pl (-10 / +1 lines)
Lines 308-323 my $patron_messages = Koha::Patron::Messages->search( Link Here
308
        message_type => 'B',
308
        message_type => 'B',
309
    }
309
    }
310
);
310
);
311
if ( $patron_messages->count ) {
312
    $template->param( bor_messages => 1 );
313
}
314
315
if ( $borr->{'opacnote'} ) {
316
  $template->param( 
317
    bor_messages => 1,
318
    opacnote => $borr->{'opacnote'},
319
  );
320
}
321
311
322
if (   C4::Context->preference('AllowPatronToSetCheckoutsVisibilityForGuarantor')
312
if (   C4::Context->preference('AllowPatronToSetCheckoutsVisibilityForGuarantor')
323
    || C4::Context->preference('AllowStaffToSetCheckoutsVisibilityForGuarantor') )
313
    || C4::Context->preference('AllowStaffToSetCheckoutsVisibilityForGuarantor') )
Lines 336-341 if ( C4::Context->preference('AllowPatronToSetCheckoutsVisibilityForGuarantor' Link Here
336
$template->param(
326
$template->param(
337
    borrower                 => $borr,
327
    borrower                 => $borr,
338
    patron_messages          => $patron_messages,
328
    patron_messages          => $patron_messages,
329
    opacnote                 => $borr->{opacnote},
339
    patronupdate             => $patronupdate,
330
    patronupdate             => $patronupdate,
340
    OpacRenewalAllowed       => C4::Context->preference("OpacRenewalAllowed"),
331
    OpacRenewalAllowed       => C4::Context->preference("OpacRenewalAllowed"),
341
    userview                 => 1,
332
    userview                 => 1,
(-)a/opac/sco/sco-main.pl (-13 / +4 lines)
Lines 257-274 if ($borrower->{cardnumber}) { Link Here
257
            message_type => 'B',
257
            message_type => 'B',
258
        }
258
        }
259
    );
259
    );
260
    if ( $patron_messages->count ) {
260
    $template->param(
261
        $template->param( bor_messages => 1,
261
        patron_messages => $patron_messages,
262
            patron_messages => $patron_messages,
262
        opacnote => $borrower->{opacnote},
263
        );
263
    );
264
    }
265
266
    if ( $borrower->{'opacnote'} ) {
267
        $template->param(
268
            bor_messages => 1,
269
            opacnote => $borrower->{'opacnote'},
270
        );
271
    }
272
264
273
    my $inputfocus = ($return_only      == 1) ? 'returnbook' :
265
    my $inputfocus = ($return_only      == 1) ? 'returnbook' :
274
                     ($confirm_required == 1) ? 'confirm'    : 'barcode' ;
266
                     ($confirm_required == 1) ? 'confirm'    : 'barcode' ;
275
- 

Return to bug 17386