Bug 14854: Add DataTables on upload results table
This patch adds datatables to the upload results table. Tools -> Upload To test: 1) Go to Tools -> Upload 2) Put any search term in search box, click Search 3) Confirm table shows as datatable and sorting works on all columns EXCEPT Actions Sponsored-by: Catalyst IT Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
parent
d115602c98
commit
40babe1a10
1 changed files with 10 additions and 2 deletions
|
@ -6,6 +6,7 @@
|
||||||
<title>Koha › Tools › Upload</title>
|
<title>Koha › Tools › Upload</title>
|
||||||
[% END %]
|
[% END %]
|
||||||
[% INCLUDE 'doc-head-close.inc' %]
|
[% INCLUDE 'doc-head-close.inc' %]
|
||||||
|
<link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" />
|
||||||
|
|
||||||
[% BLOCK plugin_pars %]
|
[% BLOCK plugin_pars %]
|
||||||
[% IF plugin %]
|
[% IF plugin %]
|
||||||
|
@ -147,7 +148,7 @@
|
||||||
[% END %]
|
[% END %]
|
||||||
|
|
||||||
[% BLOCK table_results %]
|
[% BLOCK table_results %]
|
||||||
<table>
|
<table id="uploadresults">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Filename</th>
|
<th>Filename</th>
|
||||||
|
@ -156,7 +157,7 @@
|
||||||
<th>Category</th>
|
<th>Category</th>
|
||||||
[% IF !plugin %]<th>Public</th>[% END %]
|
[% IF !plugin %]<th>Public</th>[% END %]
|
||||||
[% IF !plugin %]<th>Temporary</th>[% END %]
|
[% IF !plugin %]<th>Temporary</th>[% END %]
|
||||||
<th>Actions</th>
|
<th class="nosort">Actions</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
@ -185,6 +186,7 @@
|
||||||
</table>
|
</table>
|
||||||
[% END %]
|
[% END %]
|
||||||
|
|
||||||
|
[% INCLUDE 'datatables.inc' %]
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
#fileuploadstatus,#fileuploadfailed { display : none; }
|
#fileuploadstatus,#fileuploadfailed { display : none; }
|
||||||
#fileuploadstatus { margin:.4em; }
|
#fileuploadstatus { margin:.4em; }
|
||||||
|
@ -304,6 +306,12 @@ function Choose(hashval) {
|
||||||
window.close();
|
window.close();
|
||||||
}
|
}
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
$("#uploadresults").dataTable($.extend(true, {}, dataTablesDefaults, {
|
||||||
|
"aoColumnDefs": [
|
||||||
|
{ 'bSortable': false, 'aTargets': [ 'nosort' ] }
|
||||||
|
],
|
||||||
|
"sPaginationType": "four_button"
|
||||||
|
}));
|
||||||
[% IF msg %]
|
[% IF msg %]
|
||||||
ShowAlerts( [% msg %] );
|
ShowAlerts( [% msg %] );
|
||||||
[% END %]
|
[% END %]
|
||||||
|
|
Loading…
Reference in a new issue