Bug 27005: Adding a filter in the datatable of opac-readingrecord page
authorOwen Leonard <oleonard@myacpl.org>
Thu, 12 Nov 2020 16:37:33 +0000 (11:37 -0500)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Mon, 8 Feb 2021 16:09:32 +0000 (17:09 +0100)
commitebc20ffef41a62ef31f0be5e5f16cea68ed0107f
tree580fecd341ca9ed3dd4a150339426327b91ed97c
parentd3323881d508d17d5fcfd9e134281c0778a6590f
Bug 27005: Adding a filter in the datatable of opac-readingrecord page

This patch adds a search field and export options to the
patron's checkout history table in the OPAC.

This patch also adds some showing/hiding classes to controls which
should only be seen by users with or without JavaScript: The <select>
for resorting the table is hidden when JS is enabled. The tabs for
filtering checkouts from on-site checkouts are hidden when JS is
disabled.

To test, apply the patch and rebuild the OPAC CSS
(https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client).

 - Log in to the OPAC as a user who has both regular and on-site
   checkouts.
 - Go to "Your checkout history."
 - The table of checkouts should have controls at the top: A search
   field, "Clear filter," "Copy," "CSV," and "Print."
 - Confirm that the search filter works: Enter some text which will
   return results among regular or on-site checkouts.
   - It should work correctly to filter the results.
   - If you switch tabs, the filter should persist, and correctly filter
     the results under "Checkouts" and "On-site checkouts."
   - The "Clear filter" button should work correctly to clear your
     search.
  - Test the export and print button to confirm that they work for each
    table.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/opac-tmpl/bootstrap/css/src/_common.scss
koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-readingrecord.tt