Commit Graph

57127 Commits

Author SHA1 Message Date
Nick Clemens 95ca056cdc
Bug 40651: Select custom search field if passed in via link
This patch checks for a custom field value and preselects it in the
dropdown if present

To test:
1 - Browse to Administration - Item search fields
2 - Add a new search field pointing to a marc field with some known
    value on a record with items
3 - Browse to Item search
4 - Construct a search using your new field and search
5 - From results click 'Copy shareable link'
6 - Go to the link
7 - No results or wrong results!
8 - Edit the search
9 - Note your custom field is not selected
10 - Apply patch
11 - Visit the link again
12 - Correct results!
13 - Edit search
14 - Custom field is correctly selected!

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 14b485c6db)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
(cherry picked from commit 684cad615c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-10 14:17:13 +02:00
Tomas Cohen Arazi d26d32db83
Bug 40543: Remove pickup_library.branchname embed
This patch removes this wrongly added embed and adjusts the patron holds
history to use `pickup_location.name` instead.

To test:
1. Have a patron with some past holds from different branches
2. Browse their holds history
3. Search on the 'Library' column by name
=> SUCCESS: It works :-D
4. Apply the patch
5. Run:
   $ ktd --shell
  k$ yarn api:bundle
  k$ koha-plack --restart kohadev
6. Repeat 2-3
=> SUCCESS: Still works!
7. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 260a0af5db)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
(cherry picked from commit 9488baf31f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-10 14:11:53 +02:00
Baptiste Wojtkowski 9d9d5073d6
Bug 38619: UNIMARC prices should also be extracted from 071d
When adding a document that does not use 010d as price document, but 071d, the price is not imported from koha since it only checks 010d and 345d.

To reproduce:
1 - Create a Koha item, make sure there is neither 010d or 345d
2 - Add a 071d and fill a price
3 - Export the item as marcxml
4 - If you do not have one: in acquisition, create a vendor, a basket associated to this vendor, and a line associated to this vendor
5 - Add a line to any open basket, select: import "from a new file" and
  select the exported marcxml -> The price in 071 is not imported
6 - Apply patch
7 - Repeat 5 -> the price is properly imported

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 1cb2f97e8c)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
(cherry picked from commit 404280c868)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-10 13:44:18 +02:00
Owen Leonard 83b68d332a
Bug 39169: Automatically hide "active" and "budget period" columns on Acquisitions home page
This patch adds column configuration to the table settings for the
"Available funds" table on the Acquisitions home page. If a table has
column configration, hidden columns should be hidden in the
configuration rather than in the in-page table options.

To test, apply the patch and restart all services.

- Go to the Acquisitions home page
- In the "All available funds" section, you should not see "active" and
  "budget period" columns.
- NOTE: You may have to clear you browser's Local Storage in order for
  the change to show.
- If you go to Administration -> Table settings -> Acquisition ->
  acq_acqui-home you should see that the first two columns are hidden by
  default and cannot be toggled.

Signed-off-by: Andrew Fuerste Henry <andrew@bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 6df6337080)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-08 10:17:00 +02:00
Nick Clemens fa698d8026
Bug 39389: Don't stringify the system preference value
This bug is caused by the code that is intended to hide the export column when disabled failing
because the value of exports_enabled is "0" and not 0

To test:
1 - Checkout an item to a patron
2 - Disable ExportCircHistory
3 - Load the patron's circulation table on the Check Out tab
4 - Notice no export column
5 - Click 'Export' above the table and you can export
6 - Go to the patron's circulation table on the Details tab
7 - The export column shows
8 - Try to export - JS error
9 - Apply patch
10 - Clear local storage in the browser
11 - Repeat 3-6 - no more export column and you can export
12 - Enable ExportCircHistory
13 - Confirm the circ table on both pages hsows the export column and can be exported
     (You may need to clear local storage again)

Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Janne <janne.seppanen@lahti.fi>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4800537201)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-08 10:00:13 +02:00
Fridolin Somers c5b4736a80
Revert "Bug 39842: Populate current location for SIP item with holdingbranch"
This reverts commit eae8858d51.
2025-10-07 13:37:38 +02:00
Nick Clemens b9eba44a52
Bug 39421: Restore missing date picker on Circulation > Renew
This patch restores the renewal date input field (with a date
picker) for Circulation > Renew. This was missing.

