1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha › Tools › Labels › Manage Label Batches</title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4 <script type="text/JavaScript" language="JavaScript">
8 if(document.items.action.length > 0) {
9 for (var i=0; i < document.items.action.length; i++) {
10 if (document.items.action[i].checked) {
11 items.push("label_id=" + document.items.action[i].value);
14 if (items.length < 1) {
15 alert("Please select at least one item to delete.");
16 return; // no item selected
18 getstr = items.join("&");
20 else if (document.items.action.checked) {
21 getstr = "label_id="+document.items.action.value;
24 alert("Please select at least one item to delete.");
25 return; // no item selected
27 var msg = "Are you sure you want to the selected item(s) from this batch?"
28 var answer = confirm(msg);
30 window.location = "/cgi-bin/koha/labels/label-edit-batch.pl?op=remove&batch_id=<!-- TMPL_VAR NAME="batch_id" -->&" + getstr;
33 return; // abort delete
37 window.location = "/cgi-bin/koha/labels/label-edit-batch.pl?op=add&batch_id=<!-- TMPL_VAR NAME="batch_id" -->";
39 function Print(mode) {
40 if (mode == 'batch') {
41 alert("Print batch <!-- TMPL_VAR NAME="batch_id" -->.");
42 // window.location = "/cgi-bin/koha/labels/label-edit-batch.pl?op=print&batch_id=<!-- TMPL_VAR NAME="batch_id" -->";
45 var label_id = selected_layout();
46 alert("Print item " + label_id + ".");
48 // window.location = "/cgi-bin/koha/labels/label-edit-batch.pl?op=print&batch_id=<!-- TMPL_VAR NAME="batch_id" -->&label_id=" + label_id;
51 // return; // no layout selected
55 function selected_layout() {
56 if (document.items.action.length) {
57 for (i=0;i<document.items.action.length;i++){
58 if (document.items.action[i].checked==true){
59 return(document.items.action[i].value);
64 if (document.items.action.checked){
65 return(document.items.action.value);
67 //var x=document.getElementsByName("action");
70 // return(x[0].value);
73 alert("Please select at least one item.");
80 <!-- TMPL_INCLUDE NAME="header.inc" -->
81 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
82 <div id="breadcrumbs">
83 <a href="/cgi-bin/koha/mainpage.pl">Home</a> ›
84 <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> ›
85 <a href="/cgi-bin/koha/labels/labels-home.pl">Labels</a> ›
86 Manage Batch Number <!-- TMPL_VAR NAME="batch_id" -->
88 <div id="doc3" class="yui-t2">
92 <!-- TMPL_INCLUDE NAME="labels-batches-toolbar.inc" -->
94 <div class="yui-u first" id="manage-label-batches">
95 <div class="hint">Current Branch: <!-- TMPL_VAR NAME="LoginBranchname" --></div>
97 <h2>Items in batch number <!-- TMPL_VAR NAME="batch_id" --></h2>
99 <!-- TMPL_LOOP NAME="table_loop" -->
100 <!-- TMPL_IF NAME="header_fields" -->
102 <!-- TMPL_LOOP NAME="header_fields" -->
103 <th><!-- TMPL_VAR NAME="field_label" --></th>
108 <!-- TMPL_LOOP NAME="text_fields" -->
109 <!-- TMPL_IF NAME="select_field" -->
110 <td align="center"><input type="checkbox" name="action" value="<!-- TMPL_VAR NAME="field_value" -->"></td>
112 <td><!-- TMPL_VAR NAME="field_value" --></td>
120 <div style="margin: 10px 10px 10px 0px;">
121 <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="add" onclick="Add()" value="Add Item(s)"></span></span>
122 <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="remove" onclick="Remove()" value="Remove Item(s)"></span></span>
123 <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="print_item" onclick="Print(item)" value="Print Item(s)"></span></span>
124 <span class="yui-button yui-link-button"><span class="first-child"><input type="button" id="print_batch" onclick="Print(batch)" value="Print Batch"></span></span>
127 <!-- TMPL_IF NAME="err" -->
129 <div class="dialog alert">
130 <strong>WARNING: An error was encountered and <!-- TMPL_VAR NAME="errstr" --> Please have your system administrator check the syslog for details.</strong>
138 <!-- TMPL_INCLUDE NAME="labels-menu.inc" -->
141 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->