Commit graph

23070 commits

Author SHA1 Message Date
cee9da8efc
Bug 33737: Add bookings tab to patron details
This patch adds a new 'bookings' tab to the bottom of the members
details pages.  When a patron has any future or current bookings against
their record the tab will display the number of bookings in the tab name
and on clicking the tab a bookings table will display the current and
upcoming bookings.

Signed-off-by: Esther Melander <esther@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:56 +02:00
f30293fcc1
Bug 35994: (follow-up) Add class for customization
Also wraps statuses into b instead of the SWITCH statement,
which should hopefully help to make translation a little nicer.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:55 +02:00
cc567cb755
Bug 35994: Show acq_status on catalogue/detail
Test plan:
Based on the described criteria, check a few biblio records.
Look at Acquisitions tab on the intranet detail page.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:54 +02:00
21c87aeb15
Bug 36018: biblio->active_orders should be ->uncancelled_orders
Active orders are more than just not cancelled. See filter_by_active
in Koha::Acquisition::Orders. They are still in the acq process; we
still need to receive items on those orders.

When we cancel and want to delete a biblio, we should check for not
cancelled orders (broader than active orders as in Orders.pm).

Test plan:
Git grep active_orders.
Run t/db_dependent/Koha/Biblio.t
Run t/db_dependent/Koha/Acquisition/Order.t
Add two order lines in a basket referring to same biblio. Try to
cancel with delete biblio. Should not be possible.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Janusz Kaczmarek <januszop@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:46 +02:00
e94df657b7
Bug 26567: (follow-up) Update label and add check for RoutingSerials
The system preference RoutingSerials controls if the routing list
feature is available in the staff interface or not. If routing lists
are deactivated, the search option should not show.

Also updated the label to read: "Has routing list"

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:44 +02:00
ac5084641e
Bug 26567: Allow to limit subscription search to subscriptions with routing lists
Adds a search option to the advanced search in the
serials module that allows to limit search on subscriptions
with routing lists.

Test plan:
1. Apply this patch
2. Create two subscriptions, one with a routing list and one without
3. Navigate to Serials home and tick the checkbox labeled "Search routing lists only:"
4. Confirm that the only search result to appear is the subscription you added the routing list to
5. Run unit tests: prove t/db_dependent/Serials.t

Sponsored by: Bibliotheksservice-Zentrum Baden-Wuerttemberg

Signed-off-by: Christian Stelzenmüller <christian.stelzenmueller@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Perltidied changes to make QA test tools pass.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 16:45:44 +02:00
b1944c7895
Bug 36757: (QA follow-up) Fix for action on different triggers
This patch updates the 'title' and 'comment count' links to action the
same ticket detail/update modal as the 'details' button.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Paul Derscheid <paulderscheid@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:12 +02:00
fffe081bec
Bug 34655: (QA follow-up) Tidy the file
As we're already updating whitespace over almost the entire file, we may
as well go and tidy the whole thing too and add the /* keep tidy */
flag. (I checked for conflicts with existing bugs.. there's bug 20930
which will need a rebase, but it will already conflict and need a rebase
and is currently FQA)

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:12 +02:00
d5e20a8321
Bug 34655: Prevent selenium/system_preferences_search.t to fail randomly
Removing this JS code from document.ready.
The script tag is at the end of the DOM and there is no good reasons (at
least I didn't find any) to wait for the whole document to be ready
before executing the JS code.

It made the selenium tests selenium/system_preferences_search.t to fail
randomly with:
    #   Failed test 'The first "Policy" section (under "Accounting") is currently expanded'
    #   at t/db_dependent/selenium/system_preferences_search.t line 63.
    #          got: undef
    #     expected: 'expanded'
    # Looks like you failed 1 test of 6.

Because we set the class in this JS code and selenium won't wait for it
to finish before starting running the tests.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:11 +02:00
4d0e4f583e
Bug 34788: (follow-up) Terminology: biblio record
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:10 +02:00
d2820f57d6
Bug 34788: (QA follow-up)
This patch fixes a few things:
1) The blue dialog box now clears when navigating away from the page
2) The background job now uses skip_record_index to avoid queuing indexing jobs for every new biblio and instead queues one job at the end
3) Large files that get chunked now successfully create linked biblios if requested
4) Title matching rules have been expanded to check the package ID so that we can have duplicate titles in different packages
5) A link to the package is now included on the job report page

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:09 +02:00
e8763a720c
Bug 34788: Allow import of file with additional columns
This patch allows a file with additional columns to be imported. When the file is submitted, the system will enqueue the background job and send back information to the UI that certain columns have been ignored. The data will stil l import as normal but only the standard KBART columns will be parsed and imported

