Bug 17100: Restore previous logic
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / members / moremember-print.tt
blob66f13d74c4e82c2f9e11bd602eb80e0c684299f6
1 [% USE Koha %]
2 [% USE Branches %]
3 [% USE KohaDates %]
4 [% USE Price %]
5 [% INCLUDE 'doc-head-open.inc' %]
6     <title>Summary for [% firstname %] [% surname %] ([% cardnumber %])</title>
7     [% INCLUDE 'doc-head-close.inc' %]
8     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
9     <link rel="shortcut icon" href="[% IF ( IntranetFavicon ) %][% IntranetFavicon %][% ELSE %][% interface %]/[% theme %]/img/favicon.ico[% END %]" type="image/x-icon" />
10     <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/print.css" />
11     [% INCLUDE 'slip-print.inc' #printThenClose %]
12 </head>
13 <body id="pat_moremember-print" class="pat" onload="printThenClose();">
14     <div id="main">
15         <h3><a href="/cgi-bin/koha/circ/circulation.pl?findborrower=[% cardnumber %]">Account summary: [% firstname %] [% surname %] ([% cardnumber %])</a></h3>
17         <ul>
18             [% IF Koha.Preference( 'AddressFormat' ) %]
19                 [% INCLUDE "member-display-address-style-${ Koha.Preference( 'AddressFormat' ) }.inc" %]
20             [% ELSE %]
21                 [% INCLUDE 'member-display-address-style-us.inc' %]
22             [% END %]
23             <li>[% IF ( phone ) %][% phone %][% ELSE %](no phone number on file)[% END %]</li>
24             <li>[% IF ( email ) %][% email %][% ELSE %](no primary email on file)[% END %]</li>
25             [% IF ( emailpro ) %]
26                 <li>[% emailpro %]</li>
27             [% END %]
28             <li>Registration date: [% dateenrolled | $KohaDates %]</li>
29             <li>Expiration date: [% dateexpiry | $KohaDates %]</li>
30             <li>Library: [% Branches.GetName( branchcode ) %]</li>
31             <li>Category: [% description %]</li>
32         </ul>
34         [% IF ( issues ) %]
35             <table>
36                 <caption>Items checked out</caption>
37                 <tr>
38                     <th>Title</th>
39                     <th>Author</th>
40                     <th>Call no</th>
41                     <th>Item type</th>
42                     <th>Date due</th>
43                     <th>Barcode</th>
44                     <th>Charge</th>
45                     <th>Price</th>
46                     <th>Status</th>
47                 </tr>
49                 [% FOREACH issue IN issues %]
50                     [% IF ( issue.overdue ) %]<tr class="overdue">[% ELSE %]<tr>[% END %]
51                         <td>
52                             [% issue.title |html %]
53                             <a href="/cgi-bin/koha/catalogue/detail.pl?item=[% issue.itemnumber %]&amp;biblionumber=[% issue.biblionumber %]&amp;bi=[% issue.biblioitemnumber %]"></a>
54                         </td>
55                         <td>[% issue.author %]</td>
56                         <td>[% issue.itemcallnumber %]</td>
57                         <td>[% issue.itemtype_description %]</td>
58                         <td>[% issue.date_due | $KohaDates as_due_date => 1 %]</td>
59                         <td>[% issue.barcode %]</td>
60                         <td>[% issue.charge %]</td>
61                         <td>[% issue.replacementprice %]</td>
62                         <td>[% IF ( issue.overdue ) %]Overdue![% ELSE %]&nbsp;[% END %]</td>
63                     </tr>
64                 [% END %]
66             <tr>
67                 <td colspan="6" style="text-align: right; font-weight:bold;">Totals:</td>
68                 <td>[% totaldue %]</td>
69                 <td>[% totalprice %]</td>
70                 <td colspan="3">&nbsp;</td>
71             </tr>
72         </table>
73     [% END %]
75     [% IF ( reserves ) %]
76         <table>
77             <caption>Pending holds</caption>
78             <tr>
79                 <th>Title</th>
80                 <th>Author</th>
81                 <th>Placed on</th>
82                 <th>Expires on</th>
83                 <th>Pick up location</th>
84             </tr>
86             [% FOREACH reserve IN reserves %]
87                 <tr>
88                     <td>[% reserve.title %]</td>
89                     <td>[% reserve.author %]</td>
90                     <td>[% reserve.reservedate | $KohaDates %]</td>
91                     <td>[% reserve.expirationdate | $KohaDates %]</td>
92                     <td>[% reserve.waiting_at %]</td>
93                 </tr>
94             [% END %]
95         </table>
96     [% END %]
97     [% IF accounts && totaldue != 0 %]
98         <table>
99             <caption>Account fines and payments</caption>
100             <tr>
101                 <th>Description of charges</th>
102                 <th>Date</th>
103                 <th>Amount</th>
104                 <th>Outstanding</th>
105             </tr>
107             [% FOREACH account IN accounts %]
108                 [% NEXT IF account.amountoutstanding == 0 %]
109                 <tr>
110                     <td>
111                         [% IF ( account.itemnumber ) %]<a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% account.biblionumber %]&amp;itemnumber=[% account.itemnumber %]">[% END %]
112                         [% account.description %]&nbsp;[% IF ( account.printtitle ) %] [% account.title |html %][% END %]
113                         [% IF ( account.itemnumber ) %]</a>[% END %]
114                     </td>
115                     <td>[% account.date | $KohaDates %]</td>
116                     <td style="text-align:right;">[% account.amount | $Price %]</td>
117                     <td style="text-align:right;">[% account.amountoutstanding | $Price %]</td>
118                 </tr>
119             [% END %]
121             <tfoot>
122                 <tr>
123                     <td colspan="3">Total due</td>
124                     <td colspan="2" style="text-align:right;">[% totaldue | $Price %]</td>
125                 </tr>
126             </tfoot>
127         </table>
128     [% END %]
130 [% INCLUDE 'intranet-bottom.inc' %]