Merge remote-tracking branch 'origin/new/bug_5604'
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / acqui / z3950_search.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Acquisitions &rsaquo; Z39.50 Search Results</title>
3 [% INCLUDE 'greybox.inc' %]
4 [% INCLUDE 'doc-head-close.inc' %]
5 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
6 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
7 <script type="text/javascript">
8 //<![CDATA[
9 $.tablesorter.addParser({
10     id: 'articles',
11     is: function(s) {return false;  },
12     format: function(s) { return s.toLowerCase().replace(/^(the|an|a) /,''); },
13     type: 'text'
14 });
15
16         $(document).ready(function(){
17     $.tablesorter.defaults.widgets = ['zebra'];
18     $("#CheckAll").click(function(){
19         $(".checkboxed").checkCheckboxes();
20         return false;
21     });
22     $("#CheckNone").click(function(){
23         $(".checkboxed").unCheckCheckboxes();
24         return false;
25     });
26
27     $("#closemenu").click(function(e){
28         $(".linktools").hide();
29         $("tr").removeClass("selected");
30     });
31
32         $("#resultst").tablesorter({
33                 sortList: [[1,0]],
34                 headers: { 1: { sorter: 'articles' },5: { sorter: false },6: { sorter: false }}
35         });
36         /* Inline edit/delete links */
37         $("td").click(function(event){
38             var $tgt = $(event.target);
39             $(".linktools").hide();
40             $("tr").removeClass("selected");
41             if($tgt.is("a")||$tgt.is(":nth-child(5)")||$tgt.is(":nth-child(6)")||$tgt.is(":nth-child(7)")||$tgt.is(":nth-child(8)")){
42                 return true;
43             } else {
44                 var position = $(this).offset();
45                 var top = position.top+5;
46                 var left = position.left+5;
47                 $(".linktools",row).show().css("position","absolute").css("top",top).css("left",left);
48             }
49             var row = $(this).parent();
50             row.addClass("selected");
51         });
52 });
53 //]]>
54 </script>
55 <style type="text/css">
56 .linktools { background-color:#FFF;border-top:1px solid #DDD; border-left: 1px solid #DDD; border-right: 1px solid #666; border-bottom:1px solid #666;display: none; white-space: nowrap;}
57 .linktools a { font-size : 85%; text-decoration:none; padding:.3em;;background-color:#FFF; display:block;float:left;border-right:1px solid #DDD;}
58 .linktools a:hover { background-color:#EEE;color:#CC3300;border-right:1px solid #CCC;}
59 tr.selected { background-color : #FFFFCC; } tr.selected td { background-color : transparent !important; }
60 </style>
61 </head>
62 <body>
63 [% INCLUDE 'header.inc' %]
64 [% INCLUDE 'acquisitions-search.inc' %]
65
66 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/supplier.pl?supplierid=[% booksellerid %]">[% name %]</a> &rsaquo; <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno %]">Basket [% basketno %]</a> &rsaquo; Order from Z39.50 search</div>
67 <div id="doc3" class="yui-t7">
68       <div id="bd">
69           [% IF ( opsearch ) %]
70 <h2>Z39.50 Search Points</h2>
71     <form method="post" action="z3950_search.pl" name="f" class="checkboxed">
72     <input type="hidden" name="op" id="op" value="do_search" />
73         <div class="yui-g">
74     <div class="yui-u first">
75             <fieldset class="rows">
76                  <ol><li><label for="searchtitle">Title: </label> <input type="text" id="searchtitle"  name="title" value="[% title |html %]" /></li>
77                  <li><label for="isbn">ISBN/ISSN: </label> <input type="text" id="isbn" name="isbn" value="[% isbn %]" /></li>
78                  <li><label for="lccall">LC Call Number: </label> <input type="text" id="lccall" name="lccall" value="" /></li>
79          <li><label for="controlnumber">Control No.: </label> <input type="text" id="controlnumber" name="controlnumber" value="" /></li>
80 </ol>
81                 </fieldset>
82             </div>
83     <div class="yui-u">
84         <fieldset class="rows">          <ol><li><label for="author">Author: </label> <input type="text" id="author" name="author" value="[% author %]" /><!--  <label for="Keyword">Keyword</label> <input type="text" name="keyword" value="" /> --></li>
85                  <li> <label for="subject">Subject Heading: </label> <input type="text" id="subject" name="subject" value="" /></li>
86                  <li><label for="dewey">Dewey: </label> <input type="text" id="dewey" name="dewey" value="" /></li></ol></fieldset>
87              <fieldset class="rows" >
88                  <ol>
89                      <li>
90                          <label for="frameworkcode" >Select used MARC framework:</label>
91                          <select id="frameworkcode" name="frameworkcode" >
92                              <option value="">Default</option>
93                          [% FOREACH frameworkcodeloo IN frameworkcodeloop %]
94                              [% IF ( frameworkcodeloo.active ) %]
95                                  <option value="[% frameworkcodeloo.value %]" selected="selected" >[% frameworkcodeloo.frameworktext %]</option>
96                              [% ELSE %]
97                                  <option value="[% frameworkcodeloo.value %]" >[% frameworkcodeloo.frameworktext %]</option>
98                              [% END %]
99                          [% END %]
100                          </select>
101                      </li>
102                  </ol>
103              </fieldset>
104     <input type="hidden" name="biblionumber" value="[% biblionumber %]" />
105     <input type="hidden" name="basketno" value="[% basketno %]" />
106     <input type="hidden" name="booksellerid" value="[% booksellerid %]" />
107             </div>
108 </div>
109 <div class="yui-g">
110 <h2>Search targets <span style="display: inline; font-size: 70%; padding-left: 1em;"><span class="checkall"><a id="CheckAll" href="#">Select All</a></span><span class="clearall"><a id="CheckNone" href="#">Clear All</a></span></span></h2>
111
112     [% FOREACH serverloo IN serverloop %]
113         <p>
114             [% IF ( serverloo.checked ) %]
115                 <input type="checkbox" name="id" id="z3950_[% serverloo.id %]" value="[% serverloo.id %]" checked="checked" />
116             [% ELSE %]
117                 <input type="checkbox" name="id" id="z3950_[% serverloo.id %]" value="[% serverloo.id %]" />
118             [% END %]
119             <label for="z3950_[% serverloo.id %]">[% serverloo.name %] [[% serverloo.host %]]</label>
120
121         </p>
122     [% END %]
123     <fieldset class="action"><input type="submit"  class="submit" value="Search" onclick="cursor :'wait'"/> <a class="cancel close" href="#">Cancel</a></fieldset>
124     </div>
125     </form>
126
127
128 [% ELSE %]
129     <h2>Results</h2>
130     [% IF ( breeding_loop ) %]
131     <table id="resultst">
132 <thead>    <tr>
133         <th>Server</th>
134         <th>Title</th>
135         <th>Author</th>
136         <th>ISBN</th>
137         <th>LCCN</th>
138         <th colspan="2">Preview</th>
139                 <th>&nbsp;</th>
140     </tr></thead>
141     <tbody>[% FOREACH breeding_loo IN breeding_loop %]
142         [% IF ( breeding_loo.breedingid ) %]
143
144         [% IF ( breeding_loo.toggle ) %]<tr class="highlight">[% ELSE %]<tr>[% END %]
145             <td>[% breeding_loo.server %] <div class="linktools"><a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=[% breeding_loo.breedingid %]" rel="gb_page_center[600,500]">Preview MARC</a> <a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&amp;importid=[% breeding_loo.breedingid %]" rel="gb_page_center[600,500]">Preview Card</a> <a href="/cgi-bin/koha/acqui/neworderempty.pl?frameworkcode=[% frameworkcode %]&amp;breedingid=[% breeding_loo.breedingid %]&amp;booksellerid=[% booksellerid %]&amp;basketno=[% basketno %]">Order</a> <a href="#" id="closemenu" title="Close this menu"> X </a></div></td>
146             <td>[% breeding_loo.title |html %]</td>
147             <td>[% breeding_loo.author %]</td>
148             <td>[% breeding_loo.isbn %]</td>
149             <td>[% breeding_loo.lccn %]</td>
150             <td><a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=[% breeding_loo.breedingid %]" title="MARC" rel="gb_page_center[600,500]">MARC</a></td><td><a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&amp;importid=[% breeding_loo.breedingid %]" title="MARC" rel="gb_page_center[600,500]">Card</a></td>
151                         <td><a href="/cgi-bin/koha/acqui/neworderempty.pl?frameworkcode=[% frameworkcode %]&amp;breedingid=[% breeding_loo.breedingid %]&amp;booksellerid=[% booksellerid %]&amp;basketno=[% basketno %]">Order</a></td>
152
153         </tr>
154         [% END %]
155     [% END %]</tbody>
156 </table>
157     [% ELSE %]
158         <p>Nothing found. <a href="javascript: history.back()">Try another search</a>.</p>
159     [% END %]
160
161
162 [% END %]
163
164         </div>
165 </div>
166 [% IF ( numberpending ) %]<h3 align="center">Still [% numberpending %] servers to search</h3>[% END %]
167
168 </body>
169 </html>
170