Signed-off-by: Clemens Tubach <clemens.tubach@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:09 +02:00
d31f453186
Bug 34788: Make biblio creation optional
This patch rebases in the changes from bug 36618 to make biblio creation optional

Signed-off-by: Clemens Tubach <clemens.tubach@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:08 +02:00
3814437003
Bug 34788: Allow for import of CSV files
This commit allows CSV files to be imported alongside TSV files.
It also adds some performance improvements relating to the max_allowed_packet and the matching of titles, as well as some small bugfixes and unit test changes

Test plan:
1) Enable the ERM module
2) Navigate to E-resource management > eHoldings > Local > Packages
3) Create at least one package
4) Navigate to E-resource management > eHoldings > Local > Titles
5) There should be a button for "Import from KBART file"
6) Click this button
7) Select the package that you created from the dropdown and then choose your KBART file using the "Choose file" button. I have attached some example files to the bug but feel free to use your own if you have them.
8) Click Submit
9) If your file is a valid file, a background job will be queued, if not then a warning will display showing what is incorrect in your file
10) To test the file format warning, edit your file and add a random column heading into the file e.g. test_column. When you upload it, the warning should show that an invalid column "test_column" has been detected
11) Click on the background job. (If you have uploaded a very large file, the system will chunk the file into smaller pieces and create multiple background jobs)
12) It should display a progress bar followed by a report and any error messages
13) Navigate to E-resource management > eHoldings > Local > Titles and you should see your new titles.
14) Run the unit test: prove t/db_dependent/Koha/BackgroundJob/ImportKBARTFile.t

Signed-off-by: Clemens Tubach <clemens.tubach@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:08 +02:00
698c1e930b
Bug 34788: Add a relationship to a package for the imported file
Signed-off-by: Clemens Tubach <clemens.tubach@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:07 +02:00
1320dc2cd2
Bug 34788: Add a background job to import a KBART file
This patch adds a background job that will import a KBART file

Sponsored-by: UKHSA
Signed-off-by: Clemens Tubach <clemens.tubach@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:06 +02:00
d3222816bb
Bug 34788: Add Vue components, api client and navigation route
This patch adds a new component to handle the file import, a route to that component and the API client route needed to access the API

Signed-off-by: Clemens Tubach <clemens.tubach@kit.edu>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:06 +02:00
Phil Ringnalda
9af249057c
Bug 36823: Switch database schema links in Reports from master to main
Test plan:
1. Reports > click Database schema link, verify it gets a 404 not foun
2. Reports > Use saved > click Database schema link, verify 404
3. Apply patch
4. Reports > click Database schema link, verify it loads as main
5. Reports > Use saved > click Database schema link, verify it loads

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 15:19:01 +02:00
Michał Kula
bc58644a32
Bug 35812: specify canonical URL for the main page
Currently main page can be accessed by:
- /
- /index.html
- /cgi-bin/koha/opac-main.pl

This specifies the canonical link for all of them to be "/", to aid search engines in assessing what's url to put in the index.

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:55 +02:00
Michał Kula
119c48e6b6
Bug 35812: Add canonical URL for biblio details page
This adds a nice canonical URL for search engines to use. Will prevent duplicates with different URL query parameters from getting indexed separately, will also prevent search engine confusion when opac-search.pl redirects to opac-detail.pl when there's just one result.

Should result in prettier/simpler URLs in the search engines too, plus removal of constant warnings in Google Search Console and other tools.

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:54 +02:00
Michał Kula
2273ac8080
Bug 35812: add noindex attribute to search result pages in OPAC
This will prevent search engines from putting the search results pages into their indexes, to prevent cluttering of the search results and give better visibility to the actual bibliographic records' pages.

Note that "noindex" is separate from "nofollow", meaning that the search engine is allowed to get and process the search results page and extract ("follow") further links from it, such as links to biblio records, which is exactly what we want.

This approach is better to the sitemaps, which search engines are free to choose whether to use or not, based on multiple factors such as the size of the page. In practice for small pages Google will just not download them at all, meaning that indexing by following links around is the only way the indexer will extract any links.

