@@ -, +, @@ - On the search history page, confirm that the DataTables controls appear above each table: "Current" and "Previous" under both the "Catalog" and "Authority" tabs. - All controls should work correctly and affect only the corresponding table: Search, Clear filter, Copy, CSV, and Print. - Confirm that clicking a date in the date column checks the correct checkbox. - Confirm that toggling a checkbox correctly enables and disables the "Remove selected searches" button as well as the "Select searches to:" menu at the top of the table. --- .../bootstrap/en/modules/opac-search-history.tt | 52 +++++++++++++++++----- 1 file changed, 42 insertions(+), 10 deletions(-) --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-search-history.tt +++ a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-search-history.tt @@ -73,8 +73,14 @@ [% FOREACH s IN current_biblio_searches %] - - [% s.time |$KohaDates with_hours => 1 %] + + + + + + @@ -90,7 +96,7 @@ [% END # IF ( current_biblio_searches ) %] - +
[% IF ( previous_biblio_searches ) %]

Previous sessions

@@ -110,8 +116,14 @@ [% FOREACH s IN previous_biblio_searches %] - - [% s.time |$KohaDates with_hours => 1 %] + + + + + +
@@ -154,8 +166,14 @@ [% FOREACH s IN current_authority_searches %] - - [% s.time |$KohaDates with_hours => 1 %] + + + + + + [% s.query_desc | html %] [% s.total | html %] @@ -183,8 +201,14 @@ [% FOREACH s IN previous_authority_searches %] - - [% s.time |$KohaDates with_hours => 1 %] + + + + + + [% s.query_desc | html %] [% s.total | html %] @@ -233,10 +257,15 @@ // (so that the more recent query is shown first) $(".historyt").dataTable($.extend(true, {}, dataTablesDefaults, { "order": [[ 1, "desc" ]], + "dom": '<"top"<"table_entries"><"table_controls"fB>>t', "columnDefs": [ { "targets": [ 0 ], "sortable": false, "searchable": false }, { "targets": [ 1 ], "type": "title-string" }, - ] + ], + "language": { + "search": "_INPUT_", + "searchPlaceholder": _("Search") + } })); [% IF Koha.Preference( 'OpacAuthorities' ) == 1 %]$('#tabs').tabs();[% END %] @@ -271,6 +300,7 @@ } return false; }); + $(".remove-selected").addClass("disabled"); }); function enableCheckboxActions(form){ @@ -279,9 +309,11 @@ if ($(checkedBoxes).size()) { $(form).find(".selections").html(_("With selected searches: ")); $(form).find(".selections-toolbar .links a").removeClass("disabled"); + $(form).find(".remove-selected").removeClass("disabled"); } else { $(form).find(".selections").html(_("Select searches to: ")); $(form).find(".selections-toolbar .links a").addClass("disabled"); + $(form).find(".remove-selected").addClass("disabled"); } } --