Bug 25245: Add plugins_nightly.pl to the default cron
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / circ / branchtransfers.tt
1 [% USE Koha %]
2 [% USE Branches %]
3 [% USE ItemTypes %]
4 [% USE AuthorisedValues %]
5 [% INCLUDE 'doc-head-open.inc' %]
6 <title>Koha &rsaquo; Circulation &rsaquo; Transfers</title>
7 [% INCLUDE 'doc-head-close.inc' %]
8 </head>
9 <body id="circ_branchtransfers" class="circ">
10 [% INCLUDE 'header.inc' %]
11 [% INCLUDE 'circ-search.inc' %]
12
13 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Transfers</div>
14
15 <div class="main container-fluid">
16     <div class="row">
17         [% IF Koha.Preference('CircSidebar') %]
18             <div class="col-sm-10 col-sm-push-2">
19         [% ELSE %]
20             <div class="col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
21         [% END %]
22             <main>
23
24 [% IF ( found ) %]
25     <h3>Reserve found</h3>
26     <table>
27         <caption>
28             [% IF ( reserved ) %]
29                 Reserve found for [% name | html %] (<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% borrowernumber | uri %]">[% borrowernumber | html %]</a>).
30             [% END %]
31             [% IF ( waiting ) %]
32                 Item is marked waiting at [% branchname | html %] for [% name | html %] (<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% borrowernumber | uri %]">[% borrowernumber | html %]</a>).
33             [% END %]
34         </caption>
35         <tr>
36             <th>
37                 [% IF ( reserved ) %]Set reserve to waiting and transfer book to [% branchname | html %]: [% END %]
38                 [% IF ( waiting ) %]Cancel reservation and then attempt transfer: [% END %]
39             </th>
40             <td>
41                 <form method="post" name="mainform" id="mainform" action="branchtransfers.pl">
42                     [% FOREACH trsfitemloo IN trsfitemloop %]
43                         <input type="hidden" name="bc-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.item.barcode | html %]" />
44                         <input type="hidden" name="fb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.frombrcd | html %]" />
45                         <input type="hidden" name="tb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.tobrcd | html %]" />
46                     [% END %]
47                     <input type="hidden" name="itemnumber" value="[% itemnumber | html %]" />
48                     <input type="hidden" name="borrowernumber" value="[% borrowernumber | html %]" />
49                     <input type="hidden" name="tobranchcd" value="[% tobranchcd | html %]" />
50                     [% IF ( waiting ) %]
51                         <input type="hidden" name="barcode" value="[% barcode | html %]" />
52                         <input type="hidden" name="request" value="KillWaiting" />
53                         <input type="submit" value="Cancel" />
54                     [% END %]
55                     [% IF ( reserved ) %]
56                         <input type="hidden" name="request" value="SetWaiting" />
57                         <input type="submit" value="Waiting" />
58                     [% END %]
59                 </form>
60             </td>
61         </tr>
62             [% IF ( reserved ) %]
63                 <tr>
64                     <th>Cancel reservation and then attempt transfer:</th>
65                     <td>
66                         <form method="post" name="mainform" id="mainform" action="branchtransfers.pl">
67                             [% FOREACH trsfitemloo IN trsfitemloop %]
68                                 <input type="hidden" name="bc-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.item.barcode | html %]" />
69                                 <input type="hidden" name="fb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.frombrcd | html %]" />
70                                 <input type="hidden" name="tb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.tobrcd | html %]" />
71                             [% END %]
72                             <input type="hidden" name="biblionumber" value="[% biblionumber | html %]" />
73                             <input type="hidden" name="borrowernumber" value="[% borrowernumber | html %]" />
74                             <input type="hidden" name="tobranchcd" value="[% tobranchcd | html %]" />
75                             <input type="hidden" name="barcode" value="[% barcode | html %]" />
76                             <input type="hidden" name="request" value="KillReserved" />
77                             <input type="submit" value="Cancel" />
78                         </form>
79                     </td>
80                 </tr>
81             [% END %]
82                 <tr>
83                     <th>Ignore and return to transfers: </th>
84                         <td>
85                             <form method="post" name="mainform" id="mainform" action="branchtransfers.pl">
86                                 <input type="hidden" name="tobranchcd" value="[% tobranchcd | html %]" />
87                                 <input type="hidden" name="barcode" />
88                                 [% FOREACH trsfitemloo IN trsfitemloop %]
89                                     <input type="hidden" name="bc-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.item.barcode | html %]" />
90                                     <input type="hidden" name="fb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.frombrcd | html %]" />
91                                     <input type="hidden" name="tb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.tobrcd | html %]" />
92                                 [% END %]
93                                 <input type="submit" value="Ignore" />
94                             </form>
95                         </td>
96                 </tr>
97     </table>
98
99 [% ELSE %]
100                     [% IF ( reqmessage ) %]
101                      <div class="dialog message">
102                         <ul>
103                          [% IF ( cancelled ) %]
104                              <li>Reserve cancelled</li>
105                          [% END %]
106                          [% IF ( setwaiting ) %]
107                              <li>Item should now be waiting at library: [% reqbrchname | html %]</li>
108                          [% END %]
109                          </ul>
110                     </div>
111                      [% END %]
112
113                      [% IF ( errmsgloop ) %]
114                         <div class="dialog message">
115                             <ul>
116                              [% FOREACH errmsgloo IN errmsgloop %]
117                               [% IF ( errmsgloo.errbadcode ) %]
118                                   <li>No Item with barcode: [% errmsgloo.msg | html %]</li>
119                               [% END %]
120                               [% IF ( errmsgloo.errispermanent ) %]
121                                   <li>Please return item to home library: [% Branches.GetName( errmsgloo.msg ) | html %]</li>
122                               [% END %]
123                               [% IF ( errmsgloo.errnotallowed ) %]
124                                   <li>Transfer is not allowed for:
125                                       <ol>
126                                           [% IF ( Koha.Preference('BranchTransferLimitsType') == 'itemtype' ) %]
127                                               <li>Item type: <strong>[% ItemTypes.GetDescription( errmsgloo.code ) | html %]</strong></li>
128                                           [% ELSE %]
129                                           <li>Collection: <strong>[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => errmsgloo.code ) | html %]</strong></li>
130                                           [% END %]
131                                           <li>Originating library: <strong>[% Branches.GetName( errmsgloo.fbr ) | html %]</strong></li>
132                                           <li>Destination library: <strong>[% Branches.GetName( errmsgloo.tbr ) | html %]</strong></li>
133                                       </ol>
134                                   </li>
135                               [% END %]
136                               [% IF ( errmsgloo.errdesteqholding ) %]
137                                   <li>Item is already at destination library.</li>
138                               [% END %]
139                               [% IF ( errmsgloo.errwasreturned ) %]
140                                   <li>Item was on loan to <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% errmsgloo.patron.borrowernumber | uri %]">
141                                   [% errmsgloo.patron.firstname | html %] [% errmsgloo.patron.surname | html %]
142                                   ([% errmsgloo.patron.cardnumber | html %])</a> and has been returned.</li>
143                               [% END %]
144                           [% END %]
145                           </ul>
146                             </div>
147                         [% END %]
148
149 <div id="branchtransfers">
150     <form method="post" name="mainform" id="mainform" action="/cgi-bin/koha/circ/branchtransfers.pl">
151         <fieldset class="brief">
152             <legend>Transfer</legend>
153             <ol>
154             <li>
155                 <label for="tobranchcd">Destination library: </label>
156                     <select name="tobranchcd" id="tobranchcd">
157                         [% PROCESS options_for_libraries libraries => Branches.all( selected => tobranchcd, unfiltered => 1) %]
158                     </select>
159             </li>
160             <li>
161                 <label for="barcode">Enter barcode: </label>
162                 <input name="barcode" id="barcode" size="15" class="focus" type="text" /> <input type="submit" value="Submit" />
163             </li>
164                         </ol>
165         </fieldset>
166         <input type="hidden" name="tobranchcd" value="[% tobrancd | html %]" />
167         [% FOREACH trsfitemloo IN trsfitemloop %]
168             <input type="hidden" name="bc-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.item.barcode | html %]" />
169             <input type="hidden" name="fb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.frombrcd | html %]" />
170             <input type="hidden" name="tb-[% trsfitemloo.counter | html %]" value="[% trsfitemloo.tobrcd | html %]" />
171         [% END %]
172     </form>
173 </div>
174
175     [% IF ( trsfitemloop ) %]
176                 <table>
177             <caption>Transferred items</caption>
178             <tr>
179                 <th class="tf-title">Title</th>
180                 <th class="tf-author">Author</th>
181                 <th class="tf-barcode">Barcode</th>
182                 <th class="tf-location">Shelving location</th>
183                 <th class="tf-itemcallnumber">Call number</th>
184                 <th class="tf-itemtype">Item type</th>
185                 <th class="tf-ccode">Collection</th>
186                 <th class="tf-origin">Origin</th>
187                 <th class="tf-destination">Destination</th>
188             </tr>
189             [% FOREACH trsfitemloo IN trsfitemloop %]
190                 <tr>
191                     <td class="tf-title">
192                         [% INCLUDE 'biblio-title.inc' biblio=trsfitemloo.item.biblio link=1 %]
193                         </a>
194                     </td>
195                     <td class="tf-author">[% trsfitemloo.item.biblio.author | html %]</td>
196                     <td class="tf-barcode"><a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% trsfitemloo.item.biblionumber | uri %]&amp;itemnumber=[% trsfitemloo.item.itemnumber | uri %]#item[% trsfitemloo.item.itemnumber | uri %]">[% trsfitemloo.item.barcode | html %]</a></td>
197                     <td class="tf-location"><span class="shelvingloc">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.location', authorised_value => trsfitemloo.item.location ) | html %]</span></td>
198                     <td class="tf-itemcallnumber">[% trsfitemloo.item.itemcallnumber | html %]</td>
199                     <td class="tf-itemtype">[% ItemTypes.GetDescription( trsfitemloo.item.effective_itemtype ) | html %]</td>
200                     <td class="tf-ccode">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => trsfitemloo.item.ccode ) | html %]</td>
201                     <td class="tf-origin">[% Branches.GetName( trsfitemloo.frombrcd ) | html %]</td>
202                     <td class="tf-destination">[% Branches.GetName( trsfitemloo.tobrcd ) | html %]</td>
203                 </tr>
204             [% END %]
205         </table>
206     [% END %]
207         
208         
209 [% END %]
210
211     </main>
212         </div> <!-- /.col-sm-10.col-sm-push-2 -->
213         [% IF Koha.Preference('CircSidebar') %]
214             <div class="col-sm-2 col-sm-pull-10">
215                 <aside>
216                     [% INCLUDE 'circ-nav.inc' %]
217                 </aside>
218             </div> <!-- /.col-sm-2.col-sm-pull-10 -->
219         [% END %]
220     </div> <!-- /.row -->
221
222 [% INCLUDE 'intranet-bottom.inc' %]