Note that for this to work properly, you must NOT block the affected pages in your robots.txt file (they're not blocked by default).

Also, this patch moves "cssinclude" block in opac-results.tt inside of <head>, because in all other templates it's inside, meaning its current positioning is a small mistake I fixed while at it.

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:54 +02:00
Janusz Kaczmarek
6e09fb6ad8
Bug 36388: Mouse operation does not work in draggable fields in authority editor
When using the authority editor in Firefox, it is not possible to set
the cursor or select text from the text field.

This patch mimics the corrections made in bug 35425 for biblio editor.

Test plan:
==========
1. Start editing an existing authority record and try to put the cursor
   with the mouse in the middle of the content of any subfield or to
   select text with the mouse. It should not be possilbe.
2. Apply the patch (reload plack etc.).
3. Repeat p. 1 - everything should work as expected.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:48 +02:00
Emily Lamancusa
95d68c6bbd
Bug 36775: (QA follow-up) Remove max_length attribute
The existing code for "Holds to place (count)" sets the input field's
maxlength to remaining_holds_for_record, which does not do what we want
and makes the field unusable when the circulation rules allow unlimited
holds. Better to remove it.

Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:47 +02:00
Andrew Fuerste Henry
c345e68769
Bug 36775: Allow multiple holds on record when holds per record is unlimited
To test:
1 set Holds Per Record to Unlimited
2 confirm hold placement interface does not include "Holds to place (count)"
3 apply patch, restart all
4 reload hold placement interface, confirm it does include "Holds to place (count)"
5 set Holds Per Record to 2
6 confirm Holds to place shows when placing a first hold for a patron, but not when placing a second
7 set Holds Per Record to 1
8 confirm Holds to Place does not show
9 sign off and eat a nice snack

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:47 +02:00
Phil Ringnalda
a8f4fe946c
Bug 27363: Restore temporary selection of Z39.50 targets throughout multiple searches
The advanced editor currently saves which Z39.50 servers are selected
in local storage using the index in the sorted array of servers, and
then misreads them back as though they were server_ids. We want them to
be server_ids, since that's immutable and the index can change with
changes in rank or server name.

We use the data-server-id property in the HTML more often as a server_id
than as the index that's currently stored there, so this patches
switches it back to be the server_id, and in the one place we would use
the index, instead uses Array.find to just get the server object instead
of referencing it by index.

Test plan:
 1. Set the preference EnableAdvancedCatalogingEditor to enable
 2. Administration - Z39.50 Servers, for NATIONAL LIBRARY OF FRANCE
    uncheck "Preselected"
 3. To be sure you don't have confusing saved preferences, open
    Firefox's Developer Tools, in the Storage tab open Local Storage and
    select your URL
 4. In the row for cateditor_preferences_{your Koha user id}, if there
    are any values for selected_search_targets, delete them so you
    have "selected_search_targets":{}
 5. Open the advanced editor, and click "Advanced »" in the search box
 6. You should have Local catalog unchecked, LIBRARY OF CONGRESS checked
    because it is preselected, and NATIONAL LIBRARY OF FRANCE unchecked
 7. Toggle each checkbox so Local catalog and France are selected, and
    LoC is unselected.
 8. In a new broser tab, open the advanced editor, and click "Advanced »"
 9. You will see Local catalog unchecked, LoC checked, and France
    unchecked.
    That's the bug.
10. Apply patch, open the advanced editor in a new tab, click "Advanced »"
11. Toggle the checkboxes so Local catalog and France are selected, and
    LoC is not selected.
12. Open the advanced editor in another new tab, click "Advanced »"
13. You should see what you just set, Local catalog and France checked,
    and LoC unchecked, That's the correct behavior.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:45 +02:00
e6b778b5d4
Bug 36804: Fix clear filter
1) Visit serials and click "New subscription":
http://localhost:8081/cgi-bin/koha/serials/serials-home.pl
2) Enter '112' on the record input and '1' on the vendor input. Click "Next"
3) 'First issue publication date' -> Enter some date in the past
4) 'Frequency' -> Enter '2/day'
5) 'Subscription start date' Same as step 3)
6) 'Subscription end date' Some date in the future
7) 'Numbering pattern' -> Enter 'Number'
8) Click 'Test prediction pattern'. Click 'Save subscription'
9) On the left side menu -> Click "Serial collection". Click the yellow button 'Edit serials'
10) On the first serial, edit the status to 'Late'. Save.
11) Visit serials claims:
http://localhost:8081/cgi-bin/koha/serials/claims.pl?supplierid=1
12) Input some dates in "From" and "To"
13) Click 'Clear filter'. Notice it doesn't work.
14) Apply patch. Repeat.

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:45 +02:00
1137793e44
Bug 34263: (QA follow-up): Use flatpickr .clear instead
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:44 +02:00
Katariina Pohto
0f0479e87a
Bug 34263: Suspending holds consecutively populates previously used date falsely
Suspending a hold doesn't clear the date from the date picker. When another hold is suspended
the previously used date will show on the date picker but the value is not set on the hold.
Suspending the hold will suspend it indefinitely. Also the link "Clear date to suspend indefinitely"
will not clear the date picker. This patch will make both the Suspend button and the Clear date link
clear the dates from both the date picker and the variable passed on, making the suspending consistent
with what is seen on the date picker.

