Bug 29393: Add a dedicated letters module for add message
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / includes / waiting_holds.inc
1 [% USE KohaDates %]
2 [% USE ItemTypes %]
3 [% USE AuthorisedValues %]
4 <table class="holds_table" id="[% table_name | html %]">
5     <thead>
6         <tr>
7             <th class="NoSort"><input type="checkbox" class="select_hold_all"/></th>
8             <th>Waiting since</th>
9             <th>Date hold placed</th>
10           [% IF table_name == 'holdscr' %]
11             <th>Date cancellation requested</th>
12           [% END %]
13             <th>Expiration date</th>
14             <th class="anti-the">Title</th>
15             <th>Patron</th>
16             <th>Home library</th>
17             <th>Current library</th>
18             <th>Shelving location</th>
19             <th>Call number</th>
20             <th>Copy number</th>
21             <th>Enumeration</th>
22             <th class="NoSort noExport">Actions</th>
23         </tr>
24     </thead>
25     <tbody>
26         [% FOREACH reserveloo IN reserveloop %]
27             <tr>
28                 <th><input type="checkbox" class="select_hold" data-id="[% reserveloo.reserve_id | html %]"/></th>
29                 <td data-order="[% reserveloo.waitingdate | html %]"><span>[% reserveloo.waitingdate | $KohaDates %]</span></td>
30                 <td data-order="[% reserveloo.reservedate | html %]"><span>[% reserveloo.reservedate | $KohaDates %]</span></td>
31               [% IF table_name == 'holdscr' %]
32                 [% IF reserveloo.cancellation_requests.count %]
33                   [% FOREACH cancellation_request IN reserveloo.cancellation_requests %]
34                     [% IF loop.first %]
35                       <td data-order="[% cancellation_request.creation_date | html %]">
36                     [% END %]
37                         <span>[% cancellation_request.creation_date | $KohaDates %]</span>
38                     [% IF loop.last %]
39                       </td>
40                     [% END %]
41                   [% END %]
42                 [% ELSE %]
43                   <td></td>
44                 [% END %]
45               [% END %]
46                 <td data-order="[% reserveloo.expirationdate | html %]"><span>[% reserveloo.expirationdate | $KohaDates %]</span></td>
47                 <td>
48                     [% INCLUDE 'biblio-title.inc' biblio=reserveloo.biblio link = 1 %]
49                         [% UNLESS ( item_level_itypes ) %]
50                             [% IF ( ItemTypes.GetDescription(reserveloo.item.effective_itemtype) ) %]&nbsp; (<strong>[% ItemTypes.GetDescription(reserveloo.item.effective_itemtype) | html %]</strong>)
51                             [% END %]
52                         [% END %]
53                         <br />Barcode: [% reserveloo.item.barcode | html %]
54                 </td>
55                 <td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% reserveloo.borrower.borrowernumber | uri %]">[% INCLUDE 'patron-title.inc' patron=reserveloo.borrower invert_name=1 no_title=1 %]</a>
56                     [% IF ( reserveloo.borrower.phone ) %]<br /><span class="patron_phone">[% reserveloo.borrower.phone | html %]</span>[% END %]
57                     [% IF ( reserveloo.borrower.notice_email_address ) %]
58                         <span class="patron_email"><br /><a href="mailto:[% reserveloo.borrower.notice_email_address | uri %]?subject=[% "Hold waiting: " | uri %][% reserveloo.biblio.title | uri %]">
59                         [% reserveloo.borrower.notice_email_address | html %]</a></span>
60                     [% END %]
61                 </td>
62                 <td>[% Branches.GetName( reserveloo.item.homebranch ) | html %]</td>
63                 <td>[% Branches.GetName( reserveloo.item.holdingbranch ) | html %][% IF (reserveloo.desk_id  ) %], [% reserveloo.desk.desk_name | html %][% END %]</td>
64                 <td>[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.location', authorised_value => reserveloo.item.location) | html %]</td>
65                 <td>[% reserveloo.item.itemcallnumber | html %]</td>
66                 <td>[% reserveloo.item.copynumber | html %]</td>
67                 <td>[% reserveloo.item.enumchron | html %]</td>
68                 <td>
69                     <form name="cancelReserve" action="waitingreserves.pl" method="post">
70                         [% INCLUDE 'csrf-token.inc' %]
71                         <input type="hidden" name="op" value="cud-cancel">
72                         <input type="hidden" name="borrowernumber" value="[% reserveloo.borrower.borrowernumber | html %]" />
73                         <input type="hidden" name="itemnumber" value="[% reserveloo.item.itemnumber | html %]" />
74                         <input type="hidden" name="fbr" value="[% reserveloo.item.holdingbranch | html %]" />
75                         <input type="hidden" name="tbr" value="[% reserveloo.item.homebranch | html %]" />
76                         <input type="hidden" name="tab" value="[% tab | html %]">
77                         [% IF ( reserveloo.item.homebranch != reserveloo.item.holdingbranch ) %]
78                             <button type="submit" class="btn btn-default btn-xs"><i class="fa fa-times"></i> Cancel hold and return to: [% Branches.GetName( reserveloo.item.homebranch ) | html %]</button>
79                         [% ELSE %]
80                             <button type="submit" class="btn btn-default btn-xs"><i class="fa fa-times"></i> Cancel hold</button>
81                         [% END %]
82                    </form>
83                 </td>
84             </tr>
85         [% END %]
86     </tbody>
87 </table>