It changes the behavor slightly so that it mirrors Circulation >
Check in. A settings icon is included in the barcode field,
clicking this then shows the date field with the date picker
(and any other options).

Previously on the renewals page (24.05.x and earlier), there was
no settings icon in the barcode field and the date input field
with date picker was already shown.

This user interface pattern is used elsewhere in Koha, and this
chnage will help improve consistency.

Test plan:
1. Browse to Circulation > Check in.
2. Note the settings icon in the barcode form field.
3. Click it to show the the return date field with a date picker,
   and other options.
4. Browse to Circulation > Renew.
5. Note there is no settings icon.
6. Apply the patch.
7. Repeat step 4 - note that there is now a settings icon.
8. Click the settings icon to show the renewal date form field.
9. Click the input field to show teh date picker.

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

PA amended: Squashed both patches for 24.11
2025-10-06 18:04:13 +02:00
Imani Thomas f8ba476990
Bug 39029: When a basket contains an order transferred from another basket some info is incorrect.
To test:
1 - Create a new basket - 'Gonna transfer'
2 - Add an order to the basket
3 - Create another basket 'Has the transfer'
4 - Return to first basket and transfer order to second
5 - Return to second basket, click 'Add to basket' and inspect the modal
6 - Note basketno says 'Gonna transfer'
7 - apply the patch
8 - redo steps 1 through 6 with fresh baskets and the modal should have the correct values

Signed-off-by: Andrew Auld <andrew.auld@openfifth.co.uk>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:59:05 +02:00
Alexander Blanchard 95bbddfda2
Bug 33012: Accessibility - Fix OPAC navigation when using the tab key
An accessibility audit highlighted that when logged in you cannot tab
to the log out link in the welcome menu. The search history link in
the same menu was also unable to be tabbed to. These links were also
not able to be reached using arrows.

The links for Your Lists, Private Lists and New List could be reached
using the arrows on the keyboard but not via the tab option.

Test plan:
1) Navigate to the Koha OPAC.
2) Ensure you are logged in.
3) Use tabs to navigate the site.
4) When you reach the Welcome menu press enter.
5) Note that you can tab to 'Your Account' and the 'Clear' icon but not
   to 'Search History' or to 'Log Out'
6) Tab also to the hamburger menu and press enter
7) Note than you can navigate this menu via the arrows on the keyboard but
   not via the tab button
8) Apply patch
9) Repeat steps 1-7
10) Note that you can now tab to all of the above links

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit a83c07da19)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:46:25 +02:00
Lucas Gass 9b1310d3f0
Bug 39604: Remember cancelreserve choice when remembering patron for session
To test:
1. Put a few items on hold and make note of the barcodes.
2. Check out one of the items to a patron who doesn't have the hold
3. Check the cancel hold radio button
4. Also check the Remember for the session for this patron
5. Click 'Yes, check out'
6. Notice the item is checked out and the hold is cancelled
7. No checkout another on hold item to the same patron
8. No confirm screen ( good )
9. The item is checked out ( good )
10. The hold is not cancelled. ( bad )
11. APPLY PATCH and restart all
12. Try steps 1 - 9 again. This time the 2nd hold should be cancelled.

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 6b80dec84d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:41:06 +02:00
David Cook 32cbbc4e61
Bug 39618: (QA follow-up) add prefix length to index key
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit ba3feb54ee)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:37:22 +02:00
Katrin Fischer f51547cfa7
Bug 39618: DBRev 24.11.009.002
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 8099e118ee)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:36:22 +02:00
Lucas Gass 1db6734bfd
Bug 39618: Add index to borrowers.preferred_name column
To test:
1. APPLY PATCH
2. updatedatabase

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 9276f33d4b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:33:53 +02:00
Lucas Gass 9b1cf2cdb7
Bug 39484: Fix external sounds in self checkout module
To test:
1. Enable AudioAlerts
2. Set something up in the SCO to play a sound from an external source. ( I used #sco_main as my selector )
3. Go to SCO and try to trigger the sound, nothing plays.
4. APPLY PATCH
5. Try steps 2 and 3 again, this time you should hear the sound from an external source.

Signed-off-by: Andrew <andrew.auld@openfifth.co.uk>
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 9f16b085b5)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:29:01 +02:00
Emily Lamancusa 31ab21c214
Bug 39400: (QA follow-up) Adjust link text
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f3080cbe5b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:27:06 +02:00
Phil Ringnalda 429cec6f31
Bug 39400: "Jump to add item form" doesn't work while editing an existing item
The link at the top of the item editor page to "Jump to add item form"
tries to scrollIntoView the element with id="additema", but that element
only exists while you are adding a new item. While you are editing an
existing item, it is replaced by an element with id="edititem".
Whichever element you have at the moment is always just below the form
with id="f", so we can just scroll that into view instead.

