Merge commit 'pianohacker-koha/prefs-submit' into master
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / labels / label-edit-template.tmpl
1     <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2     <title>Koha &rsaquo; Tools &rsaquo; Labels &rsaquo; Templates</title>
3     <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4         <script type="text/javascript">
5         //<![CDATA[
6                 $(document).ready(function(){
7                 var selectedUnit = $("#units option:selected").attr("value");
8                 var unitfields = $("#page_height,#page_width,#label_width,#label_height,#top_margin,#left_margin,#top_text_margin,#left_text_margin,#col_gap,#row_gap");
9                 $(unitfields).after("<span class=\"unit\">"+getUnit(selectedUnit)+"</span>");
10                 $("#units").change(function(){
11                         $(".unit").html(getUnit($(this).val()));
12                 });
13                 function getUnit(unit){
14                         switch(unit){
15                                 case "POINT":
16                                         var unit = " pt";
17                                         break;
18                                 case "AGATE":
19                                         var unit = " ag";
20                                         break;
21                                 case "INCH":
22                                         var unit = " in";
23                                         break;
24                                 case "MM":
25                                         var unit = " mm";
26                                         break;
27                                 case "CM":
28                                         var unit = " cm";
29                                         break;
30                                 default:
31                                         var unit = "";
32                         }
33                         return unit;
34                 }
35                 });
36         //]]>
37         </script>
38 </head>
39 <body>
40     <!-- TMPL_INCLUDE NAME="header.inc" -->
41     <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
42     <div id="breadcrumbs">
43         <a href="/cgi-bin/koha/mainpage.pl">Home</a>&rsaquo;
44         <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a>&rsaquo;
45         <a href="/cgi-bin/koha/labels/label-home.pl">Labels</a>&rsaquo;
46         <a href="/cgi-bin/koha/labels/label-manage.pl?label_element=template">Label Templates</a>&rsaquo;
47         Edit Label Template
48     </div>
49     <div id="doc3" class="yui-t2">
50         <div id="bd">
51             <div id="yui-main">
52                 <div class="yui-b">
53                     <form name="input" action="/cgi-bin/koha/labels/label-edit-template.pl" method="get">
54                     <div class="yui-g">
55                         <h3>Edit Label Template</h3>
56                         <div class="yui-u first">
57                             <fieldset class="rows">
58                                 <ol>
59                                     <li>
60                                         <span class="label">Template ID:</span><!-- TMPL_IF NAME="template_id" --><!-- TMPL_VAR NAME="template_id" --><!-- TMPL_ELSE -->N/A<!-- /TMPL_IF -->
61                                     </li>
62                                     <li>
63                                         <label for="template_code">Template Code:</label>
64                                         <input type="text" size="30" maxlength="43" name="template_code" id="template_code" value="<!-- TMPL_VAR NAME="template_code" -->" />
65                                     </li>
66                                     <li>
67                                         <label for="template_desc">Template Description:</label>
68                                         <textarea cols="30" rows="3" id="template_desc" name="template_desc"><!-- TMPL_VAR NAME="template_desc" --></textarea>
69                                     </li>
70                                                                         <li>
71                                  <label for="units">Units:</label>
72                                  <select id="units" name="units">
73                                  <!-- TMPL_LOOP NAME="units" -->
74
75                                                                         <!-- TMPL_IF NAME="selected" -->
76                                                                         <option value="<!-- TMPL_VAR NAME="type" -->" selected="selected">
77                                                                         <!-- TMPL_ELSE -->
78                                                                         <option value="<!-- TMPL_VAR NAME="type" -->">
79                                                                         <!-- /TMPL_IF -->
80
81                                  <!-- TMPL_VAR NAME="desc" -->
82                                  </option>
83                                  <!-- /TMPL_LOOP -->
84                                  </select>
85                              </li>
86                                     <li>
87                                         <label for="page_height">Page Height:</label>
88                                         <input type="text" size="4" name="page_height" id="page_height" value="<!-- TMPL_VAR NAME="page_height" -->" />
89                                     </li>
90                                     <li>
91                                         <label for="page_width">Page Width:</label>
92                                         <input type="text" size="4" name="page_width" id="page_width" value="<!-- TMPL_VAR NAME="page_width" -->" />
93                                     </li>
94                                     <li>
95                                         <label for="label_width">Label Width:</label>
96                                         <input type="text" size="4" name="label_width" id="label_width" value="<!-- TMPL_VAR NAME="label_width" -->" />
97                                     </li>
98                                     <li>
99                                         <label for="label_height">Label Height:</label>
100                                         <input type="text" size="4" name="label_height" id="label_height" value="<!-- TMPL_VAR NAME="label_height" -->" />
101                                     </li>
102
103                                 </ol>
104                             </fieldset>
105                         </div>
106                         <div class="yui-u">
107                             <fieldset class="rows">
108                                 <ol><li>
109                                     <label for="top_margin">Top Page Margin:</label>
110                                     <input type="text" size="4" name="top_margin" id="top_margin" value="<!-- TMPL_VAR NAME="top_margin" -->" />
111                                 </li>
112                                 <li>
113                                     <label for="left_margin">Left Page Margin:</label>
114                                     <input type="text" size="4" name="left_margin" id="left_margin" value="<!-- TMPL_VAR NAME="left_margin" -->" />
115                                 </li>
116                                     <li>
117                                         <label for="top_text_margin">Top Text Margin:</label>
118                                         <input type="text" size="4" name="top_text_margin" id="top_text_margin" value="<!-- TMPL_VAR NAME="top_text_margin" -->" />
119                                     </li>
120                                     <li>
121                                         <label for="left_text_margin">Left Text Margin:</label>
122                                         <input type="text" size="4" name="left_text_margin" id="left_text_margin" value="<!-- TMPL_VAR NAME="left_text_margin" -->" />
123                                     </li>
124                                     <li>
125                                         <label for="cols">Number of Columns:</label>
126                                         <input type="text" size="4" name="cols" id="cols" value="<!-- TMPL_VAR NAME="cols" -->" />
127                                     </li>
128                                     <li>
129                                         <label for="rows">Number of Rows:</label>
130                                         <input type="text" size="4" name="rows" id="rows" value="<!-- TMPL_VAR NAME="rows" -->" />
131                                     </li>
132                                     <li>
133                                         <label for="col_gap">Gap between Columns:</label>
134                                         <input type="text" size="4" name="col_gap" id="col_gap" value="<!-- TMPL_VAR NAME="col_gap" -->" />
135                                     </li>
136                                     <li>
137                                         <label for="row_gap">Gap between Rows:</label>
138                                         <input type="text" size="4" name="row_gap" id="row_gap" value="<!-- TMPL_VAR NAME="row_gap" -->" />
139                                     </li>
140
141                                     <li>
142                                         <label for="profile_id">Profile:</label>
143                                         <!-- TMPL_IF NAME="profile_list" -->
144                                         <select id="profile_id" name="profile_id">
145                                         <!-- TMPL_LOOP NAME="profile_list" -->
146 <!-- TMPL_IF NAME="selected" -->
147 <option value="<!-- TMPL_VAR NAME="profile_id" -->" selected="selected">
148 <!-- TMPL_ELSE -->
149 <option value="<!-- TMPL_VAR NAME="profile_id" -->">
150 <!-- /TMPL_IF -->
151                                         <!-- TMPL_VAR NAME="printer_name" -->/<!-- TMPL_VAR NAME="paper_bin" -->
152                                         </option>
153                                         <!-- /TMPL_LOOP -->
154                                         </select>
155                                         <!-- TMPL_ELSE -->
156                                         <a href="/cgi-bin/koha/tools/tools-edit-profile.pl?op=new">Click here to define a printer profile.</a>
157                                         <!-- /TMPL_IF -->
158                                     </li>
159                                 </ol>
160                             </fieldset>
161                         </div>
162                     </div>
163                     <div class="yui-g">
164                         <fieldset class="action">
165                             <input type="submit" class="submit" value="Save" /><a class="cancel" href="/cgi-bin/koha/labels/label-manage.pl?label_element=template">Cancel</a>
166                             <input type="hidden" name="op" value="save" />
167                             <!-- TMPL_IF NAME="template_id" -->
168                             <input type="hidden" name="template_id" value="<!-- TMPL_VAR NAME="template_id" -->" />
169                             <!-- /TMPL_IF -->
170                         </fieldset>
171                     </div>
172                 </form>
173             </div>
174         </div>
175         <div class="yui-b">
176             <!-- TMPL_INCLUDE NAME="labels-menu.inc" -->
177         </div>
178     </div>
179     <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->