2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha › Cataloguing › plugin for links</title>
4 [% INCLUDE 'doc-head-close.inc' %]
8 <body id="cat_marc21_linking_section" class="cat" style="padding:1em;">
9 <h3>MARC21 Plugin to build links between records</h3>
13 <body id="cat_marc21_linking_section" class="cat" style="padding:1em;">
14 <h3>Plugin to build links between records</h3>
16 <div id="MARC21_Linking_section_search">
18 <form name="f" method="post" action="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl">
21 <input type="hidden" name="plugin_name" value="marc21_linking_section.pl" />
22 <input type="hidden" name="index" value="[% index | html %]" />
23 <input type="hidden" name="result" value="marc12 field 7 [% index | html %]" />
24 <input type="hidden" name="op" value="do_search" />
25 <label class="label100" for="searchbox">Any word</label>
26 <input type="text" name="search" id="searchbox" size="35" /><br />
27 <label for="itypeloop">Item type</label>
28 <select name="itype" id="itypeloop">
29 <option value="" selected="selected">All Item Types</option>
30 [% FOREACH itypeloo IN itypeloop %]
31 <option value="[% itypeloo.itemtype | html %]">[% itypeloo.description | html %]</option>
36 <input type="submit" value="Start search" />
45 <h2>Search results</h2>
46 <div id="MARC21_Linking_section__resultnumber">
47 <p>[% IF ( displayprev ) %] <a class="resultnumber" href="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | html %]&startfrom=[% startfromprev | html %]&search=[% search | html %]&resultsperpage=[% resultsperpage | html %]&type=intranet&op=do_search"><< Previous</a>[% END %]
48 [% FOREACH number IN numbers %]
49 [% IF ( number.highlight ) %] <span class="highlight">[% number.number | html %]</span>
50 [% ELSE %] <a class="resultnumber" href="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | html %]&startfrom=[% number.startfrom | html %]&search=[% number.search |url %]&resultsperpage=[% number.resultsperpage | html %]&type=intranet&op=do_search">[% number.number | html %]</a>
53 [% IF ( displaynext ) %]
54 <a class="resultnumber" href="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | html %]&startfrom=[% startfromnext | html %]&search=[% search | html %]&resultsperpage=[% resultsperpage | html %]&type=intranet&op=do_search">Next>></a>
56 <p class="resultcount">
57 [% IF ( total ) %]Results [% from | html %] to [% to | html %] of [% total | html %]
58 [% ELSE %]No results found
63 <th>Concise description</th>
66 [% FOREACH resul IN result %]
67 [% IF ( resul.title ) %]
69 [% IF ( resul.even ) %]<td class="hilighted">
70 [% ELSE %]<td>[% END %]
71 [% IF ( resul.MARC_ON ) %]
72 <a class="transparent resultlist" href="/cgi-bin/koha/MARCdetail.pl?biblionumber=[% resul.biblionumber |url %]">[% resul.title | html %]</a>
74 <a class="transparent resultlist" href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% resul.biblionumber |url %]">[% resul.title | html %]</a>
76 <p>[% resul.author | html %]
77 [% IF ( resul.publishercode ) %]- [% resul.publishercode | html %][% END %]
78 [% IF ( resul.place ) %] ; [% resul.place | html %][% END %]
79 [% IF ( resul.pages ) %] - [% resul.pages | html %][% END %]
80 [% IF ( resul.notes ) %] : [% resul.notes | html %][% END %]
81 [% IF ( resul.size ) %] ; [% resul.size | html %][% END %]
86 [% IF ( resul.biblionumber ) %]
87 <a href="javascript:jumpfull('/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | uri %]&biblionumber=[% resul.biblionumber | uri %]&type=intranet&op=fillinput')">Choose</a>
89 <a href="javascript:jumpfull('/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | uri %]&type=intranet&op=fillinput')">Clear field</a>
97 <div id="resultnumber">
99 [% IF ( displayprev ) %]
100 <a class="resultnumber" href="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&amp;index=[% index | html %]&amp;startfrom=[% startfromprev | html %]&amp;search=[% search |url %]&amp;resultsperpage=[% resultsperpage | html %]&amp;type=intranet&amp;op=do_search">
105 [% FOREACH number IN numbers %]
106 [% IF ( number.highlight ) %]
107 <span class="highlight">
108 [% number.number | html %]
111 <a class="resultnumber" href="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | html %]&startfrom=[% number.startfrom | html %]&search=[% number.search | html %]&resultsperpage=[% number.resultsperpage | html %]&type=intranet&op=do_search">
112 [% number.number | html %]
117 [% IF ( displaynext ) %]
118 <a class="resultnumber" href="/cgi-bin/koha/cataloguing/plugin_launcher.pl?plugin_name=marc21_linking_section.pl&index=[% index | html %]&startfrom=[% startfromnext | html %]&search=[% search | html %]&resultsperpage=[% resultsperpage | html %]&type=intranet&op=do_search">
128 [% MACRO jsinclude BLOCK %]
129 [% IF ( fillinput ) %]
130 <script type="text/javascript">
133 var index_start = "[% index | html %]";
136 whichfield = opener.opener.document.getElementById(index_start);
141 // browse all its subfields
143 var subfields = whichfield.parentNode.parentNode.getElementsByTagName('input');
145 var re = /^tag_\d*_code_/;
146 for (var i = 0, len = subfields.length; i < len; i++) {
147 if (subfields[i].hasAttribute('name') == 0) { continue; } // div elements specific to Select2
148 if (subfields[i].getAttribute('name').match(re)) { // it s a subfield
149 var code = subfields[i];
150 var subfield = subfields[i + 1];
152 if (code.value == '9') {
153 subfield.value = "[% subfield_value_9 | html %]";
155 if (code.value == '0') {
156 subfield.value = "[% subfield_value_0 | html %]";
158 if (code.value == 'a') {
159 subfield.value = "[% subfield_value_a | html %]";
161 if (code.value == 'c') {
162 subfield.value = "[% subfield_value_c | html %]";
164 if (code.value == 'd') {
165 subfield.value = "[% subfield_value_d | html %]";
167 if (code.value == 'e') {
168 subfield.value = "[% subfield_value_e | html %]";
170 if (code.value == 'h') {
171 subfield.value = "[% subfield_value_h | html %]";
173 if (code.value == 'i') {
174 subfield.value = "[% subfield_value_i | html %]";
176 if (code.value == 'p') {
177 subfield.value = "[% subfield_value_p | html %]";
179 if (code.value == 't') {
180 subfield.value = "[% subfield_value_t | html %]";
182 if (code.value == 'u') {
183 subfield.value = "[% subfield_value_u | html %]";
185 if (code.value == 'v') {
186 subfield.value = "[% subfield_value_v | html %]";
188 if (code.value == 'w') {
189 subfield.value = "[% subfield_value_w | html %]";
191 if (code.value == 'x') {
192 subfield.value = "[% subfield_value_x | html %]";
194 if (code.value == 'y') {
195 subfield.value = "[% subfield_value_y | html %]";
197 if (code.value == 'z') {
198 subfield.value = "[% subfield_value_z | html %]";
205 window.onload = go();
210 <script type="text/javascript">
211 function report(value2report) {
212 if (document.f_pop.result.value.length == 0) {
213 document.f_pop.result.value = value2report;
215 document.f_pop.result.value = document.f_pop.result.value + '|' + value2report;
221 opener.document.f.field_value[[ % index % ]].value = document.f_pop.result.value;
227 <script type="text/javascript">
228 function jumpfull(page){
229 window.open(page,'','width=100,height=100,toolbar=false,scrollbars=yes');
234 [% INCLUDE 'intranet-bottom.inc' popup_window=1 %]