Bug 16522: (follow-up) MARC display templates and get_marc_host fixes
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / includes / auth-finder-search.inc
1 [% USE Koha %]
2 [% PROCESS 'form-blocks.inc' %]
3
4 <div id="toolbar" class="btn-toolbar">
5     <div class="btn-group"><a href="#" id="clear" class="btn btn-default btn-sm"><i class="fa fa-trash"></i> Clear field</a></div>
6     <div class="btn-group"><a href="#" id="createnew" class="btn btn-default btn-sm"><i class="fa fa-plus"></i> Create new authority</a></div>
7 </div>
8 <form name="f" method="get" action="auth_finder.pl">
9             <input type="hidden" name="source" value="[% source | html %]" />
10             <input type="hidden" name="op" value="do_search" />
11             <input type="hidden" name="type" value="intranet" />
12             <input type="hidden" name="index" value="[% index | html %]" />
13                 <fieldset class="rows"><legend>Search options</legend>
14                 <ol><li>
15                     <span class="label">Authority type: </span>
16                     [% authtypecode | html %]
17                     <input type="hidden" name="authtypecode" value="[% authtypecode | html %]" />
18                 </li>
19                 <li>
20                     <label for="mainmainentry">Search main heading ($a only): </label>
21                     <input type="hidden" name="marclist" value="mainmainentry" />
22                     <input type="hidden" name="and_or" value="and" />
23                     <input type="hidden" name="excluding" value="" />
24                     <select name="operator" id="mainmainentry">
25                         [% IF ( operator_mainstr == 'contains' ) %]
26                         <option value="contains" selected="selected">contains</option>
27                         [% ELSE %]
28                         <option value="contains">contains</option>
29                         [% END %]
30                         [% IF ( operator_mainstr == 'start' ) %]
31                         <option value="start" selected="selected">starts with</option>
32                         [% ELSE %]
33                         <option value="start">starts with</option>
34                         [% END %]
35                         [% IF ( operator_mainstr == 'exact' ) %]
36                         <option value="exact" selected="selected">is exactly</option>
37                         [% ELSE %]
38                         <option value="exact">is exactly</option>
39                         [% END %]
40                     </select>
41                     <input id="value_mainstr" style="width:400px;" type="text" name="value_mainstr" value="[% value_mainstr | html %]" />
42                     <div id="yvaluecontainermainmainentry"></div>
43                 </li>
44
45                 <li>
46                     <label for="mainentry">Search main heading: </label>
47                     <input type="hidden" name="marclist" value="mainentry" />
48                     <input type="hidden" name="and_or" value="and" />
49                     <input type="hidden" name="excluding" value="" />
50                     <select name="operator" id="mainentry">
51                         [% IF ( operator_main == 'contains' ) %]
52                         <option value="contains" selected="selected">contains</option>
53                         [% ELSE %]
54                         <option value="contains">contains</option>
55                         [% END %]
56                         [% IF ( operator_main == 'start' ) %]
57                         <option value="start" selected="selected">starts with</option>
58                         [% ELSE %]
59                         <option value="start">starts with</option>
60                         [% END %]
61                         [% IF ( operator_main == 'exact' ) %]
62                         <option value="exact" selected="selected">is exactly</option>
63                         [% ELSE %]
64                         <option value="exact">is exactly</option>
65                         [% END %]
66                     </select>
67                     <input id="value_main" style="width:400px;" type="text" name="value_main" value="[% value_main | html %]" />
68                     <div id="yvaluecontainermainentry"></div>
69                 </li>
70                 <li>
71                     <label for="marclistheading">Search all headings: </label>
72                     <input type="hidden" name="marclist" value="match" />
73                     <input type="hidden" name="and_or" value="and" />
74                     <input type="hidden" name="excluding" value="" />
75                     <select name="operator" id="marclistheading">
76                         [% IF ( operator_match == 'contains' ) %]
77                         <option value="contains" selected="selected">contains</option>
78                         [% ELSE %]
79                         <option value="contains">contains</option>
80                         [% END %]
81                         [% IF ( operator_match == 'start' ) %]
82                         <option value="start" selected="selected">starts with</option>
83                         [% ELSE %]
84                         <option value="start">starts with</option>
85                         [% END %]
86                         [% IF ( operator_match == 'exact' ) %]
87                         <option value="exact" selected="selected">is exactly</option>
88                         [% ELSE %]
89                         <option value="exact">is exactly</option>
90                         [% END %]
91                     </select>
92                     <input type="text" name="value_match" value="[% value_match | html %]" />
93                 </li>
94                 <li>
95                     <label for="marclistanywhere">Search entire record: </label>
96                     <input type="hidden" name="marclist" value="all" />
97                     <input type="hidden" name="and_or" value="and" />
98                     <input type="hidden" name="excluding" value="" />
99                     <select name="operator" id="marclistanywhere">
100                         [% IF ( operator_any == 'contains' ) %]
101                         <option value="contains" selected="selected">contains</option>
102                         [% ELSE %]
103                         <option value="contains">contains</option>
104                         [% END %]
105                         [% IF ( operator_any == 'start' ) %]
106                         <option value="start" selected="selected">starts with</option>
107                         [% ELSE %]
108                         <option value="start">starts with</option>
109                         [% END %]
110                         [% IF ( operator_any == 'exact' ) %]
111                         <option value="exact" selected="selected">is exactly</option>
112                         [% ELSE %]
113                         <option value="exact">is exactly</option>
114                         [% END %]
115                     </select>
116                     <input id="value_any" style="width:400px;" type="text" name="value_any" value="[% value_any | html %]" />
117                     <div id="yvaluecontainermarclist"></div>
118                 </li>
119         <li>
120         <label for="orderby">Sort by: </label>
121         <select name="orderby" id="orderby">
122             [% IF ( orderby == 'HeadingAsc' ) %]
123             <option value="HeadingAsc" selected="selected">Heading A-Z</option>
124             [% ELSE %]
125             <option value="HeadingAsc">Heading A-Z</option>
126             [% END %]
127             [% IF ( orderby == 'HeadingDsc' ) %]
128             <option value="HeadingDsc" selected="selected">Heading Z-A</option>
129             [% ELSE %]
130             <option value="HeadingDsc">Heading Z-A</option>
131             [% END %]
132             [% IF ( orderby == '' && op ) %]
133             <option value="" selected="selected">None</option>
134             [% ELSE %]
135             <option value="">None</option>
136             [% END %]
137         </select>
138         </li></ol></fieldset>
139         [% IF source == 'auth' %]
140         <fieldset class="rows"><legend>Relationship information</legend>
141             <ol>
142             <li>
143                 <label for="relationship">Special relationship: </label>
144                 <select name="relationship" id="relationship">
145                     [% selected=relationship | html %]
146                     [% PROCESS selectoptionopen value='' %]None specified</option>
147                     [% IF Koha.Preference('marcflavour') == 'MARC21' %]
148                       [% PROCESS selectoptionopen value='a' %]a - Earlier heading</option>
149                       [% PROCESS selectoptionopen value='b' %]b - Later heading</option>
150                       [% PROCESS selectoptionopen value='d' %]d - Acronym</option>
151                       [% PROCESS selectoptionopen value='f' %]f - Musical composition</option>
152                       [% PROCESS selectoptionopen value='g' %]g - Broader term</option>
153                       [% PROCESS selectoptionopen value='h' %]h - Narrower term</option>
154                       [% PROCESS selectoptionopen value='i' %]i - Reference instruction phrase in subfield $i</option>
155                       [% PROCESS selectoptionopen value='n' %]n - Not applicable</option>
156                       [% PROCESS selectoptionopen value='r' %]r - Relationship designation in $i or $4</option>
157                       [% PROCESS selectoptionopen value='t' %]t - Immediate parent body</option>
158                     [% ELSIF Koha.Preference('marcflavour') == 'UNIMARC' %]
159                       [% PROCESS selectoptionopen value='a' %]a = earlier name</option>
160                       [% PROCESS selectoptionopen value='b' %]b = later name</option>
161                       [% PROCESS selectoptionopen value='c' %]c = official name</option>
162                       [% PROCESS selectoptionopen value='d' %]d = acronym / initial / abbreviation</option>
163                       [% PROCESS selectoptionopen value='e' %]e = pseudonym</option>
164                       [% PROCESS selectoptionopen value='f' %]f = real name</option>
165                       [% PROCESS selectoptionopen value='g' %]g = broader term or name</option>
166                       [% PROCESS selectoptionopen value='h' %]h = narrower term or name</option>
167                       [% PROCESS selectoptionopen value='i' %]i = name in religion</option>
168                       [% PROCESS selectoptionopen value='j' %]j = married name</option>
169                       [% PROCESS selectoptionopen value='k' %]k = name before marriage</option>
170                       [% PROCESS selectoptionopen value='l' %]l = shared pseudonym</option>
171                       [% PROCESS selectoptionopen value='m' %]m = secular name</option>
172                       [% PROCESS selectoptionopen value='n' %]n = different rule form of a name</option>
173                       [% PROCESS selectoptionopen value='o' %]o = attributed name / conventional title of a work</option>
174                       [% PROCESS selectoptionopen value='x' %]x = not applicable</option>
175                       [% PROCESS selectoptionopen value='z' %]z = other</option>
176                     [% END %]
177                 </select>
178             </li>
179             </ol>
180         </fieldset>
181         [% END %]
182         <fieldset class="action"> <input type="submit" value="Search" class="submit" id="search" /> <a id="cancel" class="cancel close" href="#">Cancel</a>
183         </fieldset>
184 </form>