Test plan:
1) Place 3 holds on a patron.
2) Suspend a hold and set a date for it.
3) Suspend a second hold and notice the previously used date is shown on the date picker.
   Note that the hold will be suspended indefinitely.
4) Open the suspending window for the third hold and pick a date. Click "Clear date to suspend indefinitely"
   and note the date picker doesn't get cleared. The hold will be suspended indefinitely.
5) Apply patch.
6) Suspend a hold and set a date for it.
7) Suspend a second hold and notice the date picker does not have a preset date.
8) Pick a date and clear it with the "Clear date to suspend indefinitely link".
   See that the date picker also gets cleared.

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:43 +02:00
c6e2995d27
Bug 36774: Remove wrapper if already exists
Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-10 14:11:42 +02:00
0945cdf5d6
Bug 19768: Add "Title notes" tab to OpacSerialDefaultTab preference
This patch adds a "title notes tab" option to the opacSerialDefaultTab
preference.

To test, apply the patch and restart services.

- Go to Administration -> System preferences -> opacSerialDefaultTab.
- There should now be a new options, "title notes tab."
- Set the preference to the new value.

- Go to the OPAC and locate a bibliographic record which is associated
  with a subscription and which has data in a 5XX notes field.
- On the bibliographic detail page the "Title notes" tab should be
  selected by default.
- Test that the other system preference values still work correctly too.

Sponsored-by: Athens County Public Libraries
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 20:04:09 +02:00
d8465adfe5
Bug 36618: (QA follow-up) Hide option for titles with no linked record
This patch hides the "Update linked biblio" option for titles that have been created with no linked biblio record

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 20:04:08 +02:00
08992ab711
Bug 36618: Make biblio creation optional for ERM local titles
This patch makes biblio creation on local title creation optional.

Test plan:
1) Navigate to the local title creation form
2) Create a title and leave the "Create record" box unchecked
3) Submit the form
4) Search the catalogue for the title you have just created - no biblio result will be available
5) Repeat steps 2 - 3 but this time check the box to create a record
6) You should now be able to find a record in the catalogue for the title you just imported

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 20:04:07 +02:00
956755fa15
Revert "Bug 34263: Suspending holds consecutively populates previously used date falsely"
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 20:04:07 +02:00
10853d1edc
Bug 36582: Add option to set library, desk, and register from user menu
This patch adds an expandable "panel" in the user dropdown menu in the
staff client. Expanding the panel will load the form from
set-library.pl, including library, desk and register options if present.

The patch moves the contents of desk_selection.js and
register_selection.js into staff-global.js so that the functionality is
available on every page.

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

Test plan stolen from Bug 36572:

1. Have 3 staff accounts to test:
  -STAFF A: superlibrarian
  -STAFF B: loggedinlibrary permission
  -STAFF C: no loggedinlibrary or superlibrarian permission
2. Enable 'UseCirculationDesks' and create some desks. (Admin >
   Circulation desks)
3. Enable 'UseCashRegisters' and create some registers ( Admin > Cash
   registers)
4. Use STAFF A ( superlibrarian ) and make sure you can change branch,
   desk and register.
5. Use STAFF B ( loggedinlibrary permission ) and make sure you can
   change branch, desk and register.
6. Use STAFF C ( no loggedinlibrary or superlibrarian permission ) and
   make sure you can change branch, desk and register.
