View | Details | Raw Unified | Return to bug 30475
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/export.tt (-232 / +240 lines)
Lines 47-298 Link Here
47
[% END %]
47
[% END %]
48
48
49
<div id="exporttype" class="toptabs">
49
<div id="exporttype" class="toptabs">
50
<ul>
50
    <ul class="nav nav-tabs" role="tablist">
51
<li><a href="#bibs">Export bibliographic records</a></li>
51
        <li role="presentation" class="active">
52
<li><a href="#auths">Export authority records</a></li>
52
            <a href="#bibs" aria-controls="bibs" role="tab" data-toggle="tab">Export bibliographic records</a>
53
[% IF ( allow_db_export ) %]
54
<li><a href="#db">Export database</a></li>
55
[% END %]
56
[% IF ( allow_conf_export ) %]
57
<li><a href="#conf">Export configuration</a></li>
58
[% END %]
59
</ul>
60
<div id="bibs">
61
<p>
62
    <strong>Note : The items are exported by this tool unless specified.</strong>
63
</p>
64
65
<form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/export.pl">
66
    <fieldset class="rows">
67
    <legend> Select records to export </legend>
68
        <ol>
69
        <li>
70
            <label for="start">From biblionumber: </label>
71
            <input id="start" type="text" name="StartingBiblionumber" size="5" />
72
        </li>
73
        <li>
74
            <label for="end">To biblionumber: </label>
75
            <input id="end" type="text" name="EndingBiblionumber" size="5" />
76
        </li>
53
        </li>
77
        
54
        <li role="presentation">
78
        <li>
55
            <a href="#auths" aria-controls="auths" role="tab" data-toggle="tab">Export authority records</a>
79
            <label for="itemtype">Item type: </label>
80
            <select name="itemtype" id="itemtype">
81
                <option value="">-- All --</option>
82
                [% FOREACH itemtype IN itemtypes %]
83
                    <option value="[% itemtype.itemtype | html %]">[% itemtype.translated_description | html %]</option>
84
                [% END %]
85
            </select>
86
        </li>
87
        
88
        <li>
89
            <label>With items owned by the following libraries: </label>
90
            [% INCLUDE 'branch-selector.inc' branches = libraries %]
91
        </li>
56
        </li>
92
    </ol>
57
        [% IF ( allow_db_export ) %]
93
58
            <li role="presentation">
94
    <fieldset class="rows">
59
                <a href="#db" aria-controls="db" role="tab" data-toggle="tab">Export database</a>
95
        <legend>Call number range</legend>
96
        <ol>
97
            <li>
98
                <label for="startcn">From item call number: </label>
99
                <input id="startcn" type="text" name="start_callnumber" size="15" />
100
            </li>
60
            </li>
101
            <li>
61
        [% END %]
102
                <label for="endcn">To item call number: </label>
62
        [% IF ( allow_conf_export ) %]
103
                <input id="endcn" type="text" name="end_callnumber" size="15" />
63
            <li role="presentation">
64
                <a href="#conf" aria-controls="conf" role="tab" data-toggle="tab">Export configuration</a>
104
            </li>
65
            </li>
105
        </ol>
66
        [% END %]
106
    </fieldset>
67
    </ul>
68
    <div class="tab-content">
69
        <div id="bibs" role="tabpanel" class="tab-pane active">
70
        <p>
71
            <strong>Note : The items are exported by this tool unless specified.</strong>
72
        </p>
107
73
108
    <fieldset class="rows">
74
        <form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/export.pl">
109
        <legend>Accession date (inclusive)</legend>
75
            <fieldset class="rows">
110
        <ol>
76
            <legend> Select records to export </legend>
111
            <li>
77
                <ol>
112
                    <label for="from">Start date:</label>
78
                <li>
113
                    <input type="text" size="10" id="from" name="start_accession" value="[% from | html %]" class="flatpickr" data-date_to="to" />
79
                    <label for="start">From biblionumber: </label>
114
            </li>
80
                    <input id="start" type="text" name="StartingBiblionumber" size="5" />
115
            <li>
81
                </li>
116
                <label for="to">End date:</label>
82
                <li>
117
                <input size="10" id="to" name="end_accession" value="[% end_accession | html %]" type="text" class="flatpickr" />
83
                    <label for="end">To biblionumber: </label>
118
            </li>
84
                    <input id="end" type="text" name="EndingBiblionumber" size="5" />
119
        </ol>
85
                </li>
120
    </fieldset>
121
86
122
    </fieldset>
87
                <li>
123
    <fieldset class="rows">
88
                    <label for="itemtype">Item type: </label>
124
    <legend>
89
                    <select name="itemtype" id="itemtype">
125
        Use a file
90
                        <option value="">-- All --</option>
126
    </legend>
91
                        [% FOREACH itemtype IN itemtypes %]
127
        <ol>
92
                            <option value="[% itemtype.itemtype | html %]">[% itemtype.translated_description | html %]</option>
128
        <li>File containing a list of biblionumbers with one biblionumber per line. This list works as a filter: it is compatible with other parameters. (File types accepted: .csv and .txt)</li>
93
                        [% END %]