Test plan:
 1. Without the patch, go to the details page for any bib record with at
    least one item, and click the Edit button on the row for an item in
    the holdings table.
 2. You should be scrolled down to the form for editing that item
 3. Scroll up to the top of the page, click the Jump to add item form
    link
 4. You will not be scrolled back down to the form
 5. Apply patch, shift+reload page
 6. Now the link should scroll you back down to the form
 7. Return to the biblio details page, click Edit - Manage items and
    verify that the Jump to add item form link still works when you are
    not editing an existing item
 8. Click the Add multiple copies of this item button and add 30 items
 9. Make sure that the link still scrolls the form into view both while
    you are editing an existing item, and while you are adding a new item

Sponsored-by: Chetco Community Public Library
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit fcf705e2e3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:26:04 +02:00
Jonathan Druart 5dfad59117
Bug 35885: Sort vendors by name by default
Signed-off-by: Magnus Enger <magnus@libriotech.no>
To reproduce:
- Set ERMModule = Enable
- In the Acquisitions module I added 4 vendors, with names
  X, A, C, Y, in that order
- Went to E-resource management > Agreements > New agreement
- In the "Vendor" dropdown, the vendors are listed in the
  order they were entered: X, A, C, Y

To test:
- Applied the patch + restart_all + run "yarn js:build" in the
  cloned Koha repo inside KTD
- Shift-reload the "New agreement" page
- Vendors are in alphabetical order

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f6fd36ab77)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:23:50 +02:00
Andrew Auld e6f5c4711d
Bug 39543: Error modal when trying to add two controlling licences to an agreement duplicates error message
If you try to add two licences with the status 'controlling' to an
agreement record, the error modal duplicates the error message
'Only one controlling license is allowed'.

Test Plan:
1) Enable ERMModule sys pref
2) Add an agreement record
3) Add two licence records
4) Edit the agreement record and associate both license records to the agreement
5) Try to set both licenses to status 'controlling'
6) Note error modal duplicates the error message 'Only one controlling license is allowed'
7) Apply the patch, run yarn js:build and then hard refresh the browser
8) Repeat steps 1 to 5 and enjoy the single error message!

Signed-off-by: Magnus Enger <magnus@libriotech.no>
I took the liberty of fixing up the commit message a bit.
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f201ea5076)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:15:33 +02:00
Jonathan Druart f5ca9d88c6
Bug 39080: Adjust the fixed header after we added the column filters
If a column contains a dropdown list (for libraries for instance), the
width of the column will be modified, but DT's fixed header need to be
adjusted.

Test plan:
One example where this problem can be observed is the "holds to pull"
table: "Title" is followed by "Libraries".
Test without and with the patch, and confirm that the display/offset is fixed.

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 8e808e97b3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 17:11:05 +02:00
Baptiste Wojtkowski 53df24cb17
Bug 39317: Fix CSRF protection for letters
TEST PLAN:
1 - go to /cgi-bin/koha/tools/letter.pl
2 - click on New notice -> claim serial issue (or any other one)
3 - Fill required fields with random string
4 - Save -> if it breaks, go to
5 - Open a network panel (F12 -> network)
6 - Filter on letter.pl
7 - Fill another new notice -> the arguments of the form page have been
  passed in the address of the POST request.
8 - Apply patch
9 - Repeat the whole process and see it works now

