Lines 7-12
function reloadPage(p) {
Link Here
|
7 |
} |
7 |
} |
8 |
$(document).ready(function() { |
8 |
$(document).ready(function() { |
9 |
$('#csvexporttabs').tabs(); |
9 |
$('#csvexporttabs').tabs(); |
|
|
10 |
|
11 |
$("#profile_type").find("option:first").attr("selected", "selected"); |
12 |
$("#csvnew").find("li.marc_specific").show(); |
13 |
$("#csvnew").find("li.sql_specific").hide(); |
14 |
|
15 |
$("#profile_type").change(function(){ |
16 |
if ( $(this).find("option:selected").val() == "marc" ) { |
17 |
$("#csvnew li.marc_specific").show(); |
18 |
$("#csvnew li.sql_specific").hide(); |
19 |
} else { |
20 |
$("#csvnew li.marc_specific").hide(); |
21 |
$("#csvnew li.sql_specific").show(); |
22 |
} |
23 |
}); |
24 |
$("#modify_profile_type").change(function(){ |
25 |
if ( $(this).find("option:selected").val() == "marc" ) { |
26 |
$("#csvedit li.marc_specific").show(); |
27 |
$("#csvedit li.sql_specific").hide(); |
28 |
} else { |
29 |
$("#csvedit li.marc_specific").hide(); |
30 |
$("#csvedit li.sql_specific").show(); |
31 |
} |
32 |
}); |
33 |
$("#modify_profile_type").change(); |
10 |
}); |
34 |
}); |
11 |
//]]> |
35 |
//]]> |
12 |
</script> |
36 |
</script> |
Lines 53-61
function reloadPage(p) {
Link Here
|
53 |
|
77 |
|
54 |
<form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post"> |
78 |
<form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post"> |
55 |
<fieldset class="rows"> |
79 |
<fieldset class="rows"> |
56 |
<ol><li><label for="profile_name" class="required">Profile name: </label> |
80 |
<ol> |
|
|
81 |
<li><label for="profile_name" class="required">Profile name: </label> |
57 |
<input type="text" id="profile_name" name="profile_name" /></li> |
82 |
<input type="text" id="profile_name" name="profile_name" /></li> |
58 |
|
83 |
|
|
|
84 |
<li> |
85 |
<label for="profile_type" class="required">Profile type: </label> |
86 |
<select id="profile_type" name="profile_type"> |
87 |
<option value="marc" selected="selected">MARC</option> |
88 |
<option value="sql">SQL</option> |
89 |
</select> |
90 |
</li> |
91 |
|
59 |
<li><label for="profile_description">Profile description: </label> |
92 |
<li><label for="profile_description">Profile description: </label> |
60 |
<textarea cols="50" rows="2" name="profile_description" id="profile_description"></textarea></li> |
93 |
<textarea cols="50" rows="2" name="profile_description" id="profile_description"></textarea></li> |
61 |
|
94 |
|
Lines 72-78
function reloadPage(p) {
Link Here
|
72 |
</select> |
105 |
</select> |
73 |
</li> |
106 |
</li> |
74 |
|
107 |
|
75 |
<li><label for="new_field_separator">Field separator: </label> |
108 |
<li class="marc_specific"><label for="new_field_separator">Field separator: </label> |
76 |
<select name="field_separator" id="new_field_separator"> |
109 |
<select name="field_separator" id="new_field_separator"> |
77 |
<option value=":">Colon (:)</option> |
110 |
<option value=":">Colon (:)</option> |
78 |
<option value=",">Comma (,)</option> |
111 |
<option value=",">Comma (,)</option> |
Lines 85-91
function reloadPage(p) {
Link Here
|
85 |
</select> |
118 |
</select> |
86 |
</li> |
119 |
</li> |
87 |
|
120 |
|
88 |
<li><label for="new_subfield_separator">Subfield separator: </label> |
121 |
<li class="marc_specific"><label for="new_subfield_separator">Subfield separator: </label> |
89 |
<select name="subfield_separator" id="new_subfield_separator"> |
122 |
<select name="subfield_separator" id="new_subfield_separator"> |
90 |
<option value=":">Colon (:)</option> |
123 |
<option value=":">Colon (:)</option> |
91 |
<option value=",">Comma (,)</option> |
124 |
<option value=",">Comma (,)</option> |
Lines 98-104
function reloadPage(p) {
Link Here
|
98 |
</select> |
131 |
</select> |
99 |
</li> |
132 |
</li> |
100 |
|
133 |
|
101 |
<li><label for="new_encoding">Encoding: </label> |
134 |
<li class="marc_specific"><label for="new_encoding">Encoding: </label> |
102 |
<select name="encoding" id="new_encoding"> |
135 |
<select name="encoding" id="new_encoding"> |
103 |
[% FOREACH encoding IN encodings %] |
136 |
[% FOREACH encoding IN encodings %] |
104 |
[% IF ( encoding.encoding == 'utf8' ) %] |
137 |
[% IF ( encoding.encoding == 'utf8' ) %] |
Lines 110-121
function reloadPage(p) {
Link Here
|
110 |
</select></li> |
143 |
</select></li> |
111 |
|
144 |
|
112 |
|
145 |
|
113 |
<li><label for="new_profile_content">Profile MARC fields: </label> |
146 |
<li class="marc_specific"><label for="new_profile_marc_content">Profile MARC fields: </label> |
114 |
<textarea cols="50" rows="2" name="profile_content" id="new_profile_content"></textarea> |
147 |
<textarea cols="50" rows="2" name="profile_marc_content" id="new_profile_marc_content"></textarea> |
115 |
<p>You have to define which fields or subfields you want to export, separated by pipes.</p> |
148 |
<p>You have to define which fields or subfields you want to export, separated by pipes.</p> |
116 |
<p>You can also use your own headers (instead of the ones from Koha) by prefixing the field number with an header, followed by the equal sign.</p> |
149 |
<p>You can also use your own headers (instead of the ones from Koha) by prefixing the field number with an header, followed by the equal sign.</p> |
117 |
<p>Example: Personal name=200|Entry element=210$a|300|009</p> |
150 |
<p>Example: Personal name=200|Entry element=210$a|300|009</p> |
118 |
</li> |
151 |
</li> |
|
|
152 |
<li class="sql_specific"> |
153 |
<label for="new_profile_sql_content">Profile SQL fields: </label> |
154 |
<textarea cols="50" rows="2" name="profile_sql_content" id="new_profile_sql_content"></textarea> |
155 |
<p>You have to define which fields you want to export, separated by pipes.</p> |
156 |
<p>You can also use your own headers (instead of the ones from Koha) by prefixing the field name with an header, followed by the equal sign.</p> |
157 |
<p>Example: Name=subscription.name|Title=subscription.title|Issue number=serial.serialseq</p> |
158 |
</li> |
119 |
</ol> |
159 |
</ol> |
120 |
</fieldset> |
160 |
</fieldset> |
121 |
<fieldset class="action"><input type="hidden" name="action" value="create" /> |
161 |
<fieldset class="action"><input type="hidden" name="action" value="create" /> |
Lines 129-135
function reloadPage(p) {
Link Here
|
129 |
|
169 |
|
130 |
<form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post"> |
170 |
<form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post"> |
131 |
<fieldset class="rows"> |
171 |
<fieldset class="rows"> |
132 |
<ol><li><label for="modify_profile_name">Profile name: </label> |
172 |
<ol> |
|
|
173 |
<li><label for="modify_profile_name">Profile name: </label> |
133 |
<select id="modify_profile_name" name="profile_name" onchange="javascript:reloadPage(this)"> |
174 |
<select id="modify_profile_name" name="profile_name" onchange="javascript:reloadPage(this)"> |
134 |
<option value="0">-- Choose One --</option> |
175 |
<option value="0">-- Choose One --</option> |
135 |
[% FOREACH existing_profile IN existing_profiles %] |
176 |
[% FOREACH existing_profile IN existing_profiles %] |
Lines 141-146
function reloadPage(p) {
Link Here
|
141 |
[% END %] |
182 |
[% END %] |
142 |
</select></li> |
183 |
</select></li> |
143 |
|
184 |
|
|
|
185 |
<li> |
186 |
<label for="modify_profile_type">Profile type: </label> |
187 |
<select id="modify_profile_type" name="profile_type"> |
188 |
<option value="marc">MARC</option> |
189 |
[% IF selected_profile_type == "sql" %] |
190 |
<option value="sql" selected="selected">SQL</option> |
191 |
[% ELSE %] |
192 |
<option value="sql">SQL</option> |
193 |
[% END %] |
194 |
</select> |
195 |
</li> |
196 |
|
197 |
|
144 |
<li><label for="modify_profile_description">Profile description: </label> |
198 |
<li><label for="modify_profile_description">Profile description: </label> |
145 |
<textarea cols="50" rows="2" name="profile_description" id="modify_profile_description">[% selected_profile_description %]</textarea></li> |
199 |
<textarea cols="50" rows="2" name="profile_description" id="modify_profile_description">[% selected_profile_description %]</textarea></li> |
146 |
|
200 |
|
Lines 184-190
function reloadPage(p) {
Link Here
|
184 |
[% END %] |
238 |
[% END %] |
185 |
</select></li> |
239 |
</select></li> |
186 |
|
240 |
|
187 |
<li><label for="field_separator">Field separator: </label> |
241 |
<li class="marc_specific"><label for="field_separator">Field separator: </label> |
188 |
<select name="field_separator" id="field_separator"> |
242 |
<select name="field_separator" id="field_separator"> |
189 |
<option value=":">Colon (:)</option> |
243 |
<option value=":">Colon (:)</option> |
190 |
|
244 |
|
Lines 231-237
function reloadPage(p) {
Link Here
|
231 |
</select></li> |
285 |
</select></li> |
232 |
|
286 |
|
233 |
|
287 |
|
234 |
<li><label for="subfield_separator">Subfield separator: </label> |
288 |
<li class="marc_specific"><label for="subfield_separator">Subfield separator: </label> |
235 |
<select name="subfield_separator" id="subfield_separator"> |
289 |
<select name="subfield_separator" id="subfield_separator"> |
236 |
<option value=":">Colon (:)</option> |
290 |
<option value=":">Colon (:)</option> |
237 |
|
291 |
|
Lines 278-284
function reloadPage(p) {
Link Here
|
278 |
|
332 |
|
279 |
</select></li> |
333 |
</select></li> |
280 |
|
334 |
|
281 |
<li><label for="encoding">Encoding: </label> |
335 |
<li class="marc_specific"><label for="encoding">Encoding: </label> |
282 |
<select name="encoding" id="encoding"> |
336 |
<select name="encoding" id="encoding"> |
283 |
[% FOREACH encoding IN encodings %] |
337 |
[% FOREACH encoding IN encodings %] |
284 |
[% IF ( selected_encoding == encoding.encoding ) %] |
338 |
[% IF ( selected_encoding == encoding.encoding ) %] |
Lines 289-296
function reloadPage(p) {
Link Here
|
289 |
[% END %] |
343 |
[% END %] |
290 |
</select></li> |
344 |
</select></li> |
291 |
|
345 |
|
292 |
<li><label for="modify_profile_content">Profile MARC fields: </label> |
346 |
<li class="marc_specific"><label for="modify_profile_marc_content">Profile MARC fields: </label> |
293 |
<textarea cols="50" rows="2" name="profile_content" id="modify_profile_content">[% selected_profile_marcfields %]</textarea></li> |
347 |
<textarea cols="50" rows="2" name="profile_marc_content" id="modify_profile_marc_content">[% selected_profile_content %]</textarea></li> |
|
|
348 |
|
349 |
<li class="sql_specific"> |
350 |
<label for="modify_profile_sql_content">Profile SQL fields: </label> |
351 |
<textarea cols="50" rows="2" name="profile_sql_content" id="modify_profile_sql_content">[% selected_profile_content %]</textarea> |
352 |
</li> |
294 |
|
353 |
|
295 |
<li class="radio"> <label for="delete">Delete selected profile ?</label> |
354 |
<li class="radio"> <label for="delete">Delete selected profile ?</label> |
296 |
<input type="checkbox" name="delete" id="delete" /></li> |
355 |
<input type="checkbox" name="delete" id="delete" /></li> |