1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" --><title>Koha › Tools › CSV export profiles</title><!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
2 <script type="text/javascript">
4 function reloadPage(p) {
6 if (id != 0) { document.location = "/cgi-bin/koha/tools/csv-profiles.pl?id=" + id; }
8 $(document).ready(function() {
9 $('#csvexporttabs > ul').tabs();
16 <!-- TMPL_INCLUDE NAME="header.inc" -->
17 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
19 <div id="breadcrumbs">
20 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
21 › <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a>
22 › CSV export profiles
25 <div id="doc3" class="yui-t2">
29 <!-- TMPL_IF EXPR="success || error" -->
30 <!-- TMPL_IF NAME="success" -->
31 <!-- TMPL_IF EXPR="action eq 'create'" --><p>The new CSV profile "<!-- TMPL_VAR NAME="profile_name" -->" has been successfully created.</p><!-- /TMPL_IF -->
32 <!-- TMPL_IF EXPR="action eq 'edit'" --><p>The CSV profile has been successfully modified.</p><!-- /TMPL_IF -->
33 <!-- TMPL_IF EXPR="action eq 'delete'" --><p>The CSV profile has been successfully deleted.</p><!-- /TMPL_IF -->
35 <!-- TMPL_IF EXPR="action eq 'create'" --><p class="error">The new CSV profile "<!-- TMPL_VAR NAME="profile_name" -->" has not been created.</p><!-- /TMPL_IF -->
36 <!-- TMPL_IF EXPR="action eq 'edit'" --><p class="error">The CSV profile has not been modified.</p><!-- /TMPL_IF -->
37 <!-- TMPL_IF EXPR="action eq 'delete'" --><p class="error">The CSV profile has not been deleted.</p><!-- /TMPL_IF -->
40 <div id="csvexporttabs" class="toptabs">
42 <li><a href="csv-profiles.pl#csvnew">New profile</a></li>
43 <!-- TMPL_IF NAME="existing_profiles" -->
44 <!-- TMPL_IF NAME="selected_profile_id" -->
45 <li class="ui-tabs-selected">
49 <a href="csv-profiles.pl#csvedit">Edit existing profile</a></li> <!-- /TMPL_IF -->
52 <h3>New CSV export profile</h3>
54 <form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post">
55 <fieldset class="rows">
56 <ol><li><label for="profile_name" class="required">Profile name: </label>
57 <input type="text" id="profile_name" name="profile_name" /></li>
59 <li><label for="profile_description">Profile description: </label>
60 <textarea cols="50" rows="2" name="profile_description" id="profile_description"></textarea></li>
62 <li><label for="new_csv_separator">CSV separator: </label>
63 <select name="csv_separator" id="new_csv_separator">
64 <option value=":">Colon (:)</option>
65 <option value="," selected="selected">Comma (,)</option>
66 <option value="|">Pipe (|)</option>
67 <option value=";">Semi-colon (;)</option>
68 <option value="#">Sharp (#)</option>
69 <option value=" ">Space ( )</option>
70 <option value="\t">Tabulation (\t)</option>
73 <li><label for="new_field_separator">Field separator: </label>
74 <select name="field_separator" id="new_field_separator">
75 <option value=":">Colon (:)</option>
76 <option value=",">Comma (,)</option>
77 <option value="|">Pipe (|)</option>
78 <option value=";">Semi-colon (;)</option>
79 <option value="#" selected="selected">Sharp (#)</option>
80 <option value=" ">Space ( )</option>
81 <option value="\t">Tabulation (\t)</option>
84 <li><label for="new_subfield_separator">Subfield separator: </label>
85 <select name="subfield_separator" id="new_subfield_separator">
86 <option value=":">Colon (:)</option>
87 <option value=",">Comma (,)</option>
88 <option value="|" selected="selected">Pipe (|)</option>
89 <option value=";">Semi-colon (;)</option>
90 <option value="#">Sharp (#)</option>
91 <option value=" ">Space ( )</option>
92 <option value="\t">Tabulation (\t)</option>
95 <li><label for="new_encoding">Encoding: </label>
96 <select name="encoding" id="new_encoding">
97 <!-- TMPL_LOOP NAME="encodings" -->
98 <option<!-- TMPL_IF EXPR="encoding eq 'utf8'" --> selected="selected" <!-- /TMPL_IF -->><!-- TMPL_VAR NAME="encoding" --></option>
103 <li><label for="new_profile_content">Profile marcfields: </label>
104 <textarea cols="50" rows="2" name="profile_content" id="new_profile_content"></textarea>
105 <p>You have to define which fields or subfields you want to export, separated by pipes.</p>
106 <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>
107 <p>Example: Personal name=200|Entry element=210$a|300|009</p>
111 <fieldset class="action"><input type="hidden" name="action" value="create" />
112 <input type="submit" value="Submit" /></fieldset>
114 <br style="clear:both;" />
116 <!-- TMPL_IF NAME="existing_profiles" -->
118 <h3>Modify or delete a CSV export profile</h3>
120 <form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post">
121 <fieldset class="rows">
122 <ol><li><label for="modify_profile_name">Profile name: </label>
123 <select id="modify_profile_name" name="profile_name" onchange="javascript:reloadPage(this)">
124 <option value="0">-- Choose One --</option>
125 <!-- TMPL_LOOP NAME="existing_profiles" -->
126 <!-- TMPL_IF EXPR="export_format_id eq selected_profile_id" -->
127 <option value="<!-- TMPL_VAR NAME="export_format_id" -->" selected="selected"><!-- TMPL_VAR NAME="profile" --></option>
129 <option value="<!-- TMPL_VAR NAME="export_format_id" -->"><!-- TMPL_VAR NAME="profile" --></option>
134 <li><label for="modify_profile_description">Profile description: </label>
135 <textarea cols="50" rows="2" name="profile_description" id="modify_profile_description"><!-- TMPL_VAR NAME="selected_profile_description" --></textarea></li>
137 <li><label for="csv_separator">CSV separator: </label>
138 <select name="csv_separator" id="csv_separator">
139 <option value=":">Colon (:)</option>
140 <!-- TMPL_IF EXPR="selected_csv_separator eq ','" -->
141 <option value="," selected="selected">Comma (,)</option>
143 <option value=",">Comma (,)</option>
145 <!-- TMPL_IF EXPR="selected_csv_separator eq '|'" -->
146 <option value="|" selected="selected">Pipe (|)</option>
148 <option value="|">Pipe (|)</option>
150 <!-- TMPL_IF EXPR="selected_csv_separator eq ';'" -->
151 <option value=";" selected="selected">Semi-colon (;)</option>
153 <option value=";">Semi-colon (;)</option>
155 <!-- TMPL_IF EXPR="selected_csv_separator eq '#'" -->
156 <option value="#" selected="selected">Sharp (#)</option>
158 <option value="#">Sharp (#)</option>
160 <!-- TMPL_IF EXPR="selected_csv_separator eq ' '" -->
161 <option value=" " selected="selected">Space ( )</option>
163 <option value=" ">Space ( )</option>
165 <!-- TMPL_IF EXPR="selected_csv_separator eq '\t'" -->
166 <option value="\t" selected="selected">Tabulation (\t)</option>
168 <option value="\t">Tabulation (\t)</option>
172 <li><label for="field_separator">Field separator: </label>
173 <select name="field_separator" id="field_separator">
174 <option value=":">Colon (:)</option>
176 <!-- TMPL_IF EXPR="selected_field_separator eq ','" -->
177 <option value="," selected="selected">Comma (,)</option>
179 <option value=",">Comma (,)</option>
182 <!-- TMPL_IF EXPR="selected_field_separator eq '|'" -->
183 <option value="|" selected="selected">Pipe (|)</option>
185 <option value="|">Pipe (|)</option>
188 <!-- TMPL_IF EXPR="selected_field_separator eq ';'" -->
189 <option value=";" selected="selected">Semi-colon (;)</option>
191 <option value=";">Semi-colon (;)</option>
194 <!-- TMPL_IF EXPR="selected_field_separator eq '#'" -->
195 <option value="#" selected="selected">Sharp (#)</option>
197 <option value="#">Sharp (#)</option>
200 <!-- TMPL_IF EXPR="selected_field_separator eq ' '" -->
201 <option value=" " selected="selected">Space ( )</option>
203 <option value=" ">Space ( )</option>
206 <!-- TMPL_IF EXPR="selected_field_separator eq '\t'" -->
207 <option value="\t" selected="selected">Tabulation (\t)</option>
209 <option value="\t">Tabulation (\t)</option>
214 <li><label for="subfield_separator">Subfield separator: </label>
215 <select name="subfield_separator" id="subfield_separator">
216 <option value=":">Colon (:)</option>
219 <!-- TMPL_IF EXPR="selected_subfield_separator eq ','" -->
220 <option value="," selected="selected">Comma (,)</option>
222 <option value=",">Comma (,)</option>
225 <!-- TMPL_IF EXPR="selected_subfield_separator eq '|'" -->
226 <option value="|" selected="selected">Pipe (|)</option>
228 <option value="|">Pipe (|)</option>
231 <!-- TMPL_IF EXPR="selected_subfield_separator eq ';'" -->
232 <option value=";" selected="selected">Semi-colon (;)</option>
234 <option value=";">Semi-colon (;)</option>
237 <!-- TMPL_IF EXPR="selected_subfield_separator eq '#'" -->
238 <option value="#" selected="selected">Sharp (#)</option>
240 <option value="#">Sharp (#)</option>
243 <!-- TMPL_IF EXPR="selected_subfield_separator eq ' '" -->
244 <option value=" " selected="selected">Space ( )</option>
246 <option value=" ">Space ( )</option>
249 <!-- TMPL_IF EXPR="selected_subfield_separator eq '\t'" -->
250 <option value="\t" selected="selected">Tabulation (\t)</option>
252 <option value="\t">Tabulation (\t)</option>
257 <li><label for="encoding">Encoding: </label>
258 <select name="encoding" id="encoding">
259 <!-- TMPL_LOOP NAME="encodings" -->
260 <!-- TMPL_IF EXPR="selected_encoding eq encoding" -->
261 <option selected="selected"><!-- TMPL_VAR NAME="encoding" --></option>
263 <option><!-- TMPL_VAR NAME="encoding" --></option>
268 <li><label for="modify_profile_content">Profile marcfields: </label>
269 <textarea cols="50" rows="2" name="profile_content" id="modify_profile_content"><!-- TMPL_VAR NAME="selected_profile_marcfields" --></textarea></li>
271 <li class="radio"> <label for="delete">Delete selected profile ?</label>
272 <input type="checkbox" name="delete" id="delete" /></li>
277 <fieldset class="action"><input type="hidden" name="modify_profile_id" value="<!-- TMPL_VAR NAME="selected_profile_id" -->" />
278 <input type="hidden" name="action" value="edit" />
279 <input type="submit" value="Submit" /> <a href="/cgi-bin/koha/tools/csv-profiles.pl" class="cancel">Cancel</a></fieldset>
287 <div class="yui-b noprint">
288 <!-- TMPL_INCLUDE NAME="tools-menu.inc" -->
291 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->