129
        <li><label for="id_list_file">File: </label> <input type="file" id="id_list_file" name="id_list_file" /></li>
94
                    </select>
130
        </ol>
95
                </li>
131
    </fieldset>
132
    <fieldset class="rows">
133
    <legend> Options</legend>
134
<ol>        <li>
135
        <label for="dont_export_item">Don't export items:</label>
136
        <input id="dont_export_item" type="checkbox" name="dont_export_item" />
137
        </li>
138
        <li>
139
        <label for="strip_items_not_from_libraries">Remove items not owned by selected libraries:</label>
140
        <input id="strip_items_not_from_libraries" type="checkbox" name="strip_items_not_from_libraries" />
141
        </li>
142
        <li>
143
        <label for="export_remove_fields">Don't export fields:</label>
144
        <input id="export_remove_fields" type="text" name="export_remove_fields" value="[% export_remove_fields | html %]" />
145
        separate by a blank. (e.g., 100a 200 606)
146
        </li></ol>
147
    </fieldset>
148
    <fieldset class="rows">
149
    <legend>
150
        Output format
151
    </legend>
152
        <ol><li>
153
            <label for="output_format">File format: </label>
154
            <select id="output_format" name="output_format">
155
                <option value="iso2709">MARC</option>
156
                <option value="xml">XML</option>
157
                [% IF csv_profiles %]
158
                    <option value="csv">CSV</option>
159
                [% ELSE %]
160
                    <option value="csv" disabled data-toggle="tooltip" data-placement="left" title="You must create a CSV profile for MARC exports to use this option.">CSV</option>
161
                [% END %]
162
            </select>
163
        </li>
164
        <li class="csv_profiles">
165
            <label for="bibs_csv_profile">CSV profile: </label>
166
            <select id="bibs_csv_profile" name="csv_profile_id">
167
                [% FOR csv_profile IN csv_profiles %]
168
                    <option value="[% csv_profile.export_format_id | html %]">[% csv_profile.profile | html %]</option>
169
                [% END %]
170
            </select>
171
        </li>
172
        <li>
173
        <label for="filename">File name:</label><input id="filename" type="text" name="filename" value="koha.mrc" />
174
        </li></ol>
175
    </fieldset>
176
    <input type="hidden" name="op" value="export" />
177
    <input type="hidden" name="record_type" value="bibs" />
178
96
179
    <fieldset class="action"><input type="submit" value="Export bibliographic records" class="button" /></fieldset>
97
                <li>
180
</form>
98
                    <label>With items owned by the following libraries: </label>
181
</div>
99
                    [% INCLUDE 'branch-selector.inc' branches = libraries %]
100
                </li>
101
            </ol>
182
102
183
<div id="auths">
103
            <fieldset class="rows">
184
<form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/export.pl">
104
                <legend>Call number range</legend>
185
    <fieldset class="rows">
105
                <ol>
186
    <legend> Select records to export </legend>
106
                    <li>
187
        <ol><li>
107
                        <label for="startcn">From item call number: </label>
188
            <label for="start">From authid: </label>
108
                        <input id="startcn" type="text" name="start_callnumber" size="15" />
189
            <input id="start" type="text" name="starting_authid" size="6" />
109
                    </li>
190
        </li>
110
                    <li>
191
        <li>
111
                        <label for="endcn">To item call number: </label>
192
            <label for="end">To authid: </label>
112
                        <input id="endcn" type="text" name="end_callnumber" size="15" />
193
            <input id="end" type="text" name="ending_authid" size="6" />
113
                    </li>
194
        </li>
114
                </ol>
195
        <li>
115
            </fieldset>
196
            <label for="authtype">Authority type: </label>
197
            <select name="authtype" id="authtype">
198
                <option value="">-- All --</option>
199
                [% FOREACH authority_type IN authority_types %]
200
                    <option value="[% authority_type.authtypecode | html %]">[% authority_type.authtypetext | html %]</option>
201
                [% END %]
202
            </select>
203
        </li>
204
        </ol>
205
    </fieldset>
206
    <fieldset class="rows">
207
    <legend>
208
        Use a file
209
    </legend>
210
        <ol>
211
        <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>
212
        <li><label for="id_list_file">File:</label> <input type="file" id="id_list_file" name="id_list_file" /></li>
213
        </ol>
214
    </fieldset>
215
    <fieldset class="rows">
216
    <legend>Options</legend>
217
        <ol>
218
        <li>
219
            <label for="export_remove_fields">Don't export fields:</label>
220
            <input id="export_remove_fields" type="text" name="export_remove_fields" />
221
            separate by a blank. (e.g., 100a 200 606)
222
        </li></ol>
223
    </fieldset>
224
    <fieldset class="rows">
225
    <legend>Output format</legend>
226
        <ol><li>
227
            <label for="output_format">File format: </label>
228
            <select id="output_format_auth" name="output_format">
229
                <option value="marc">MARC</option>
230
                <option value="xml">XML</option>
231
            </select>
232
        </li>
233
        <li>
234
        <label for="filename_auth">File name:</label><input id="filename_auth" type="text" name="filename_auth" value="koha.mrc" />
