Bug 24860: Skip non-matching item group holds in HoldsQueue
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / circ / transfers_to_send.tt
1 [% USE raw %]
2 [% USE Asset %]
3 [% USE Koha %]
4 [% USE KohaDates %]
5 [% USE Branches %]
6 [% USE ItemTypes %]
7 [% SET footerjs = 1 %]
8 [% PROCESS 'transfer_reasons.inc' %]
9 [% INCLUDE 'doc-head-open.inc' %]
10 <title>Transfers to send &rsaquo; Circulation &rsaquo; Koha</title>
11 [% INCLUDE 'doc-head-close.inc' %]
12 </head>
13
14 <body id="circ_transferstosend" class="circ">
15 [% WRAPPER 'header.inc' %]
16     [% INCLUDE 'circ-search.inc' %]
17 [% END %]
18
19 [% WRAPPER 'sub-header.inc' %]
20 <nav id="breadcrumbs" aria-labal="Breadcrumb" class="breadcrumb">
21     <ol>
22         <li>
23             <a href="/cgi-bin/koha/mainpage.pl">Home</a>
24         </li>
25         <li>
26             <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a>
27         </li>
28         <li>
29             <a href="#" aria-current="page">Transfers to send</a>
30         </li>
31     </ol>
32 </nav>
33 [% END %]
34
35 <div class="main container-fluid">
36     <div class="row">
37         <div class="col-sm-12">
38             <main>
39                 <div class="row">
40
41                     [% IF Koha.Preference('CircSidebar') %]
42                     <div class="col-sm-10 col-sm-push-2">
43                     [% ELSE %]
44                     <div class="col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
45                     [% END %]
46
47                         <h1>Transfers requested of your library as of [% show_date | $KohaDates %]</h1>
48
49                         [% IF libraries.count %]
50                         <p>Your library is the origin for the following transfer(s)</p>
51                         <div id="resultlist">
52                             [% FOREACH library IN libraries %]
53                                 [% IF ( library.branchcode ) %]
54                                 <table style="width: 100%" id="transferst[% library.branchcode | html %]">
55                                     <caption>Sending to [% library.branchname | html %]</caption>
56                                     <thead>
57                                         <tr>
58                                             <th>Date of request</th>
59                                             <th class="anti-the">Title</th>
60                                             <th>Reason</th>
61                                             <th>On loan</th>
62                                             <th>Home library</th>
63                                             <th>Call number</th>
64                                             <th>Actions</th>
65                                         </tr>
66                                     </thead>
67                                     <tbody>
68                                         [% FOREACH transfer IN library.inbound_transfers %]
69                                             [% UNLESS transfer.datesent %]
70                                             <tr>
71                                                 <td data-order="[% transfer.daterequested | html %]">
72                                                     [% transfer.daterequested | $KohaDates %]
73                                                 </td>
74                                                 <td>
75                                                     [% INCLUDE 'biblio-title.inc' biblio = transfer.item.biblio link = 1 %][% IF ( transfer.item.biblio.author ) %] by [% transfer.item.biblio.author | html %][% END %]
76                                                     [% IF ( transfer.item.effective_itemtype ) %] (<b>[% ItemTypes.GetDescription( transfer.item.effective_itemtype ) | html %]</b>)[% END %]
77                                                     <br />Barcode: [% transfer.item.barcode | html %]
78                                                 </td>
79                                                 <td><p>[% PROCESS transfer_reason transfer=transfer %]</p></td>
80                                                 <td>[% IF transfer.item.onloan %]Due [% transfer.item.onloan | $KohaDates %][% ELSE %]On shelf[% END %]</td>
81                                                 <td>[% Branches.GetName( transfer.item.homebranch ) | html %]</td>
82                                                 <td>[% transfer.item.itemcallnumber | html %]</td>
83                                                 <td class="actions">
84                                                     [% IF transfer.reason == 'StockrotationAdvance' %]
85                                                     <a href="/cgi-bin/koha/catalogue/stockrotation.pl?op=toggle_in_demand&stage_id=4&item_id=[% transfer.itemnumber | uri %]&biblionumber=[% transfer.item.biblionumber | uri %]" class="btn btn-default btn-xs"><i class="fa fa-fire"></i> Mark "In demand"</a>
86                                                     [% END %]
87                                                 </td>
88                                             </tr>
89                                             [% END %]
90                                         [% END %]
91                                     </tbody>
92                                 </table>
93                                 [% END %]
94                             [% END %]
95                         </div>
96                         [% ELSE %]
97                         <p>No transfers to send</p>
98                         [% END %]
99
100                     </div> <!-- /.col-sm-10.col-sm-push-2 OR /.col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2-->
101
102                     [% IF Koha.Preference('CircSidebar') %]
103                     <div class="col-sm-2 col-sm-pull-10">
104                         <aside>
105                             [% INCLUDE 'circ-nav.inc' %]
106                         </aside>
107                     </div> <!-- /.col-sm-2.col-sm-pull-10 -->
108                     [% END %]
109
110                 </div> <!-- /.row -->
111             </main>
112         </div> <!-- /.col-sm-12 -->
113     </div> <!-- /.row -->
114
115 [% MACRO jsinclude BLOCK %]
116     [% INCLUDE 'datatables.inc' %]
117     <script>
118         $(document).ready(function() {
119             [% FOREACH library IN libraries %]
120             $("#transferst[% library.branchcode | html %]").dataTable($.extend(true, {}, dataTablesDefaults, {
121                 "aoColumnDefs": [
122                     { "aTargets": [ -1 ], "bSortable": false, "bSearchable": false },
123                     { "sType": "anti-the", "aTargets" : [ "anti-the" ] }
124                 ],
125                 "sDom": 't',
126                 "bPaginate": false
127             }));
128             [% END %]
129         });
130     </script>
131 [% END %]
132
133 [% INCLUDE 'intranet-bottom.inc' %]