7. Each time you change you should be redirected to the page you were
   previously on.
8. Turn off UseCirculationDesks, make sure everything still works.
9. Turn off UseCashRegisters, make sure everthing still works.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:24:01 +02:00
42944b3e9b
Bug 35648: (follow-up) Remove sorting from transport columns
There's not a simple way to handle sorting of a column containing only
checkboxes, so I think it makes sense to remove the sorting unless
someone feels strongly about it being necessary.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:24:00 +02:00
109a1e93dc
Bug 35648: (follow-up) Clear table filter before submitting
This patch takes advise from elasticsearch-mappings.js and adds an
onsubmit event to clear any DataTables filter before submitting. This
should prevent hidden fields from being overwritten.

To test, filter the table and make a change to one of the visible rows.
After submitting, confirm that the previously-hidden rows retain the
same settings as before.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:24:00 +02:00
2800f7c9fb
Bug 35648: Allow sorting of patron categories in Overdue notice/status triggers
This patch adds a basic DataTables configuration to the table of patron
categories on the Overdue notice/status triggers page. The table can be
sorted by patron category and can be filtered.

To test, apply the patch and go to Tools -> Overdue notice/status
triggers.

- Confirm that the table of patron categories is sorted by default by
   patron category
- Other columns should not be sortable
- You should see a search field above the table which works to filter by
  patron category.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:59 +02:00
ac19b97974
Bug 36755: Update UI input element
Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:57 +02:00
Aleisha Amohia
d8baa5090b
Bug 32256: Use a new SCOBatchCheckoutsValidCategories syspref
So that this functionality can be controlled separately from staff-side batch checkouts

Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:55 +02:00
Aleisha Amohia
bb059abe90
Bug 32256: Handle batch error messages better
This enhancement modifies the self-checkout script to better handle 'impossible' and 'needs confirmation' checkout messages.

Test with a combination of barcodes that would invoke these messages, for example:
- impossible: barcode doesn't exist
- impossible: barcode is for a 'notforloan' item type
- impossible: debt
- needs confirmation: barcode already checked out, i.e. confirm renewal

Include barcodes that should have successful checkouts too.

Also, test with the following sysprefs:
- BatchCheckouts: enabled
- BatchCheckoutsValidCategories: none selected

Confirm SCO does not have a multi-line text area for more than one barcode, and doesn't accept more than one barcode.

Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:54 +02:00
Aleisha Amohia
3c57d0f3db
Bug 32256: Display barcodes not checked out in batch
This patch encourages the user to check out certain items individually if they fail to be checked out in a batch.

This way they will be presented with more useful error messages.

To test:

1 - Enable BatchCheckouts, select nothing in BatchCheckoutsValidCategories
2 - Find three barcodes
3 - log into SCO with a user in category Patron, paste the barcodes separated by newlines and submit. confirm one item is succcessfully checked out and the other two barcodes are listed in the pop-up, encouraged to try checking out individually.
4 - select Patron in BatchCheckoutsValidCategories
5 - log into SCO with your Patron user again, confirm you can check out multiple items at a time

Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:54 +02:00
Aleisha Amohia
297ad2bb6f
Bug 32256: Add message to SCO that batch checkouts works for checkouts only
Not yet handling renewals, returns, or items that are impossible to check out.

Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:53 +02:00
Aleisha Amohia
6a70c126d1
Bug 32256: Enable batch checkout using self-checkout
This patch allows more than one item to be scanned and processed at once in Koha's self-checkout module. The items in the batch will still be handled one-by-one, so if any item in the batch requires confirmation (i.e. to be renewed or returned) or is impossible to check out, the process will stop at that item. Any items earlier in the list will be processed, but any items coming after in the list will be ignored. This feature uses the existing BatchCheckouts and BatchCheckoutsValidCategories system preferences to determine if batch checkouts should be allowed.