235
        </li></ol>
236
    </fieldset>
237
    <input type="hidden" name="op" value="export" />
238
    <input type="hidden" name="record_type" value="auths" />
239
116
240
    <fieldset class="action"><input type="submit" value="Export authority records" class="button" /></fieldset>
117
            <fieldset class="rows">
241
</form>
118
                <legend>Accession date (inclusive)</legend>
242
</div>
119
                <ol>
120
                    <li>
121
                            <label for="from">Start date:</label>
122
                            <input type="text" size="10" id="from" name="start_accession" value="[% from | html %]" class="flatpickr" data-date_to="to" />
123
                    </li>
124
                    <li>
125
                        <label for="to">End date:</label>
126
                        <input size="10" id="to" name="end_accession" value="[% end_accession | html %]" type="text" class="flatpickr" />
127
                    </li>
128
                </ol>
129
            </fieldset>
243
130
244
[% IF ( allow_db_export ) %]
131
            </fieldset>
245
<div id="db">
132
            <fieldset class="rows">
246
<form method="post" action="/cgi-bin/koha/tools/export.pl">
133
            <legend>
247
    <p><strong>Note : This export file will be very large, and is generated nightly.</strong></p>
134
                Use a file
248
    <fieldset class="rows">
135
            </legend>
249
    <legend> Choose a file </legend>
136
                <ol>
250
    [% IF ( dbfiles && (dbfiles.size > 0) ) %]
137
                <li>File containing a list of biblionumbers with one biblionumber per line. This list works as a filter: it is compatible with other parameters. (File types accepted: .csv and .txt)</li>
251
        <ul>
138
                <li><label for="id_list_file">File: </label> <input type="file" id="id_list_file" name="id_list_file" /></li>
252
        [% FOREACH dbfile IN dbfiles %]
139
                </ol>
253
            <li><input type="radio" name="filename" value="[% dbfile | html %]">[% dbfile | html %]</input></li>
140
            </fieldset>
254
        [% END %]
141
            <fieldset class="rows">
255
        </ul>
142
            <legend> Options</legend>
256
    [% ELSE %]
143
        <ol>        <li>
257
        <p>Unfortunately, no backups are available.</p>
144
                <label for="dont_export_item">Don't export items:</label>
258
    [% END %]
145
                <input id="dont_export_item" type="checkbox" name="dont_export_item" />
259
    </fieldset>
146
                </li>
147
                <li>
148
                <label for="strip_items_not_from_libraries">Remove items not owned by selected libraries:</label>
149
                <input id="strip_items_not_from_libraries" type="checkbox" name="strip_items_not_from_libraries" />
150
                </li>
151
                <li>
152
                <label for="export_remove_fields">Don't export fields:</label>
153
                <input id="export_remove_fields" type="text" name="export_remove_fields" value="[% export_remove_fields | html %]" />
154
                separate by a blank. (e.g., 100a 200 606)
155
                </li></ol>
156
            </fieldset>
157
            <fieldset class="rows">
158
            <legend>
159
                Output format
160
            </legend>
161
                <ol><li>
162
                    <label for="output_format">File format: </label>
163
                    <select id="output_format" name="output_format">
164
                        <option value="iso2709">MARC</option>
165
                        <option value="xml">XML</option>
166
                        [% IF csv_profiles %]
167
                            <option value="csv">CSV</option>
168
                        [% ELSE %]
169
                            <option value="csv" disabled data-toggle="tooltip" data-placement="left" title="You must create a CSV profile for MARC exports to use this option.">CSV</option>
170
                        [% END %]
171
                    </select>
172
                </li>
173
                <li class="csv_profiles">
174
                    <label for="bibs_csv_profile">CSV profile: </label>
175
                    <select id="bibs_csv_profile" name="csv_profile_id">
176
                        [% FOR csv_profile IN csv_profiles %]
177
                            <option value="[% csv_profile.export_format_id | html %]">[% csv_profile.profile | html %]</option>
178
                        [% END %]
179
                    </select>
180
                </li>
181
                <li>
182
                <label for="filename">File name:</label><input id="filename" type="text" name="filename" value="koha.mrc" />
183
                </li></ol>
184
            </fieldset>
185
            <input type="hidden" name="op" value="export" />
186
            <input type="hidden" name="record_type" value="bibs" />
260
187
261
    [% IF ( dbfiles && (dbfiles.size > 0) ) %]
188
            <fieldset class="action"><input type="submit" value="Export bibliographic records" class="button" /></fieldset>
262
        <input type="hidden" name="op" value="export" />
189
        </form>
263
        <input type="hidden" name="record_type" value="db" />
190
        </div>
264
        <fieldset class="action"><input type="submit" value="Download database" class="button" /></fieldset>
265
    [% END %]
266
</form>
267
</div>
268
[% END %]
269
191
270
[% IF ( allow_conf_export ) %]
192
        <div id="auths" role="tabpanel" class="tab-pane">
271
<div id="conf">
193
        <form method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/export.pl">
272
<form method="post" action="/cgi-bin/koha/tools/export.pl">
194
            <fieldset class="rows">