Signed-off-by: Magnus Enger <magnus@libriotech.no>
I can't recreate the problem, but the change seems sensible enough
and does not seem to introduce a regression, I can still save a
new letter/notice.
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 248013a2a9)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:39:16 +02:00
Martin Renvoize a7b23c744e
Bug 37546: Error message output improvements
As suggested by David, I've re-arranged the message output so we pass
'message' first, followed by the error reference inside brackets,
followed by "for SERVER" and finally "result No."

This follows the Z39.50 suggestions more closely whilst still including
our level of detail for Server + Result number.

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit d32a1b7063)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:24:58 +02:00
Martin Renvoize 4f48879e58
Bug 37546: Output error message from ZOOM in Z3950 errors
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 03afbb442c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:24:34 +02:00
Jonathan Druart c0e27917b6
Bug 40046: Use xml and auto-select it
Absolutely no idea why the previous code was not selecting MARCXML (MARC
was passed and so the import failed)

        cy.get('select[name="format"]')
            .select("MARCXML", { force: true })
            .should("have.value", "MARCXML");

But I found a bug in the JS code: we are supposed to auto-detect .xml
file and pre-select MARCXML. So let's rely on that behaviour!

sample.mrc is actually an xml file so it makes sense to rename it

Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 0802e46e18)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
(cherry picked from commit 3c7ddb4070)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:22:59 +02:00
Jonathan Druart ac640e3813
Bug 40046: Prevent random failures when verifying select's values
Commands like .select() are queued. We need to prevent the should to
happen before the select is executed.

Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 9ebfd8d462)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
(cherry picked from commit b8709b9df0)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:22:59 +02:00
Jonathan Druart e274de676d
Bug 40046: (bug 39606 follow-up) Remove waits and screenshots
From bug 39606:
"""
Why are you taking screenshots?
The wait statements will certainly cause random failures.

cy.wait(5000);
cy.wait(2000);

Notice the following couple of lines:
  cy.get("#fileuploadstatus").contains("100%");
  cy.get("legend").contains("Look for existing records in catalog?").should('be.visible');

It makes Cypress wait 10s until "100%" appears (ie. the file is updated), then the block with the dropdown lists you are going to interact with to be visible.

You should almost never use cy.wait.
"""

Test plan:
  yarn cypress run --spec t/cypress/integration/Tools/ManageMarcImport_spec.ts
should still pass

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit f12bbbf010)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
(cherry picked from commit 1406d3b7a7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:20:54 +02:00
Lucas Gass 57f40adebc
Bug 39606: Add a cypress test
To test:
1. APPLY PATCH
2. cypress run --spec "t/cypress/integration/Tools/"
3. Tests should pass

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit b0cfcea861)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-06 16:20:40 +02:00
Lucas Gass 8c387f9d5b
Bug 39212: Explicitly set the contentType to JSON
To test:
1. Make an item or item type 'Bookable'
2. Place a booking for that item
3. Go the 'Bookings' tab for that item.
4. Edit the booking
5. Submit the edit request and see at the top of the modal "Failure"
6. APPLY PATCH
7. Try editing bookings, now it should work.

Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 7a125d7cc8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:26:53 +02:00
Lucas Gass b9a826b4f4
Bug 38861: Use a render function to display pickup name or pickup ID
To test:
0. Have some bookings that are ready to collect.
1. Load the bookings to collect report.
2. Table does not load.
3. APPLY PATCH
4. Try again, table loads.
5. Make sure you can filter by 'Pickup library'

Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 139fff4b27)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:25:48 +02:00
Andrew Fuerste Henry 9ec67bcba2
Bug 39576: Show preferred_name for hiddenborrowername
The last patron menu uses the value "hiddenborrowername." I've made that use preferred_name instead of firstname. When a patron's preferred_name is not manually set/edited, it automatically takes the value of firstname, so we don't need an IF in the template toolkit here.

