]> git.koha-community.org Git - koha.git/blob - koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-print.tt
Bug 14048: Add syspref and atomic update
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / labels / label-print.tt
1     [% INCLUDE 'doc-head-open.inc' %]
2     <title>Koha &rsaquo; Tools &rsaquo; Label creator &rsaquo; Label printing/exporting</title>
3     [% INCLUDE 'doc-head-close.inc' popup => 1 %]
4     <script type="text/javascript">
5         //<![CDATA[
6             function Done() {
7                 window.location = "[% referer %]";
8             };
9         //]]>
10     </script>
11     <style type="text/css">#custom-doc {width:47.23em; *width:46.04em; min-width:610px; margin:auto; margin-top:0.4em;}</style>
12     <style type="text/css">table {border-collapse: separate; border-spacing: 0; border: hidden none;} .header {cursor: auto; background-position: center center; background-repeat: repeat;}</style>
13 </head>
14 <body id="labels_label-print" class="tools labels">
15     <div id="custom-doc" class="yui-t2">
16         <div id="bd">
17             [% IF ( batches ) %]
18             <form>
19                 <h3>Click on the following links to download the exported batch(es).</h3>
20                         [% FOREACH batche IN batches %]
21                         <fieldset>
22                             [% IF ( batche.label_ids ) %]
23                                 <legend>[% IF ( batche.label_count == 1 ) %][% batche.label_count %] single label[% ELSE %][% batche.label_count %] single labels[% END %]</legend>
24                                     <p><a class="document pdf" href="/cgi-bin/koha/labels/[% batche.create_script %]?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %][% batche.label_ids %]">Download as PDF</a></p>
25
26                                     <p><a class="document csv" href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.label_ids %]">Download as CSV</a></p>
27
28                                     <p><a class="document xml" href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.label_ids %]">Download as XML</a></p>
29                             [% ELSIF ( batche.item_numbers ) %]
30                             <legend>[% IF ( batche.label_count == 1 ) %][% batche.label_count %] single label[% ELSE %][% batche.label_count %] single labels[% END %]</legend>
31                                     <p><a class="document pdf" href="/cgi-bin/koha/labels/[% batche.create_script %]?template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %][% batche.item_numbers %]">Download as PDF</a></p>
32
33                                     <p><a class="document csv" href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.item_numbers %]">Download as CSV</a></p>
34
35                                     <p><a class="document xml" href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %][% batche.item_numbers %]">Download as XML</a></p>
36                             [% ELSE %]
37                             <legend>Label Batch Number [% batche.batch_id %]</legend>
38                                     <p><a class="document pdf" href="/cgi-bin/koha/labels/label-create-pdf.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]&amp;start_label=[% batche.start_label %]">Download as PDF</a>
39                                 </p>
40                                 <p>
41                                     <a class="document csv" href="/cgi-bin/koha/labels/label-create-csv.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]">Download as CSV</a>
42                                 </p>
43                                 <p>
44                                     <a class="document xml" href="/cgi-bin/koha/labels/label-create-xml.pl?batch_id=[% batche.batch_id %]&amp;template_id=[% batche.template_id %]&amp;layout_id=[% batche.layout_id %]">Download as XML</a></p>
45                             [% END %]
46                         </fieldset>
47                         [% END %]
48                 <fieldset class="action">
49                     <input type="button" id="done" onclick="parent.parent.GB_hide();" class="submit" value="Done" />
50                 </fieldset>
51             </form>
52             [% ELSE %]
53             <h3>
54                 [% IF ( label_ids ) %]
55                     [% IF ( label_count == 1 ) %]Exporting [% label_count %] label[% ELSE %]Exporting [% label_count %] labels[% END %]
56                 [% ELSIF ( item_numbers ) %]
57                     [% IF ( item_count == 1 ) %]Exporting [% item_count %] label[% ELSE %]Exporting [% item_count %] labels[% END %]
58                 [% ELSE %]
59                     [% IF ( multi_batch_count == 1 ) %][% multi_batch_count %] batch to export[% ELSE %][% multi_batch_count %] batches to export[% END %]
60                 [% END %]
61             </h3>
62             <form name="exporting" method="post" action="/cgi-bin/koha/labels/label-print.pl">
63                 <input type="hidden" name="op" value="export" />
64                 <input type="hidden" name="referer" value="[% referer %]" />
65                 [% FOREACH batch_id IN batch_ids %]
66                     <input type="hidden" name="batch_id" value="[% batch_id.batch_id %]" />
67                 [% END %]
68                 [% FOREACH label_id IN label_ids %]
69                     <input type="hidden" name="label_id" value="[% label_id.label_id %]" />
70                 [% END %]
71                 [% FOREACH item_number IN item_numbers %]
72                     <input type="hidden" name="item_number" value="[% item_number.item_number %]" />
73                 [% END %]
74                 <fieldset class="rows">
75                     <ol>
76                         <li>
77                             <label for="template_id" style="width:20em">Select a template to be applied: </label>
78                             <select name="template_id" id="template_id">
79                                     [% FOREACH template IN templates %]
80                                     <option value="[% template.template_id %]">[% template.template_code %]</option>
81                                     [% END %]
82                                 </select>
83                         </li>
84                         <li>
85                             <label for="layout_id" style="width:20em">Select a layout to be applied: </label>
86                             <select name="layout_id" id="layout_id">
87                                     [% FOREACH layout IN layouts %]
88                                     <option value="[% layout.layout_id %]">[% layout.layout_name %]</option>
89                                     [% END %]
90                                 </select>
91                         </li>
92                         <li>
93                             <label for="start_label" style="width:20em">Enter starting label position (for PDF): </label>
94                             <input type="text" size="5" id="start_label" name="start_label" class="focus" title="Starting label number" value="1"/>
95                         </li>
96                     </ol>
97                 </fieldset>
98                 <fieldset class="action">
99                     <input type="submit" class="submit" value="Export" />
100                     <a href="#" class="cancel" id="done" onclick="parent.parent.GB_hide();return false;">Cancel</a>
101                 </fieldset>
102             </form>
103             [% END %]
104         </div>
105 [% INCLUDE 'popup-bottom.inc' %]