273
    <p><strong>Note : This export file will be very large, and is generated nightly.</strong></p>
195
            <legend> Select records to export </legend>
274
    <fieldset class="rows">
196
                <ol><li>
275
    <legend> Choose a file </legend>
197
                    <label for="start">From authid: </label>
276
    [% IF ( conffiles && (conffiles.size > 0) ) %]
198
                    <input id="start" type="text" name="starting_authid" size="6" />
277
        <ul>
199
                </li>
278
        [% FOREACH conffile IN conffiles %]
200
                <li>
279
            <li><input type="radio" name="filename" value="[% conffile | html %]">[% conffile | html %]</input></li>
201
                    <label for="end">To authid: </label>
202
                    <input id="end" type="text" name="ending_authid" size="6" />
203
                </li>
204
                <li>
205
                    <label for="authtype">Authority type: </label>
206
                    <select name="authtype" id="authtype">
207
                        <option value="">-- All --</option>
208
                        [% FOREACH authority_type IN authority_types %]
209
                            <option value="[% authority_type.authtypecode | html %]">[% authority_type.authtypetext | html %]</option>
210
                        [% END %]
211
                    </select>
212
                </li>
213
                </ol>
214
            </fieldset>
215
            <fieldset class="rows">
216
            <legend>
217
                Use a file
218
            </legend>
219
                <ol>
220
                <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>
221
                <li><label for="id_list_file">File:</label> <input type="file" id="id_list_file" name="id_list_file" /></li>
222
                </ol>
223
            </fieldset>
224
            <fieldset class="rows">
225
            <legend>Options</legend>
226
                <ol>
227
                <li>
228
                    <label for="export_remove_fields">Don't export fields:</label>
229
                    <input id="export_remove_fields" type="text" name="export_remove_fields" />
230
                    separate by a blank. (e.g., 100a 200 606)
231
                </li></ol>
232
            </fieldset>
233
            <fieldset class="rows">
234
            <legend>Output format</legend>
235
                <ol><li>
236
                    <label for="output_format">File format: </label>
237
                    <select id="output_format_auth" name="output_format">
238
                        <option value="marc">MARC</option>
239
                        <option value="xml">XML</option>
240
                    </select>
241
                </li>
242
                <li>
243
                <label for="filename_auth">File name:</label><input id="filename_auth" type="text" name="filename_auth" value="koha.mrc" />
244
                </li></ol>
245
            </fieldset>
246
            <input type="hidden" name="op" value="export" />
247
            <input type="hidden" name="record_type" value="auths" />
248
249
            <fieldset class="action"><input type="submit" value="Export authority records" class="button" /></fieldset>
250
        </form>
251
        </div>
252
253
        [% IF ( allow_db_export ) %]
254
        <div id="db" role="tabpanel" class="tab-pane">
255
        <form method="post" action="/cgi-bin/koha/tools/export.pl">
256
            <p><strong>Note : This export file will be very large, and is generated nightly.</strong></p>
257
            <fieldset class="rows">
258
            <legend> Choose a file </legend>
259
            [% IF ( dbfiles && (dbfiles.size > 0) ) %]
260
                <ul>
261
                [% FOREACH dbfile IN dbfiles %]
262
                    <li><input type="radio" name="filename" value="[% dbfile | html %]">[% dbfile | html %]</input></li>
263
                [% END %]
264
                </ul>
265
            [% ELSE %]
266
                <p>Unfortunately, no backups are available.</p>
267
            [% END %]
268
            </fieldset>
269
270
            [% IF ( dbfiles && (dbfiles.size > 0) ) %]
271
                <input type="hidden" name="op" value="export" />
272
                <input type="hidden" name="record_type" value="db" />
273
                <fieldset class="action"><input type="submit" value="Download database" class="button" /></fieldset>
274
            [% END %]
275
        </form>
276
        </div>
280
        [% END %]
277
        [% END %]
281
        </ul>
282
    [% ELSE %]
283
        <p>Unfortunately, no backups are available.</p>
284
    [% END %]
285
    </fieldset>
286
278
287
    [% IF ( conffiles && (conffiles.size > 0) ) %]
279
        [% IF ( allow_conf_export ) %]
288
        <input type="hidden" name="op" value="export" />
280
        <div id="conf" role="tabpanel" class="tab-pane">
289
        <input type="hidden" name="record_type" value="conf" />
281
        <form method="post" action="/cgi-bin/koha/tools/export.pl">
290
        <fieldset class="action"><input type="submit" value="Download configuration" class="button" /></fieldset>
282
            <p><strong>Note : This export file will be very large, and is generated nightly.</strong></p>
291
    [% END %]
283
            <fieldset class="rows">
292
</form>
284
            <legend> Choose a file </legend>
293
</div>
285
            [% IF ( conffiles && (conffiles.size > 0) ) %]
294
[% END %]
286
                <ul>
287
                [% FOREACH conffile IN conffiles %]
288
                    <li><input type="radio" name="filename" value="[% conffile | html %]">[% conffile | html %]</input></li>
289
                [% END %]
290
                </ul>
291
            [% ELSE %]
292
                <p>Unfortunately, no backups are available.</p>