To test:
1) Open the staff interface. Go to Koha Administration -> Global system preferences. Search for "BatchCheckouts". Confirm BatchCheckouts syspref is disabled, and no categories are selected for the BatchCheckoutsValidCategories syspref.
2) In another tab, open the OPAC self checkout (found out OPACBaseURL/cgi-bin/koha/sco/sco-main.pl) and log in
3) Confirm the self-checkout works as normal for checking out, returning or renewing one item at a time
4) Go back to the staff interface tab (you may need to log back in). Enable the BatchCheckouts syspref but leave the BatchCheckoutsValidCategories syspref empty.
5) Refresh the OPAC self checkout tab. The barcode input field will now be bigger to support a list of barcodes. Enter a list of barcodes separated by newlines and Submit.
6) Only the first barcode should be processed. This is because no categories are valid for BatchCheckouts.
7) Go back to the staff interface tab (you may need to log back in). Select at least your patron category for the BatchCheckoutsValidCategories syspref and Save.
8) Refresh the OPAC self checkout tab. Enter a list of barcodes separated by newlines and Submit. Confirm all valid items are checked out as expected.
9) Test with a few items that are notforloan or would not be valid checkouts. Confirm they are not checked out, but other valid items in the batch are checked out successfully.
10) Test with a batch where one of the items is already checked out to the patron. The batch should get blocked at this item as the self-checkout asks for confirmation.
11) Test with both renewing and returning of items that are already checked out to the patron. This will only work with one item at a time and later items in the list will be ignored.

Sponsored-by: Koha-US
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Andrew Fuerste Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:52 +02:00
a2aa3053a8
Bug 31097: (follow-up) Rename link from 'account' to 'charges'
The tab has been renamed at some point and I think the link should
be adapted to be clear where it leads to.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:51 +02:00
1966938c6f
Bug 31097: (follow-up) Standardize appearance of colon between restriction type and comments
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:51 +02:00
0967c18adb
Bug 31097: (follow-up) Restructure messages a bit
This patch updates the patron restrictions markup and splits up some
strings to (hopefully) improve the translation process. The patch also
fixes a bug in a previous patch which prevented manual restrictions from
being displayed if there was also a restriction added by
overdue_notices.pl.

Test that all three kinds of restrictions display correctly:

 - Restrictions added by overdue process
 - Manual restriction without an expiration date
 - Manual restriction with an expiration date

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:50 +02:00
1f53e721ef
Bug 31097: Add classes, drop an ELSE, drop <br />
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:49 +02:00
Philip Orr
2dd1fd5587
Bug 31097: Added more restrictions info
Added more info to the restrictions message
in circulation as well as to the OPAC display
in "Your account" and to the display of
restriction messages when trying to place a
hold in the OPAC.

To Test:
1. Before applying patch, set system preference
"PatronRestrictionTypes" to "Allow"
2. Go to Administration -> Patron restriction types
3. Add some restriction types, make sure you
fill out both "Code" and "Label"
4. Go to any patron and add one or more of each
restriction type
4a. Make sure that you add some with an
expiration date and some without
4b. Make sure you add some with a comment and
some without
5. Go to that patron's checkout page
6. Notice that only the comments of the
restrictions are displayed and not all info
is displayed
7. Apply the patch
8. Reload the page
9. Notice the restriction types are now
displayed correctly
10. Notice the colon is only displayed
if there is a comment
11. Notice the expiration date is also displayed
12. Open the OPAC and log in with that user
(or if you want to log in with your own user:
 make sure they have all the restrictions
 mentioned above as well)
13. Go to "Your account" in the OPAC
14. Notice the display of restrictions
15. Try to place a hold on any record
16. Notice the display of restrictions

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:49 +02:00
Philip Orr
a2fa3a1719
Bug 31097: Display restriction types
This patch changes the display of patron
restrictions in checkout and patron details
pages to show the restriction type for each
restriction. It also changes the display so
each restriction is shown on a newline.

To test:
1. Before applying patch, set system preference
"PatronRestrictionTypes" to "Allow"
2. Go to Administration -> Patron restriction types
3. Add some restriction types, make sure you
fill out both "Code" and "Label"
4. Go to any patron and add one or more of each
restriction type
5. Go to that patron's checkout page
6. Notice that only the comments of the
restrictions are displayed
7. Apply the patch
8. Reload the page
9. Notice the restriction types are now
displayed correctly

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:48 +02:00
Emily Lamancusa
7b4b3f7487
Bug 36701: Adjust confirmation to hide empty div
To test:
1. Place a hold on any bib record
2. Cancel the hold by clicking the trash can icon next to it
--> Note that there is an empty red page section in the modal
3. Apply patch and refresh the page
4. Repeat steps 1-2
--> No empty red page section
5. Confirm that the test plan from bug 33174 still works

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-05-08 18:23:48 +02:00