To test:
1 - have a patron with a preferred_name and one without
2 - get both patrons in the Last Patron dropdown, confirm they both show firstname
3 - apply patch, restart services, clear cache, reload page
4 - get your patrons in Last Patron again, confirm now one shows preferred name and the other firstname

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 829186d77d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:21:23 +02:00
Hammat Wele 5748ef0ebc
Bug 33224: OPACHoldsIfAvailableAtPickup and no on-shelf holds don't mix well
When OPACHoldsIfAvailableAtPickup preference is set to Don't allow and circulation rules allow on-shelf holds only if any unavailable, and we have a record with a checked out copy at Centerville and an available copy at Midway, a Midway patron should not be able to place a hold for pickup at Midway since the Midway copy is available.

This is the setting:
- circulation rules allow on-shelf holds only if any unavailable
- OPACHoldsIfAvailableAtPickup is set to Don't allow

To test:
1. Set up the circulation rule so that on-shelf holds are allowed ('Yes')
2. Create a record with two items, one at Centerville and one at Midway
3. Check out the Centerville item
4. Log into the OPAC with a Midway patron (I used Henry Acevedo)
5. Try to place a hold on the record
   --> Midway is not a valid pickup location (correct behaviour)
6. Cancel
7. Change the circulation rules so that on-shelf holds are only allowed 'if any unavailable'
8. Try to place a hold on the record from the OPAC again
   --> The system allows you to place the hold for pickup at Midway (incorrect behaviour)
9. Optionally, check the Holds to pull for Midway (the hold is there, it shouldn't)
10. Optionnaly, check in the Midway item (it is trapped for Henry's hold)
11. Apply the patch
12. Try again to place a hold on the record from the OPAC
   --> it is impossible to select Midway, Midway is not a valid pickup location

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit e303854076)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:17:15 +02:00
Jonathan Druart 99781912b6
Bug 39075: DBIC schema changes
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit a387c0c381)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:13:01 +02:00
Jonathan Druart a8a6e9afff
Bug 39075: Explicit NOT NULL for timestamp
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 01f842f4a7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:12:44 +02:00
Katrin Fischer 8817cc6a21
Bug 39075: DBRev 24.11.09.001
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4278abd185)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:12:20 +02:00
Marcel de Rooy ddd0188cf5
Bug 39075: (QA follow-up) Use new bug number. refer to old
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0334dd9093)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:11:26 +02:00
Matt Blenkinsop d3e892fa7c
Bug 39075: Fix DB inconsistencies
This patch fixes DB inconsistencies introduced in bug 34587

Test plan:
1) Run 'updatedatabase'
2) There should be no errors
3) Check the database and observe the correct assignment of the following columns
- erm_counter_logs.importdate
- erm_counter_files.date_uploaded

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
[EDIT] chmod 755 on new dbrev
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 50ef9576d2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:11:17 +02:00
Brendan Lawlor 9f081a212d
Bug 39569: Fix branch name in alert when cancelling holds over x
To test:
1. On a bib with one item place a hold for pickup at library A and Library B
2. Check the item into library A
3. Set the first hold's expiration date to the past
4. On Holds awaiting pickup > Holds waiting past their expiration date
   In the actions column click the 'Cancel hold' button
5. Notice the alert says 'This item is on hold for pick-up at'
   with no library name
6. Apply patch and redo steps 1-4
7. Confirm the alert include's Library B's name
   This item is on hold for pick-up at Library B

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit c095e09ff9)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:09:11 +02:00
Jonathan Druart 6fb39317e7
Bug 39995: Prevent Koha/Biblio.t to fail on slow servers
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 82bd6aac35)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 16:06:05 +02:00
Baptiste b6472510cc
Bug 38841: Check non-patron guarantor while deleting patron guarantor
When editing a child while Childneedsquarantor active, trying to delete
a guarantor while saving a non-patron guarantor will prevent the user
from saving. However, if an adult has expired, some librarian would like
to remove the account and let some information in non-patron guarantor.

TEST PLAN

Before applying patch
1 - Open Lisa Charles'page, add Henry Acevedo as Guarantor, also fill
  Guarantor surname and firstname
2 - Edit the page and try and remove Henry Acevedo, it won't work
  however there is still one guarantor

3 - Apply patch
4 - Try and remove Henry Acevedo -> it will work
5 - add HA as a guarantor again
6 - try and remove him AND let guarantor firstname and surname empty ->
  you can't
7 - Add HA and Edna Acosta as guarantor
8 - Remove HA and ler guarantor firstname and surname empty -> you can