293
            [% END %]
294
            </fieldset>
295
295
296
            [% IF ( conffiles && (conffiles.size > 0) ) %]
297
                <input type="hidden" name="op" value="export" />
298
                <input type="hidden" name="record_type" value="conf" />
299
                <fieldset class="action"><input type="submit" value="Download configuration" class="button" /></fieldset>
300
            [% END %]
301
        </form>
302
        </div>
303
        [% END %]
304
    </div> <!-- /.tab-content -->
296
</div>
305
</div>
297
306
298
            </main>
307
            </main>
Lines 310-316 Link Here
310
    [% INCLUDE 'calendar.inc' %]
319
    [% INCLUDE 'calendar.inc' %]
311
    <script>
320
    <script>
312
        $(document).ready(function() {
321
        $(document).ready(function() {
313
            $('#exporttype').tabs();
314
322
315
            $("li.csv_profiles").hide();
323
            $("li.csv_profiles").hide();
316
324
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt (-72 / +78 lines)
Lines 39-127 Link Here
39
                <form id="patron_batchmod_form" method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/modborrowers.pl">
39
                <form id="patron_batchmod_form" method="post" enctype="multipart/form-data" action="/cgi-bin/koha/tools/modborrowers.pl">
40
                    <input type="hidden" name="op" value="show" />
40
                    <input type="hidden" name="op" value="show" />
41
                    <div id="batch_patron_options" class="toptabs">
41
                    <div id="batch_patron_options" class="toptabs">
42
                        <ul>
42
                        <ul class="nav nav-tabs" role="tablist">
43
                            <li>
43
                            <li role="presentation" class="active">
44
                                <a href="#usecardnumber">By card number</a>
44
                                <a href="#usecardnumber" aria-controls="usecardnumber" role="tab" data-toggle="tab">By card number</a>
45
                            </li>
45
                            </li>
46
                            <li>
46
                            <li role="presentation">
47
                                <a href="#useborrowernumber">By borrowernumber</a>
47
                                <a href="#useborrowernumber" aria-controls="useborrowernumber" role="tab" data-toggle="tab">By borrowernumber</a>
48
                            </li>
48
                            </li>
49
                            [% IF patron_lists %]
49
                            [% IF patron_lists %]
50
                                <li>
50
                                <li role="presentation">
51
                                    <a href="#uselist">By patron list</a>
51
                                    <a href="#uselist" aria-controls="uselist" role="tab" data-toggle="tab">By patron list</a>
52
                                </li>
52
                                </li>
53
                            [% END %]
53
                            [% END %]
54
                        </ul>
54
                        </ul>
55
                        <div id="usecardnumber">
55
                        <div class="tab-content">
56
                            <fieldset class="rows">
56
                            <div id="usecardnumber" role="tabpanel" class="tab-pane active">
57
                                <legend>Use a file of card numbers</legend>
58
                                <ol>
59
                                    <li>
60
                                        <label for="cardnumberuploadfile">File: </label> <input type="file" id="cardnumberuploadfile" name="cardnumberuploadfile" />
61
                                        <div class="hint">File must contain one card number per line.</div>
62
                                    </li>
63
                                </ol>
64
                            </fieldset>
65
                            <fieldset class="rows">
66
                                <legend>Or list card numbers one by one</legend>
67
                                <ol>
68
                                    <li>
69
                                    <label for="cardnumberlist">Card number list (one card number per line): </label>
70
                                    <textarea rows="10" cols="30" id="cardnumberlist" name="cardnumberlist">[% cardnumberlist | html %]</textarea>
71
                                    </li>
72
                                </ol>
73
                            </fieldset>
74
                    <fieldset class="action">
75
                        <input type="submit" value="Continue" class="button" />
76
                        <a class="cancel" href="/cgi-bin/koha/tools/tools-home.pl">Cancel</a>
77
                    </fieldset>
78
                        </div>
79
                        <div id="useborrowernumber">
80
                            <fieldset class="rows">
81
                                <legend>Use a file of borrowernumbers</legend>
82
                                <ol>
83
                                    <li>
84
                                        <label for="borrowernumberuploadfile">File: </label> <input type="file" id="borrowernumberuploadfile" name="borrowernumberuploadfile" />
85
                                        <div class="hint">File must contain one borrowernumber per line.</div>
86
                                    </li>
87
                                </ol>
88
                            </fieldset>
89
                            <fieldset class="rows">
90
                                <legend>List borrowernumbers one by one</legend>
91
                                <ol>
92
                                    <li>
93
                                    <label for="borrowernumberlist">Borrowernumber list (one number per line): </label>
94
                                    <textarea rows="10" cols="30" id="borrowernumberlist" name="borrowernumberlist">[% borrowernumberlist | html %]</textarea>
95
                                    </li>
96
                                </ol>
97
                            </fieldset>
98
                    <fieldset class="action">
99
                        <input type="submit" value="Continue" class="button" />
100
                        <a class="cancel" href="/cgi-bin/koha/tools/tools-home.pl">Cancel</a>
101
                    </fieldset>
102
                        </div>
103
                        [% IF patron_lists %]
104
                            <div id="uselist">
105
                                <fieldset class="rows">
57
                                <fieldset class="rows">
106
                                    <legend>Use a patron list</legend>
58
                                    <legend>Use a file of card numbers</legend>
107
                                    <ol>
59
                                    <ol>
108
                                        <li>
60
                                        <li>
109
                                            <label for="patron_list_id">Patron list: </label>
61
                                            <label for="cardnumberuploadfile">File: </label> <input type="file"
110
                                            <select id="patron_list_id" name="patron_list_id">
62
                                                id="cardnumberuploadfile" name="cardnumberuploadfile" />
111
                                                <option value=""> -- Choose a patron list -- </option>
63
                                            <div class="hint">File must contain one card number per line.</div>
112
                                                [% FOREACH pl IN patron_lists %]
113
                                                    <option value="[% pl.patron_list_id | html %]">[% pl.name | html %]</option>
114
                                                [% END %]
115
                                            </select>
116
                                        </li>
64
                                        </li>
117
                                    </ol>
65
                                    </ol>
118
                                </fieldset>
66
                                </fieldset>
119
                    <fieldset class="action">
67
                                <fieldset class="rows">
120
                        <input type="submit" value="Continue" class="button" />
68
                                    <legend>Or list card numbers one by one</legend>
121
                        <a class="cancel" href="/cgi-bin/koha/tools/tools-home.pl">Cancel</a>
69
                                    <ol>
122
                    </fieldset>
70
                                        <li>
71
                                            <label for="cardnumberlist">Card number list (one card number per line):
72
                                            </label>
73
                                            <textarea rows="10" cols="30" id="cardnumberlist"
74
                                                name="cardnumberlist">[% cardnumberlist | html %]</textarea>
75
                                        </li>
76
                                    </ol>
77
                                </fieldset>
78
                                <fieldset class="action">
79
                                    <input type="submit" value="Continue" class="button" />
80
                                    <a class="cancel" href="/cgi-bin/koha/tools/tools-home.pl">Cancel</a>
81
                                </fieldset>
123
                            </div>
82
                            </div>
124
                        [% END %]
83
                            <div id="useborrowernumber" role="tabpanel" class="tab-pane">
84
                                <fieldset class="rows">
85
                                    <legend>Use a file of borrowernumbers</legend>
86
                                    <ol>
87
                                        <li>
88
                                            <label for="borrowernumberuploadfile">File: </label> <input type="file"
89
                                                id="borrowernumberuploadfile" name="borrowernumberuploadfile" />
90
                                            <div class="hint">File must contain one borrowernumber per line.</div>
91
                                        </li>
92
                                    </ol>
93
                                </fieldset>
94
                                <fieldset class="rows">
95
                                    <legend>List borrowernumbers one by one</legend>
96
                                    <ol>
97
                                        <li>
98
                                            <label for="borrowernumberlist">Borrowernumber list (one number per line):
99
                                            </label>
100
                                            <textarea rows="10" cols="30" id="borrowernumberlist"
101
                                                name="borrowernumberlist">[% borrowernumberlist | html %]</textarea>
102
                                        </li>
103
                                    </ol>
104
                                </fieldset>
105
                                <fieldset class="action">
106
                                    <input type="submit" value="Continue" class="button" />
107
                                    <a class="cancel" href="/cgi-bin/koha/tools/tools-home.pl">Cancel</a>
108
                                </fieldset>
109
                            </div>
110
                            [% IF patron_lists %]
111
                                <div id="uselist" role="tabpanel" class="tab-pane">
112
                                    <fieldset class="rows">
113
                                        <legend>Use a patron list</legend>
114
                                        <ol>
115
                                            <li>
116
                                                <label for="patron_list_id">Patron list: </label>
117
                                                <select id="patron_list_id" name="patron_list_id">
118
                                                    <option value=""> -- Choose a patron list -- </option>
119
                                                    [% FOREACH pl IN patron_lists %]
120
                                                    <option value="[% pl.patron_list_id | html %]">[% pl.name | html %]</option>
121
                                                    [% END %]
122
                                                </select>
123
                                            </li>
124
                                        </ol>
125
                                    </fieldset>
126
                                    <fieldset class="action">
127
                                        <input type="submit" value="Continue" class="button" />
128
                                        <a class="cancel" href="/cgi-bin/koha/tools/tools-home.pl">Cancel</a>
129
                                    </fieldset>
130
                                </div>
131
                            [% END %]
132
                        </div> <!-- /.tab-content -->
125
                    </div><!-- /#batch_patron_options -->
133
                    </div><!-- /#batch_patron_options -->
126
                </form>
134
                </form>
127
                [% END %]
135
                [% END %]
Lines 419-426 Link Here
419
                    });
427
                    });
