[16/30] Patron Card Creator print interface and code
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / patroncards / print.tmpl
1     <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2     <title>Koha &rsaquo; Tools &rsaquo; Patron Cards &rsaquo; Patron Card Printing/Exporting</title>
3     <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4     <script type="text/JavaScript" language="JavaScript">
5         //<![CDATA[
6             function Done() {
7                 window.location = "<!-- TMPL_VAR NAME="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;} .tr {border-collapse: separate;}</style>
13 </head>
14 <body>
15     <div id="custom-doc" class="yui-t2">
16         <div id="bd">
17             <!-- TMPL_IF NAME="batches" -->
18             <form>
19                 <div align="center">
20                     <div class="message">
21                         <b>Click on the following link(s) to download the exported batch(es).</b>
22                     </div>
23                 </div>
24                 <fieldset class="rows">
25                     <table class="borderless">
26                         <!-- TMPL_LOOP NAME="batches" -->
27                         <tr>
28                             <!-- TMPL_IF NAME="label_ids" -->
29                             <td class="borderless">
30                                 <!-- TMPL_VAR NAME="card_count" --> Single Patron Cards
31                             </td>
32                             <td class="borderless">
33                                 <h1 id="pdf">
34                                     <a href="/cgi-bin/koha/patroncards/<!-- TMPL_VAR NAME="create_script" -->?batch_id=<!-- TMPL_VAR NAME="batch_id" -->&amp;template_id=<!-- TMPL_VAR NAME="template_id" -->&amp;layout_id=<!-- TMPL_VAR NAME="layout_id" -->&amp;start_card=<!-- TMPL_VAR NAME="start_card" --><!-- TMPL_VAR NAME="label_ids" -->">label_single_<!-- TMPL_VAR NAME="card_count" -->.pdf</a>
35                                 </h1>
36                             </td>
37                             <!-- TMPL_ELSIF NAME="borrower_numbers" -->
38                             <td class="borderless">
39                                 <!-- TMPL_VAR NAME="card_count" --> Single Patron Cards
40                             </td>
41                             <td class="borderless">
42                                 <h1 id="pdf">
43                                     <a href="/cgi-bin/koha/patroncards/<!-- TMPL_VAR NAME="create_script" -->?template_id=<!-- TMPL_VAR NAME="template_id" -->&amp;layout_id=<!-- TMPL_VAR NAME="layout_id" -->&amp;start_card=<!-- TMPL_VAR NAME="start_card" --><!-- TMPL_VAR NAME="borrower_numbers" -->">label_single_<!-- TMPL_VAR NAME="card_count" -->.pdf</a>
44                                 </h1>
45                             </td>
46                             <!-- TMPL_ELSE -->
47                             <td class="borderless">
48                                 Card Batch Number <!-- TMPL_VAR NAME="batch_id" -->
49                             </td>
50                             <td class="borderless">
51                                 <h1 id="pdf">
52                                     <a href="/cgi-bin/koha/patroncards/create-pdf.pl?batch_id=<!-- TMPL_VAR NAME="batch_id" -->&amp;template_id=<!-- TMPL_VAR NAME="template_id" -->&amp;layout_id=<!-- TMPL_VAR NAME="layout_id" -->&amp;start_card=<!-- TMPL_VAR NAME="start_card" -->">label_batch_<!-- TMPL_VAR NAME="batch_id" -->.pdf</a>
53                                 </h1>
54                             </td>
55                             <!-- /TMPL_IF -->
56                         </tr>
57                         <!-- /TMPL_LOOP -->
58                     </table>
59                 </fieldset>
60                 <fieldset class="action">
61                     <div style="margin: 10px 10px 10px 0px;">
62                         <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="done" onclick="parent.parent.GB_hide();" value="Done"></span></span>
63                     </div>
64                 </fieldset>
65             </form>
66             <!-- TMPL_ELSE -->
67             <div align="center">
68                 <div class="message">
69                     <!-- TMPL_IF NAME="label_ids" -->
70                     <b>Exporting <!-- TMPL_VAR NAME="card_count" --> patroncard(s).</b>
71                     <!-- TMPL_ELSIF NAME="borrower_numbers"-->
72                     <b>Exporting <!-- TMPL_VAR NAME="borrower_count" --> patroncard(s).</b>
73                     <!-- TMPL_ELSE -->
74                     <b><!-- TMPL_VAR NAME="multi_batch_count" --> batch(es) to export.</b>
75                     <!-- /TMPL_IF -->
76                 </div>
77             </div>
78             <form name="exporting" method="post" action="/cgi-bin/koha/patroncards/print.pl">
79                 <input type="hidden" name="op" value="export" />
80                 <input type="hidden" name="referer" value="<!-- TMPL_VAR NAME="referer" -->" />
81                 <!-- TMPL_LOOP NAME="batch_ids" -->
82                     <input type="hidden" name="batch_id" value="<!-- TMPL_VAR NAME="batch_id" -->" />
83                 <!-- /TMPL_LOOP -->
84                 <!-- TMPL_LOOP NAME="label_ids" -->
85                     <input type="hidden" name="label_id" value="<!-- TMPL_VAR NAME="label_id" -->" />
86                 <!-- /TMPL_LOOP -->
87                 <!-- TMPL_LOOP NAME="borrower_numbers" -->
88                     <input type="hidden" name="borrower_number" value="<!-- TMPL_VAR NAME="borrower_number" -->" />
89                 <!-- /TMPL_LOOP -->
90                 <fieldset class="rows">
91                     <table class="borderless">
92                         <tr>
93                             <td class="borderless">
94                                 <label for="template">Select a template to be applied: </label>
95                             </td>
96                             <td class="borderless">
97                                 <select name="template_id">
98                                     <!-- TMPL_LOOP NAME="templates" -->
99                                     <option value="<!-- TMPL_VAR NAME="template_id" -->"><!-- TMPL_VAR NAME="template_code"  --></option>
100                                     <!-- /TMPL_LOOP -->
101                                 </select>
102                             </td>
103                         </tr>
104                         <tr>
105                             <td class="borderless">
106                                 <label for="layout">Select a layout to be applied: </label>
107                             </td>
108                             <td class="borderless">
109                                 <select name="layout_id">
110                                     <!-- TMPL_LOOP NAME="layouts" -->
111                                     <option value="<!-- TMPL_VAR NAME="layout_id" -->"><!-- TMPL_VAR NAME="layout_name"  --></option>
112                                     <!-- /TMPL_LOOP -->
113                                 </select>
114                             </td>
115                         </tr>
116                         <tr>
117                             <td class="borderless">
118                                 <label for="start_card">Enter starting card number: </label>
119                             </td>
120                             <td class="borderless">
121                                 <input type="text" size="5" id="start_card" name="start_card" class="focus" title="Starting card number" value="1"/>
122                             </td>
123                         </tr>
124                     </table>
125                 </fieldset>
126                 <fieldset class="action">
127                     <div style="margin: 10px 10px 10px 0px;">
128                         <span class="yui-button yui-link-button"><span class="first-child"><input type="submit" value="Export" /></span></span>
129                         <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="done" onclick="parent.parent.GB_hide();" value="Cancel"></span></span>
130                     </div>
131                 </fieldset>
132             </form>
133             <!-- /TMPL_IF -->
134         </div>
135     <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->