Signed-off-by: Thibault Keromnes <thibault.keromnes@univ-paris8.fr>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit e0be89266d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:53:43 +02:00
Jonathan Druart 0ca30deab0
Bug 39020: Add tests
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 5127534f5c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:52:32 +02:00
Lisette Scheer 6b75fe9034
Bug 39020: Search filters can't parse query
1. Turn on the SavedSearchFilters system preference
2. Go to advanced search, select a number of item types and search
3. Save the search
4. Enter a search term (such as power)
5. select the filter. Observe the following message:
Error: Unable to understand your search query, please rephrase and try again.
6. Apply patch
7. Repeat steps 4 & 5, search should work as expected.
8. Sign off!

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit d6c2124b29)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:51:56 +02:00
Janusz Kaczmarek f3267b81ee
Bug 38925: Update record 'date entered on file' when duplicating a record -- in advanced editor (MARC21)
With Bug 36552 we set 'date entered on file' (MARC21: 008/0-5)
of a record created by duplication of an existing record to the current
date instead of having there the value from the original record.

The same should be done for the advanced editor (for now, it retains
the date of the original record).

Test plan:
==========
1. Enable EnableAdvancedCatalogingEditor systempreference.
2. Open any record in advanced editor to make it default. Go back to
   record normal display.
3. Make a duplicate: Edit > Edit as new (duplicate)
4. Note that the date in 008/0-5 is of the original record, not of
   today.
5. Apply the patch ; restart_all.
6. Repeat p. 3. The date in 008/0-5 should be of the today. If not,
   refresh browser's cache (Ctrl+Shift+R etc.) to get the fresh
   version of the JS.

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit c0b3310ab8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:49:57 +02:00
Emily Lamancusa 23c76b43e7
Bug 39904: (QA follow-up) Fix a few other cases
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0868f260c6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:45:34 +02:00
Kyle M Hall 52eda9ba69
Bug 39904: EDIFACT error messages are malformed
Perl can interpolate hashrefs but not method calls. This results in messages like "Cannot connect to Koha::Schema::Result::VendorEdiAccount=HASH(0xaaab059252f0)->host: Name or service not known: My Test at ./misc/cronjobs/edi_cron.pl line 58." when running the edi_cron.pl cronjob.

Test Plan:
1) Enable EDIFACT
2) Create a fake EDI account with a bad FTP server in it
3) Run edi_cron.pl
4) Note the errors like:
    Cannot connect to Koha::Schema::Result::VendorEdiAccount=HASH(0xaaab059252f0)->host: Name or service not known: My Test at ./misc/cronjobs/edi_cron.pl line 58.
5) Apply this patch
6) Run edi_cron.pl
7) Note the errors are now like:
    Cannot connect to test.example.com: Name or service not known: My Test at ./misc/cronjobs/edi_cron.pl line 58.

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>
(cherry picked from commit 26e7c07302)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:40:44 +02:00
Hammat Wele 5da9ec9b27
Bug 39800: Error 500 when trying to delete patron card template
Test plan:

1. Go to Tools > Patron card creator
2. Click Manage > Card templates
3. Click Delete next to the HB-PC0001 template
--> Error 500
4. Go back to Tools > Patron card creator
5. Click Manage > Printer profiles
6. Click Delete next to the '16' printer profile
--> Error 500
7. Apply the patch
8. Repeat step 1, 2, 3
--> Card template is deleted
9. Repeat step 4, 5, 6
--> Printer profilesis deleted

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0bfad63507)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:36:48 +02:00
Owen Leonard 0973bf2537
Bug 39354: (follow-up) Override additional BS5 CSS for multiple-select
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 6c95ae68be)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:35:51 +02:00
Owen Leonard 4f9cf0d8c2
Bug 39354: Remove unintended Bootstrap 5 change to scroll-behavior
This patch updates the "variables" SCSS file in the OPAC and staff
interface in order to disable the "smooth scroll" behavior introduced in
Bootstrap 5. This was an unexpected and unintentional change.

The patch also corrects another unexpected side-effect of the BS5
upgrade: A change to the "cursor" property of elements with a
".placeholder" class. This class is used by the multiple-select jQuery
plugin found in some system preference controls.