420
                    return false;
428
                    return false;
421
                });
429
                });
422
            [% ELSE %]
423
                $("#batch_patron_options").tabs();
424
            [% END %]
430
            [% END %]
425
431
426
            var values = new Array();
432
            var values = new Array();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/overduerules.tt (-84 / +87 lines)
Lines 71-158 Link Here
71
                <h3>Rules for overdue actions: [% IF ( branch ) %][% Branches.GetName( branch ) | html %][% ELSE %] default library [% END %]</h3>
71
                <h3>Rules for overdue actions: [% IF ( branch ) %][% Branches.GetName( branch ) | html %][% ELSE %] default library [% END %]</h3>
72
                    [% IF ( datasaved ) %]<div class="dialog message">Changes saved.</div> [% END %]
72
                    [% IF ( datasaved ) %]<div class="dialog message">Changes saved.</div> [% END %]
73
73
74
  <div id="rulestabs" class="toptabs">
74
                <div id="rulestabs" class="toptabs">
75
    <ul class="ui-tabs-nav">
75
                    <ul class="nav nav-tabs" role="tablist">
76
      [% FOR tab IN tabs %]
76
                        [% FOR tab IN tabs %]
77
          <li><a href="#[% tab.id | uri %]" class="tab [% tab.id | html %]" data-number="[% tab.number | html %]"></a></li>
