3 [% USE AuthorisedValues %]
7 [% INCLUDE 'doc-head-open.inc' %]
8 <title>Koha › Serials › Serial collection information for [% bibliotitle | html %]</title>
9 [% INCLUDE 'doc-head-close.inc' %]
10 [% Asset.css("css/datatables.css") | $raw %]
13 <body id="ser_serials-collection" class="ser">
14 [% INCLUDE 'header.inc' %]
15 [% INCLUDE 'serials-search.inc' %]
17 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/serials/serials-home.pl">Serials</a> › Serial collection information for <i>[% bibliotitle | html %]</i></div>
19 <div class="main container-fluid">
21 <div class="col-sm-10 col-sm-push-2">
24 [% INCLUDE 'modals/serials_multi_receiving.inc' %]
26 [% UNLESS ( popup ) %]
27 [% INCLUDE 'serials-toolbar.inc' %]
29 <h1>Serial collection information for <i>[% bibliotitle | html %]</i>
30 [% IF location %] ([% AuthorisedValues.GetByCode( 'LOC', location ) | html %]) [% END %]
31 [% IF ( callnumber ) %]callnumber: [% callnumber | html %][% END %]</h1>
34 [% IF ( subscriptions ) %]
36 [% IF ( subscriptions.size == 1 ) %]
37 <caption> Subscription summary</caption>
39 <caption> Subscription summaries</caption>
42 <th>Subscription num.</th>
44 <th>Numbering pattern</th>
50 [% FOREACH subscription IN subscriptions %]
52 <td><a href="subscription-detail.pl?subscriptionid=[% subscription.subscriptionid | html %]"># [% subscription.subscriptionid | html %]</a> </td>
53 <td>[% subscription.frequency.description | html %]</td>
54 <td>[% subscription.numberpattern.label | html %]</td>
55 <td>[% IF subscription.branchcode %][% Branches.GetName( subscription.branchcode ) | html %][% END %]</td>
56 <td> [% subscription.callnumber | html %]</td>
57 <td> [% subscription.notes | html %]
58 [% UNLESS subscription.closed %]
59 [% IF ( subscription.subscriptionexpired ) %]
60 <br /><span class="problem"> Subscription expired</span>
63 <br /> Subscription closed
66 [% IF ( subscription.abouttoexpire ) || ( subscription.subscriptionexpired ) %]<td class="problem actions">[% ELSE %]<td class="actions">[% END %]
67 [% UNLESS subscription.closed %]
68 [% IF ( routing && CAN_user_serials_routing ) %]
69 [% IF ( subscription.hasRouting ) %]
70 <a class="btn btn-default btn-xs" href="/cgi-bin/koha/serials/routing.pl?subscriptionid=[% subscription.subscriptionid | html %]"><i class="fa fa-pencil"></i> Edit routing list</a>
72 <a class="btn btn-default btn-xs" href="/cgi-bin/koha/serials/routing.pl?subscriptionid=[% subscription.subscriptionid | html %]&op=new"><i class="fa fa-plus"></i> Create routing list</a>
75 [% IF ( subscription.abouttoexpire ) %]<a class="btn btn-default btn-xs" href="/cgi-bin/koha/serials/subscription-renew.pl?subscriptionid=[% subscription.subscriptionid | html %]" onclick="popup([% subscription.subscriptionid | html %]); return false;"><i class="fa fa-refresh"></i> Renew</a>
77 [% IF ( subscription.subscriptionexpired ) %]<a class="btn btn-default btn-xs" href="/cgi-bin/koha/serials/subscription-renew.pl?subscriptionid=[% subscription.subscriptionid | html %]" onclick="popup([% subscription.subscriptionid | html %]); return false;"><i class="fa fa-refresh"></i> Renew</a>
89 [% IF ( subscriptioncount > 1 ) %]
90 <tr ><td colspan="8"> <a href="serials-collection.pl?biblionumber=[% biblionumber | html %]">See any subscription attached to this biblio</a></td>
98 [% IF ( years ) %]<form name="edition" action="serials-edit.pl" method="post">
99 <div id="subscription_years" class="toptabs numbered">
101 [% FOREACH year IN years %]
102 [% IF ( year.year ) %]
103 [% IF year.year == 'manage' %]
104 <li><a href="#subscription-year-manage">Manage</a></li>
106 <li><a href="#subscription-year-[% year.year | html %]">[% year.year | html %]</a></li>
112 [% FOREACH year IN years %]
113 <div id="subscription-year-[% year.year | html %]">
114 [% IF ( CAN_user_serials_receive_serials ) %]
116 <div class="btn-group"><input type="submit" value="Edit serials" class="btn btn-default btn-sm" /></div>
117 [% UNLESS subscription.closed %]
118 <div class="btn-group"><input type="button" value="Generate next" onclick="javascription:generateNext([% subscriptionidlist | html %])" class="btn btn-default btn-sm" /></div>
119 [% IF ( subscriptions.size == 1 and !serialsadditems ) %]
120 <div class="btn-group"><input type="button" value="Multi receiving" href="#multi_receiving" class="btn btn-default btn-sm" data-toggle="modal"></div>
125 <span class="checkall">
126 <a class="CheckAll" href="#" onclick="CheckAll('subscription-year-[% year.year | html %]'); return false;">Select all</a>
128 <span class="clearall">
129 <a class="CheckNone" href="#" onclick="CheckNone('subscription-year-[% year.year | html %]'); return false;">Clear all</a>
131 <table class="subscription-year-table">
134 [% IF ( CAN_user_serials_receive_serials ) %]<th>Edit</th>[% END %]
135 [% IF ( subscriptions.size > 1 ) %]
138 <th class="title-string">Date published
140 <th class="title-string">Date published (text)
142 <th class="title-string">Date received
152 [% IF ( routing ) %]<th>Routing</th>[% END %]
156 [% FOREACH serial IN year.serials %]
158 [% IF ( CAN_user_serials_receive_serials ) %]
160 [% UNLESS CAN_user_serials_receive_serials %]
163 [% IF ( serial.subscriptionexpired ) %]
164 <input type="checkbox" name="serialid" value="[% serial.serialid | html %]" disabled="disabled" />
166 [% IF ( serial.checked ) %]
167 <input type="checkbox" class="checkboxed" name="serialid" checked="checked" value="[% serial.serialid | html %]" />
169 <input type="checkbox" class="checkboxed" name="serialid" value="[% serial.serialid | html %]" />
175 [% IF ( subscriptions.size > 1 ) %]
176 <td><a href="serials-collection.pl?subscriptionid=[% serial.subscriptionid | html %]">[% serial.subscriptionid | html %]</a></td>
179 <span title="[% serial.publisheddate | html %]">
180 [% IF serial.publisheddate %]
181 [% serial.publisheddate | $KohaDates %]
188 [% IF serial.publisheddatetext %]
189 <span title="[% serial.publisheddatetext | html %]">
190 [% serial.publisheddatetext | html %]
195 <span title="[% serial.planneddate | html %]">
196 [% IF serial.planneddate %]
197 [% serial.planneddate | $KohaDates %]
204 [% IF ( matches = serial.serialseq.match('(.*)Spring(.*)') ) %]
205 [% matches.0 | html %]Spring[% matches.1 | html %]
206 [% ELSIF ( matches = serial.serialseq.match('(.*)Summer(.*)') ) %]
207 [% matches.0 | html %]Summer[% matches.1 | html %]
208 [% ELSIF ( matches = serial.serialseq.match('(.*)Fall(.*)') ) %]
209 [% matches.0 | html %]Fall[% matches.1 | html %]
210 [% ELSIF ( matches = serial.serialseq.match('(.*)Winter(.*)') ) %]
211 [% matches.0 | html %]Winter[% matches.1 | html %]
212 [% ELSIF ( matches = prediction.number.match('(.*)Spr(.*)') ) %]
213 [% matches.0 | html %]Spr[% matches.1 | html %]
214 [% ELSIF ( matches = prediction.number.match('(.*)Sum(.*)') ) %]
215 [% matches.0 | html %]Sum[% matches.1 | html %]
216 [% ELSIF ( matches = prediction.number.match('(.*)Fal(.*)') ) %]
217 [% matches.0 | html %]Fal[% matches.1 | html %]
218 [% ELSIF ( matches = prediction.number.match('(.*)Win(.*)') ) %]
219 [% matches.0 | html %]Win[% matches.1 | html %]
221 [% serial.serialseq | html %]
225 [% IF ( serial.status1 ) %]Expected[% END %]
226 [% IF ( serial.status2 ) %]Arrived[% END %]
227 [% IF ( serial.status3 ) %]Late[% END %]
228 [% IF ( serial.status4 ) %]Missing[% END %]
229 [% IF ( serial.status41 ) %]Missing (never received)[% END %]
230 [% IF ( serial.status42 ) %]Missing (sold out)[% END %]
231 [% IF ( serial.status43 ) %]Missing (damaged)[% END %]
232 [% IF ( serial.status44 ) %]Missing (lost)[% END %]
233 [% IF ( serial.status5 ) %]Not issued[% END %]
234 [% IF ( serial.status6 ) %]Delete[% END %]
235 [% IF ( serial.status7 ) %]Claimed[% END %]
236 [% IF ( serial.status8 ) %]Stopped[% END %]
239 [% serial.notes | html %]
242 [% Branches.GetName( serial.branchcode ) | html %]
246 <a href="" onclick="print_slip([% serial.subscriptionid | html %], '[% serial.serialseq.replace("'", "\\'") | html %] ([% serial.publisheddate | $KohaDates %])'); return false" class="btn btn-default btn-xs"><i class="fa fa-print"></i> Print list</a>
255 <input type="hidden" name="subscriptionid" value="[% subscriptionidlist | html %]" />
262 </div> <!-- /.col-sm-10.col-sm-push-2 -->
264 <div class="col-sm-2 col-sm-pull-10">
266 [% INCLUDE 'serials-menu.inc' %]
268 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
269 </div> <!-- /.row -->
271 [% MACRO jsinclude BLOCK %]
272 [% INCLUDE 'datatables.inc' %]
274 var subscriptionid = "[% subscriptionid | html %]";
275 var MSG_CLOSE_SUBSCRIPTION = _("Are you sure you want to close this subscription?");
276 var MSG_REOPEN_SUBSCRIPTION = _("Are you sure you want to reopen this subscription?");
277 var CONFIRM_DELETE_SUBSCRIPTION = _("Are you sure you want to delete this subscription?");
279 [% Asset.js("js/serials-toolbar.js") | $raw %]
280 [% Asset.js("lib/jquery/plugins/jquery.checkboxes.min.js") | $raw %]
284 function print_slip(subscriptionid,issue){
285 var myurl = 'routing-preview.pl?ok=1&subscriptionid='+subscriptionid+'&issue='+issue;
286 window.open(myurl,'PrintSlip','width=500,height=500,toolbar=no,scrollbars=yes');
289 function popup(subscriptionid) {
290 newin=window.open('subscription-renew.pl?mode=popup&subscriptionid='+subscriptionid,'popup','width=500,height=400,toolbar=false,scrollbars=yes');
293 function generateNext(subscriptionid) {
294 if(confirm(_("Do you really want to generate next serial?"))){
295 document.location = 'serials-collection.pl?op=gennext&subscriptionid='+subscriptionid;
299 function CheckAll( node ) {
300 $("#"+node).checkCheckboxes();
303 function CheckNone( node ) {
304 $("#"+node).unCheckCheckboxes();
307 $(document).ready(function() {
308 $('#subscription_years').tabs();
309 $(".subscription-year-table").dataTable($.extend(true, {}, dataTablesDefaults, {
311 { "aTargets": [ 0,-1 ], "bSortable": false, "bSearchable": false },
312 { "sType": "title-string", "aTargets" : [ "title-string" ] }
314 "aaSorting": [[0, 'desc']],
322 $('#multi_receiving').on('show', function () {
323 $(this).find(".modal-body").html($(".serials_multi_receiving")[0].outerHTML);
326 $("form[name='edition']").on('submit', function(e){
327 if ( $(this).find("input[name='serialid']:checked").size() == 0 ) {
329 alert(_("You must select at least one serial to edit"));
339 [% INCLUDE 'intranet-bottom.inc' %]