To test, apply the patch and rebuild the staff and OPAC CSS.

- Clear your browser cache if necessary.
- In the staff interface, go to Administration -> System preferences ->
  Circulation, and click "Patron restrictions" in the left-hand sidebar.
  The page should jump immediately to that section without any scrolling
  effect.
- Go to the "Article requests" section of that page. Hover your cursor
  over a dropdown which doesn't have any option selected. Your cursor
  should not change to a "waiting" cursor.

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>
(cherry picked from commit 09c79110a1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:35:19 +02:00
Nick Clemens eae8858d51
Bug 39842: Populate current location for SIP item with holdingbranch
This patch simply adds the holdingbranch to the SIP item as current_location

To test:
1 - Find an item and check it in at a different location than its homebranch
2 - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -t CR -m item_information --item 39999000004151
3 - Note no AP field is returned
4 - Apply patch, restart all
5 - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -t CR -m item_information --item 39999000004151
6 - You see the current holdingbranch in the AP field
7 - Return the item to its homebranch
8 - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -t CR -m item_information --item 39999000004151
9 - Confirm home and holding branches are the same now

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0049543314)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:30:23 +02:00
Fridolin Somers d1eae2cec9
Bug 39733: Remove system preference delimiter mention in misc/cronjobs/staticfines.pl
Bug 27486 renamed system preference "delimiter" into "CSVDelimiter"

This patch just replaces the commented code with a TODO text

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 269ad710b2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:14:13 +02:00
Michael Skarupianski 922d644b0a
Bug 39528: Remove schema.org "Product" type from OPAC record pages
OPAC record detail pages include https://schema.org microdata information
in the HTML page markup, such as CreativeWork.

It incorrectly includes the "Product" type - this is not needed
and is also rejected by some search engines, for example
... vocab="http://schema.org/" typeof="CreativeWork Product" ...

(Koha maps schema.org to the RDFa Lite syntax https://www.w3.org/TR/rdfa-lite/)

Test plan:
1. Look at HTML source of a details page for a record in the OPAC.
2. Search for schema.org
3. Note that it there are two typeof entries:
   .. vocab="http://schema.org/" typeof="CreativeWork Product" ...
4. Apply the patch.
5. Refresh the page and look at the HTML source again.
6. Note that the "Product" schema.org type is removed:
   .. vocab="http://schema.org/" typeof="CreativeWork" ...
7. Sign off.

Sponsored-by: Karlsruhe Institute of Technology (KIT)
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>
(cherry picked from commit 4adc1a065f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:10:58 +02:00
Nick Clemens 37d3df99ca
Bug 39561: Allow users with fast_cataloging to continue after duplicate is found
This patch adds the fast_cataloging permission to those checked when a duplicate is found

Additionally, the barcode was missing from the duplicate check and is now added to be passed forward

To test:
 1 - Create or choose a borrower and grant permissions:
     catalogue
     circulate
     borrowers: list_borrowers
     editcatalogue: fast_cataloguing
 2 - Log in as that patron
 3 - Search for another borrower and go to checkout screen
 4 - Enter random string as barcode to checkout
 5 - Item is not found, click to fast catalogue
 6 - In the editor type into 245$a 'Perl best practices' - or another title that exists in your system
 7 - Get a notice of duplicate with options:
     Yes: View existing items
     No, save as new record
 8 - Clicking 'Yes' will take you to the record details page - you cannot add an item because record is not FA framework
 9 - You can click 'back' to return to the messages
10 - Clicking 'No' will create a new record and take you to the details page - you can add an item (Edit->manage items)
     but barcode has been dropped
11 - Apply patch
12 - Repeate 3-6
13 - You now get options:
     Yes: View existing items (you cannot add items to an existing record)
     No, save as new record
14 - 'Yes' will take you to details view
15 - Click back
16 - 'No' will take you to the edit items screen and populate the barcode
17 - Saving the item should return you to patron and issue item
18 - Repeat again with a staff patron with full permissions and confirm saying 'Yes' completes the fast catalogin workflow as expected

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 6812b170a6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2025-10-03 15:08:49 +02:00