77
                            <li role="presentation">
78
      [% END %]
78
                                <a href="#[% tab.id | uri %]" class="tab [% tab.id | html %]" data-number="[% tab.number | html %]" aria-controls="[% tab.id | uri %]" role="tab" data-toggle="tab"></a>
79
    </ul>
79
                            </li>
80
    [% FOR tab IN tabs %]
80
                        [% END %]
81
      <div id="[% tab.id | html %]">
81
                    </ul>
82
        <table>
82
                    <div class="tab-content">
83
          <thead>
83
                        [% FOR tab IN tabs %]
84
            <tr>
84
                            <div id="[% tab.id | html %]" role="tabpanel" class="tab-pane">
85
              <th>&nbsp;</th>
85
                                <table>
86
              <th scope="col">Delay</th>
86
                                    <thead>
87
              <th scope="col">Letter</th>
87
                                        <tr>
88
              <th scope="col">Restrict</th>
88
                                        <th>&nbsp;</th>
89
              [% FOREACH mtt IN message_transport_types %]
89
                                        <th scope="col">Delay</th>
90
                [% NEXT IF mtt == 'itiva' AND !Koha.Preference('TalkingTechItivaPhoneNotification') %]
90
                                        <th scope="col">Letter</th>
91
                [% NEXT IF mtt == 'phone' AND !Koha.Preference('PhoneNotification') %]
91
                                        <th scope="col">Restrict</th>
92
                <th scpre="col">
92
                                            [% FOREACH mtt IN message_transport_types %]
93
                  [% SWITCH mtt %]
93
                                                [% NEXT IF mtt == 'itiva' AND !Koha.Preference('TalkingTechItivaPhoneNotification') %]
94
                  [% CASE 'email' %]<span>Email</span>
94
                                                [% NEXT IF mtt == 'phone' AND !Koha.Preference('PhoneNotification') %]
95
                  [% CASE 'print' %]<span>Print</span>
95
                                                <th scope="col">
96
                  [% CASE 'sms' %]<span>SMS</span>
96
                                                    [% SWITCH mtt %]
97
                  [% CASE 'feed' %]<span>Feed</span>
97
                                                    [% CASE 'email' %]<span>Email</span>
98
                  [% CASE 'itiva' %]<span>Phone (i-tiva)</span>
98
                                                    [% CASE 'print' %]<span>Print</span>
99
                  [% CASE 'phone' %]<span>Phone</span>
99
                                                    [% CASE 'sms' %]<span>SMS</span>
100
                  [% CASE %]<span>[% mtt | html %]</span>
100
                                                    [% CASE 'feed' %]<span>Feed</span>
101
                  [% END %]
101
                                                    [% CASE 'itiva' %]<span>Phone (i-tiva)</span>
102
                </th>
102
                                                    [% CASE 'phone' %]<span>Phone</span>
103
              [% END %]
103
                                                    [% CASE %]<span>[% mtt | html %]</span>
104
            </tr>
104
                                                    [% END %]
105
          </thead>
105
                                                </th>
106
          <tbody>
106
                                            [% END %]
107
          [% FOREACH value IN tab.values %]
107
                                        </tr>
108
            <tr>
108
                                    </thead>
109
              <th scope="row">[% value.line | html %]</th>
109
                                    <tbody>
110
              <td>
110
                                        [% FOREACH value IN tab.values %]
111
              <input type="text" inputmode="numeric" pattern="[0-9]*" name="delay[% tab.number | html %]-[% value.overduename | html %]" value="[% value.delay | html %]" />
111
                                            <tr>
112
              </td>
112
                                                <th scope="row">[% value.line | html %]</th>
113
              <td>
113
                                                <td>
114
                <select name="letter[% tab.number | html %]-[% value.overduename | html %]">
114
                                                    <input type="text" inputmode="numeric" pattern="[0-9]*" name="delay[% tab.number | html %]-[% value.overduename | html %]" value="[% value.delay | html %]" />
115
                  <option value="">No notice</option>
115
                                                </td>
116
                  [% FOREACH letter IN letters %]
116
                                                <td>
117
                    [% IF letter.code == value.selected_lettercode %]
117
                                                    <select name="letter[% tab.number | html %]-[% value.overduename | html %]">
