2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha › Tools › Export data</title>
4 [% INCLUDE 'doc-head-close.inc' %]
5 [% INCLUDE 'calendar.inc' %]
6 <script type="text/javascript">
8 $(document).ready(function() {
9 $('#exporttype').tabs();
11 $("li.csv_profiles").hide();
13 $("#bibs select[name='output_format']").on('change', function(){
14 var format = $(this).val();
15 if ( format == 'csv' ) {
16 $("#bibs li.csv_profiles").show();
18 $("#bibs li.csv_profiles").hide();
21 $("#checkall").on("click",function(e){
23 $(".branch_select").prop("checked",1);
25 $("#checknone").on("click",function(e){
27 $(".branch_select").prop("checked",0);
32 <style type="text/css">
33 fieldset.rows fieldset.rows {
38 <body id="tools_export" class="tools">
39 [% INCLUDE 'header.inc' %]
40 [% INCLUDE 'cat-search.inc' %]
42 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> › Export data</div>
44 <div id="doc3" class="yui-t2">
50 [% FOR m IN messages %]
51 <div class="dialog [% m.type %]">
53 [% CASE 'invalid_mimetype' %]The file used does not have a valid format. Only csv and txt are allowed.
54 [% CASE %][% m.code %]
59 <div id="exporttype" class="toptabs">
61 <li><a href="#bibs">Export bibliographic records</a></li>
62 <li><a href="#auths">Export authority records</a></li>
63 [% IF ( allow_db_export ) %]
64 <li><a href="#db">Export database</a></li>
66 [% IF ( allow_conf_export ) %]
67 <li><a href="#conf">Export configuration</a></li>
72 <b>Note : The items are exported by this tool unless specified.</b>
75 <form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/export.pl">
76 <fieldset class="rows">
77 <legend> Select records to export </legend>
80 <label for="start">From biblio number: </label>
81 <input id="start" type="text" name="StartingBiblionumber" size="5" />
84 <label for="end">To biblio number: </label>
85 <input id="end" type="text" name="EndingBiblionumber" size="5" />
89 <label for="itemtype">Item type: </label>
90 <select name="itemtype" id="itemtype">
91 <option value="">-- All --</option>
92 [% FOREACH itemtype IN itemtypes %]
93 <option value="[% itemtype.itemtype %]">[% itemtype.translated_description %]</option>
99 <label>Library: </label>
100 [% INCLUDE 'branch-selector.inc' branches = libraries %]
104 <fieldset class="rows">
105 <legend>Call number range</legend>
108 <label for="startcn">From item call number: </label>
109 <input id="startcn" type="text" name="start_callnumber" size="15" />
112 <label for="endcn">To item call number: </label>
113 <input id="endcn" type="text" name="end_callnumber" size="15" />
118 <fieldset class="rows">
119 <legend>Accession date (inclusive)</legend>
122 <label for="from">Start date:</label>
123 <input type="text" size="10" id="from" name="start_accession" value="[% from %]" class="datepickerfrom" />
126 <label for="to">End date:</label>
127 <input size="10" id="to" name="end_accession" value="[% end_accession %]" type="text" class="datepickerto" />
133 <fieldset class="rows">
138 <li>File containing a list of biblio numbers with one biblio number per line. This list works as a filter: it is compatible with other parameters. (File types accepted: .csv and .txt)</li>
139 <li><label for="id_list_file">File: </label> <input type="file" id="id_list_file" name="id_list_file" /></li>
142 <fieldset class="rows">
143 <legend> Options</legend>
145 <label for="dont_export_item">Don't export items:</label>
146 <input id="dont_export_item" type="checkbox" name="dont_export_item" />
149 <label for="strip_nonlocal_items">Remove non-local items:</label>
150 <input id="strip_nonlocal_items" type="checkbox" name="strip_nonlocal_items" />
153 <label for="export_remove_fields">Don't export fields:</label>
154 <input id="export_remove_fields" type="text" name="export_remove_fields" value="[% export_remove_fields %]" />
155 separate by a blank. (e.g., 100a 200 606)
158 <fieldset class="rows">
163 <label for="output_format">File format: </label>
164 <select id="output_format" name="output_format">
165 <option value="iso2709">marc</option>
166 <option value="xml">xml</option>
167 <option value="csv">csv</option>
170 <li class="csv_profiles">
171 <label for="bibs_csv_profile">CSV profile: </label>
172 <select id="bibs_csv_profile" name="csv_profile_id">
173 [% FOR csv_profile IN csv_profiles %]
174 <option value="[% csv_profile.export_format_id %]">[% csv_profile.profile %]</option>
179 <label for="filename">File name:</label><input id="filename" type="text" name="filename" value="koha.mrc" />
182 <input type="hidden" name="op" value="export" />
183 <input type="hidden" name="record_type" value="bibs" />
185 <fieldset class="action"><input type="submit" value="Export bibliographic records" class="button" /></fieldset>
190 <form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/export.pl">
191 <fieldset class="rows">
192 <legend> Select records to export </legend>
194 <label for="start">From authid: </label>
195 <input id="start" type="text" name="starting_authid" size="6" />
198 <label for="end">To authid: </label>
199 <input id="end" type="text" name="ending_authid" size="6" />
202 <label for="authtype">Authority type: </label>
203 <select name="authtype" id="authtype">
204 <option value="">-- All --</option>
205 [% FOREACH authority_type IN authority_types %]
206 <option value="[% authtypeloo.value %]">[% authtypeloo.description %]</option>
212 <fieldset class="rows">
217 <li>File containing a list of authids with one authid per line. This list works as a filter: it is compatible with other parameters. (File types accepted: .csv and .txt)</li>
218 <li><label for="id_list_file">File:</label> <input type="file" id="id_list_file" name="id_list_file" /></li>
221 <fieldset class="rows">
222 <legend>Options</legend>
225 <label for="export_remove_fields">Don't export fields:</label>
226 <input id="export_remove_fields" type="text" name="export_remove_fields" />
227 separate by a blank. (e.g., 100a 200 606)
230 <fieldset class="rows">
231 <legend>Output format</legend>
233 <label for="output_format">File format: </label>
234 <select id="output_format" name="output_format">
235 <option value="marc">marc</option>
236 <option value="xml">xml</option>
240 <label for="filename">File name:</label><input id="filename" type="text" name="filename" value="koha.mrc" />
243 <input type="hidden" name="op" value="export" />
244 <input type="hidden" name="record_type" value="auths" />
246 <fieldset class="action"><input type="submit" value="Export authority records" class="button" /></fieldset>
250 [% IF ( allow_db_export ) %]
252 <form method="post" action="/cgi-bin/koha/tools/export.pl">
253 <p><b>Note : This export file will be very large, and is generated nightly.</b></p>
254 <fieldset class="rows">
255 <legend> Choose a file </legend>
256 [% IF ( dbfiles && (dbfiles.size > 0) ) %]
258 [% FOREACH dbfile IN dbfiles %]
259 <li><input type="radio" name="filename" value="[% dbfile %]">[% dbfile %]</input></li>
263 <p>Unfortunately, no backups are available.</p>
267 [% IF ( dbfiles && (dbfiles.size > 0) ) %]
268 <input type="hidden" name="op" value="export" />
269 <input type="hidden" name="record_type" value="db" />
270 <fieldset class="action"><input type="submit" value="Download database" class="button" /></fieldset>
276 [% IF ( allow_conf_export ) %]
278 <form method="post" action="/cgi-bin/koha/tools/export.pl">
279 <p><b>Note : This export file will be very large, and is generated nightly.</b></p>
280 <fieldset class="rows">
281 <legend> Choose a file </legend>
282 [% IF ( conffiles && (conffiles.size > 0) ) %]
284 [% FOREACH conffile IN conffiles %]
285 <li><input type="radio" name="filename" value="[% conffile %]">[% conffile %]</input></li>
289 <p>Unfortunately, no backups are available.</p>
293 [% IF ( conffiles && (conffiles.size > 0) ) %]
294 <input type="hidden" name="op" value="export" />
295 <input type="hidden" name="record_type" value="conf" />
296 <fieldset class="action"><input type="submit" value="Download configuration" class="button" /></fieldset>
306 <div class="yui-b noprint">
307 [% INCLUDE 'tools-menu.inc' %]
310 [% INCLUDE 'intranet-bottom.inc' %]