118
                      <option value="[% letter.code | html %]" selected="selected">[% letter.name | html %]</option>
118
                                                        <option value="">No notice</option>
119
                    [% ELSE %]
119
                                                        [% FOREACH letter IN letters %]
120
                      <option value="[% letter.code | html %]">[% letter.name | html %]</option>
120
                                                            [% IF letter.code == value.selected_lettercode %]
121
                    [% END %]
121
                                                            <option value="[% letter.code | html %]" selected="selected">[% letter.name | html %]</option>
122
                  [% END %]
122
                                                            [% ELSE %]
123
                </select>
123
                                                            <option value="[% letter.code | html %]">[% letter.name | html %]</option>
124
              </td>
124
                                                            [% END %]
125
              <td>
125
                                                        [% END %]
126
              [% IF ( value.debarred ) %]
126
                                                    </select>
127
                <input type="checkbox" name="debarred[% tab.number | html %]-[% value.overduename | html %]" checked="checked" value="1" />
127
                                                </td>
128
              [% ELSE %]
128
                                                <td>
129
                <input type="checkbox" name="debarred[% tab.number | html %]-[% value.overduename | html %]" value="1" />
129
                                                    [% IF ( value.debarred ) %]
130
              [% END %]
130
                                                        <input type="checkbox" name="debarred[% tab.number | html %]-[% value.overduename | html %]" checked="checked" value="1" />
131
              </td>
131
                                                    [% ELSE %]
132
              [% FOREACH mtt IN value.message_transport_types %]
132
                                                        <input type="checkbox" name="debarred[% tab.number | html %]-[% value.overduename | html %]" value="1" />
133
                [% NEXT IF mtt.value == 'itiva' AND !Koha.Preference('TalkingTechItivaPhoneNotification') %]
133
                                                    [% END %]
134
                [% NEXT IF mtt.value == 'phone' AND !Koha.Preference('PhoneNotification') %]
134
                                                </td>
135
                <td>
135
                                                [% FOREACH mtt IN value.message_transport_types %]
136
                  [% IF mtt.selected %]
136
                                                    [% NEXT IF mtt.value == 'itiva' AND !Koha.Preference('TalkingTechItivaPhoneNotification') %]
137
                    <input type="checkbox" name="mtt[% tab.number | html %]-[% value.overduename | html %]" value="[% mtt.value | html %]" checked="checked" />
137
                                                    [% NEXT IF mtt.value == 'phone' AND !Koha.Preference('PhoneNotification') %]
138
                  [% ELSE %]
138
                                                    <td>
139
                    [% IF mtt.value == "sms" and not Koha.Preference("SMSSendDriver") %]
139
                                                        [% IF mtt.selected %]
140
                      <input type="checkbox" name="mtt[% tab.number | html %]-[% value.overduename | html %]" value="[% mtt.value | html %]" disabled="disabled" />
140
                                                            <input type="checkbox" name="mtt[% tab.number | html %]-[% value.overduename | html %]" value="[% mtt.value | html %]" checked="checked" />
141
                    [% ELSE %]
141
                                                        [% ELSE %]
142
                      <input type="checkbox" name="mtt[% tab.number | html %]-[% value.overduename | html %]" value="[% mtt.value | html %]" />
142
                                                            [% IF mtt.value == "sms" and not Koha.Preference("SMSSendDriver") %]
143
                    [% END %]
143
                                                                <input type="checkbox" name="mtt[% tab.number | html %]-[% value.overduename | html %]" value="[% mtt.value | html %]" disabled="disabled" />
144
                  [% END %]
144
                                                            [% ELSE %]
145
                </td>
145
                                                                <input type="checkbox" name="mtt[% tab.number | html %]-[% value.overduename | html %]" value="[% mtt.value | html %]" />
146
              [% END %]
146
                                                            [% END %]
147
            </tr>
147
                                                        [% END %]
148
          [% END %]
148
                                                    </td>
149
          </tbody>
149
                                                [% END # /FOREACH mtt %]
150
        </table>
150
                                            </tr>
151
      </div>
151
                                        [% END # /FOREACH value %]
152
    [% END %]
152
                                    </tbody>
153
153
                                </table>
154
154
                            </div> <!-- /.tab-pane -->
155
</div>
155
                        [% END # /FOR tabs %]
156
                    </div> <!-- /.tab-content -->
157
                </div>
156
158
157
                <fieldset class="action"><input type="submit" value="Save changes" /></fieldset>
159
                <fieldset class="action"><input type="submit" value="Save changes" /></fieldset>
158
            </form>
160
            </form>
Lines 184-190 Link Here
184
                var id = $(this).attr("data-number");
186
                var id = $(this).attr("data-number");
185
                $(this).html(tab_map[id]);
187
                $(this).html(tab_map[id]);
186
            });
188
            });
187
            $('#rulestabs').tabs();
189
            if( $("#rulestabs .tab-pane.active").length < 1 ){
190
                $("#rulestabs a:first").tab("show");
191
            }
188
        });
192
        });
189
    </script>
193
    </script>
190
[% END %]
194
[% END %]
191
- 

Return to bug 30475