Commit Graph

6499 Commits

Author SHA1 Message Date
Emily Lamancusa a8c8152b98
Bug 36114: Adjust TRANSFERSLIP to use Template Toolkit
To test:
1. Apply patch
2. reset_all (or start your testing environment in the first place)
3. Find or create an item that belongs to a library other than the logged-in library
4. Make sure the item has a callnumber (edit it to add one if needed)
4. Check the item in to generate a transfer slip
--> Confirm the information is all filled in correctly on the slip

Signed-off-by: Marion Durand <marion.durand@biblibre.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit dcdb8b058c)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:38 +02:00
Paul Derscheid 82ac526335
Bug 35467: DBRev 25.05.03.007
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:29 +02:00
Andrew Fuerste Henry 552a88df61
Bug 35467: atomicupdate to rename NewsLog to AdditionalContentLog
Now executable!

Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 665753634b)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:28 +02:00
Andrew Fuerste Henry 6e3fba0778
Bug 35467: atomicupdate to change NewsLog to AdditionalContentLog
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 420add2908)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:28 +02:00
Andrew Fuerste Henry 0d5a1e2541
Bug 35467: Rename NewsLog system preference to AdditionalContent
To test:
1 - confirm whether or not NewsLog is enabled on your system
2 - apply patch, updatedatabase, restart_all
3 - search system preferences, confirm you now have
    AdditionalContentLog rather than NewsLog and that the new
    description is accurate
4 - confitm AdditionalContentLog shows the value you previously had for
    NewsLog
5 - go to Tools > Log Viewer
6 - confirm the checkbox here is labeled "Additional Content", that it
    correctly reflects the syspref value, and that it links to the
    syspref
7 - with AdditionalContentLog enabled, created/edit/delete news, HTML
    customizations, and pages. confirm they log
8 - with AdditionalContentLog disabled, created/edit/delete news, HTML
    customizations, and pages. confirm they don't log

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 9805b4cb3e)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:27 +02:00
Paul Derscheid 3b724c5edb
Bug 34561: DBRev 25.05.03.006
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:26 +02:00
Lisette Scheer b77389b396
Bug 34561: (QA follow-up) Rename to StaffReportsHome to match othe html customizations
I noticed the rest of the html customizations don't have html in the option name, so I renamed for consistency.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit c1a1b85c87)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:26 +02:00
Owen Leonard b1be1478ec
Bug 34561: Move IntranetReportsHomeHTML to HTML customizations
This patch moves the IntranetReportsHomeHTML system preference into
HTML customizations, making it possible to have language- and
library-specific content.

To test you should have some content in the IntranetReportsHomeHTML
system preference before applying the patch. Apply the patch and run the
database update process.

- In the staff client, go to Tools -> HTML customizations and verify
  that the content from IntranetReportsHomeHTML is now stored there.
- The HTML customization entry form should offer
  IntranetReportsHomeHTML as a choice under "Display location."
- Update and reinstall active translations (for instance fr-FR):
  - perl misc/translator/translate update fr-FR
  - perl misc/translator/translate install fr-FR
- Enable the translation if necessary under Administration -> System
  preferences -> language.
- Edit the IntranetReportsHomeHTML HTML customization and add unique
  content to the "fr-FR" tab.

- Go to the reports home page. You should see the
  content you added to the IntranetReportsHomeHTML HTML
  customization.
- Switch to your updated translation and confirm that the content you
  added for your translation shows up correctly.
- Go to Administration -> System preferences and search for
  "IntranetReportsHomeHTML." It should return no results.

Sponsored-by: Athens County Public Libraries
Signed-off-by: Ray Delahunty <lib-systems@arts.ac.uk>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 20caaf611a)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:42:21 +02:00
Paul Derscheid a52239172b
Bug 40305: DBRev 25.05.03.005
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:25 +02:00
Martin Renvoize 4e596b8fff
Bug 40305: Add database update to fix existing notice templates
This database update fixes existing RECEIPT and ACCOUNT_CREDIT notice
templates that may still use the old 'collected' variable instead of
'tendered'. It handles various formatting patterns and provides
verification that the conversion was successful.

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 4b300b1c1d)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:24 +02:00
Martin Renvoize 86b3f2f08e
Bug 40305: Fix 'tendered' vs 'collected' variable name inconsistency
"One Ring to rule them all, one Ring to find them, One Ring to bring
them all and in the darkness bind them"

We've been battling against this for years, with a mixed use of
terminology and thus confusion in templates vs controllers and notice
templates.  I've decided to just try and make sure all the terminology
matches throughout, and use the more popular 'tendered' term over the
'collected' term.

This patch standardizes the terminology used throughout the payment
  system to consistently use 'tendered' instead of the mixed usage of
  'collected' and 'tendered' that has caused confusion over the years.

Changes include:
  - Update all payment form templates to use 'tendered' input names
  - Update JavaScript validation and change calculation logic
  - Update controller parameter handling in pos/pay.pl, pos/printreceipt.pl,
    and members/paycollect.pl
  - Update sample notice templates (RECEIPT) to use 'tendered' variable
  - Add null check for $total_tendered to prevent perl warnings

Test plan:
  1. Test Point of Sale payments with tendered amounts and change calculation
  2. Test member account payments with tendered amounts
  3. Test receipt generation (both print and email)
  4. Verify JavaScript validation works correctly
  5. Confirm no perl warnings when tendered amount is undefined

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 f91310306c)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:24 +02:00
Paul Derscheid ff135b5110
Bug 36561: DBRev 25.05.03.004
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:23 +02:00
David Cook 9c4319d2cf
Bug 36561: Add new permission `api_validate_password`
This change adds a `api_validate_password` permission which allows a user to only
validate borrowers by using the /api/v1/auth/password/validation endpoint.

This avoids scenarios where you want third-parties to authenticate a user without
giving them full permissions to perform CRUD operations on user data.

To test:
1. Apply patch
2. Run "koha-upgrade-schema kohadev"
3. koha-plack --reload kohadev
4. prove -v t/db_dependent/api/v1/password_validation.t
5. Visit http://localhost:8081/cgi-bin/koha/members/member-flags.pl?member=51
6. Note that a new subpermission `api_validate_password` appears under the "borrowers" permission

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 79c1853b2b)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:22 +02:00
Paul Derscheid c882d58649
Bug 37883: DBRev 25.05.03.003
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:22 +02:00
Lucas Gass c7d5bad5c1
Bug 37883: Correct permissions of atomicupdate file
Signed-off-by: Laura_Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 4db82a99d0)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:20 +02:00
Lucas Gass 2ac88f0609
Bug 37883: Add FilterSearchResultsByLoggedInBranch system preference
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Laura_Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 764273befe)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:11 +02:00
Paul Derscheid be4add9121
Bug 40405: DBRev 25.05.03.002
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:09 +02:00
Jonathan Druart 9df90e7c64
Bug 40405: And ILLOpacUnauthenticatedRequest
No idea why it was not NULL in DB when I did my first SELECT

Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit fe14f8b7c6)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:09 +02:00
Jonathan Druart baf8af8c99
Bug 40405: Set systempreferences.value to NOT NULL
Some sysprefs have NULL as their default value, and systempreferences.value allows NULL values.

However C4::Context->set_preference does not unset a syspref if "undef" is passed.

Additionally some of the sysprefs that have NULL as default will generate warnings in the logs (and test suite output).

opac/opac-suggestions.pl:        for my $f ( split( /\s*\,\s*/, C4::Context->preference("OPACSuggestionUnwantedFields") ) ) {

Here is the current list:
+-------------------------------+-------+
| variable                      | value |
+-------------------------------+-------+
| decreaseLoanHighHoldsDuration | NULL  |
| decreaseLoanHighHoldsValue    | NULL  |
| ILLHiddenRequestStatuses      | NULL  |
| ILLOpacbackends               | NULL  |
| ILLSendStaffNotices           | NULL  |
| ListOwnerDesignated           | NULL  |
| MarcFieldDocURL               | NULL  |
| MaxFine                       | NULL  |
| OPACSuggestionUnwantedFields  | NULL  |
| ReportsExportLimit            | NULL  |
| SerialsSearchResultsLimit     | NULL  |
+-------------------------------+-------+

Test plan:
Code review required here, please confirm the above and that the
different occurrences do not use "undef" as a value.

Note that some tests now do not longer generate warnings
(eg. t/db_dependent/selenium/opac_ill_requests.t)

Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit a3b4b5cdd0)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:08 +02:00
Paul Derscheid a2bc913de0
Bug 23010: DBRev 25.05.03.001
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:08 +02:00
Emily Lamancusa 24dab792e3
Bug 23010: (QA follow-up) a few trivial fixes
- Update the dbrev to use say_success, and make dbrev and installer
  consistent
- Change error div in moredetail.tt from info to warning

Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 3096833130)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:07 +02:00
Lucas Gass af9615f3d9
Bug 23010: Update pref name to PreventWithdrawingItemsStatus
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit c4acafe29b)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:04 +02:00
Lucas Gass 22b32b2814
Bug 23010: Fix file permission of atomicupdate
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit e5da98c353)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:02:04 +02:00
Lucas Gass db1bca48e6
Bug 23010: Add system preference PreventWithdrawingItemsStatus
To test:

1. APPLY PATCH, updatedatabase, and restart_all
2. Search for the system preference, PreventWithDrawingItemsStatus
3. Select both in transit and checked out, then save
4. Find an item and put it in transit.
5. Now from the item detail page, go to manage items > edit item
6. Using the item that was put in transit, attempt to change the status to withdrawn.
7. You should see an error at the top of the page 'In transit item cannot be withdrawn.' Make sure the item did not get marked as withdrawn.
8. Using a different item, do a checkout
9. Now from the item detail page, go to manage items > edit item
10. Using the checked out item, attempt to change the status to withdrawn.
11. vYou should see an error at the top of the page 'Onloan item cannot be withdrawn.' Make sure the item did not get marked as withdrawn.

12. Now, using the in transit item, go to the items tab. ( catalogue/moredetail.pl?biblionumber=x )
13. Under Statuses, attempt to withdraw the item.
14. You should see an error near the top of the page "Cannot withdraw item in transit".
15. Now, using the checked out item, go to the items tab. ( catalogue/moredetail.pl?biblionumber=144 )
16. Under Statuses, attempt to withdraw the item.
17. You should see an error near the top of the page "Cannot withdraw checked out item.".

18. Using both the in-transit and checked out item, attempt to modify the status through batchMod.
19. Ensure that the items are not being updated to withdrawn.

20. Turn off PreventWithDrawingItemsStatus system preferece.
21. Going through each of the steps again, except this time your items should successfully withdraw.

prove t/db_dependent/Koha/Item.t

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 4e920be91f)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-16 14:01:58 +02:00
Paul Derscheid a7d9b27728
Increment version for 25.05.03 release
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-26 21:47:58 +02:00
Emily Lamancusa 7be30834a2
Bug 36127: Adjust default HOLDPLACED and HOLD_CHANGED notices to use TT
To test:
1. Apply patch
2. reset_all (or start your testing environment in the first place)
3. Edit system preferences:
     emailLibrarianWhenHoldIsPlaced - Enable
     ReplyToDefault - enter a fake/test email address
     ExpireReservesMaxPickupDelay - Allow
     ExpireReservesAutoFill - Do
     ExpireReservesAutoFillEmail - same email address as ReplyToDefault
4. Place two holds on the same bib for two different patrons, Patron A
   and Patron B
5. Edit an item on that bib to set a call number (if it doesn't have one
   already)
6. Check in that item to set Patron A's hold to waiting
7. Edit the expiration date on Patron A's hold to yesterday's date
   To do this in KTD:
     ktd --shell
     koha-mysql kohadev
     UPDATE reserves SET expirationdate = <yesterday's date>
     WHERE borrowernumber = <Patron A's borrowernumber>;
8. Run misc/cronjobs/holds/cancel_expired_holds.pl to automatically
   cancel the expired hold and fill the next one
9. Open koha-mysql again and run the following query to view the
   generated notices:
   SELECT subject, content FROM message_queue
   WHERE to_address = '<the email address you set in step 3>';
--> Confirm that HOLDPLACED and HOLD_CHANGED notices were both generated
--> Confirm that all information has been filled in correctly for those
    notices

Signed-off-by: Marion Durand <marion.durand@biblibre.com>
Signed-off-by: Lisette Scheer <lisette@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit f869d42807)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-22 09:48:39 +02:00
Jonathan Druart cb504d5cc7
Bug 40541: Add missing new line at the end of files when missing
We have insert_final_newline = true to ensure files will contain a new
line at the end. However we have seen commits with "No new line" added
in the git log.

We should have a xt test to prevent more occurrences.

We should also have a test at the QA script level:
https://gitlab.com/koha-community/qa-test-tools/-/issues/96

Test plan:
  prove xt/find-missing-new-lines-at-the-end-of-file.t
should return green.

Remove the new line at the end of a file, eg.
vim -b mainpage.pl
:set noeol
:wq

Now
  prove xt/find-missing-new-lines-at-the-end-of-file.t
is failing on mainpage.pl.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit e9eb20249e)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-22 09:48:20 +02:00
Caroline Cyr La Rose 535b6cc9b9
Bug 40414: Update patron card layout with expiry date
This patch updates the default patron card layout to replace "Expires:
August 31, 2010" with the patron's account expiry date.

To test:
1. Apply patch and reset_all
2. Go to Tools > Patron card creator
3. Click New > Card batch
4. In Add by borrowernumber(s), enter borrowernumbers 1 to 6, one per line
5. Click Add patron(s)
6. Click Export card batch
7. Click Export
8. Open the PDF
   --> Note that the patron's account expiry date is printed on the card

Optional : Change the expiry date of one or more patrons and redo steps 6-8.
--> The updated expiry dates should be printed on the cards.

Signed-off-by: Eric Garcia <cubingguy714@gmail.com>
Signed-off-by: Laura_Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 3e95c21d85)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-22 09:48:16 +02:00
Courtney Brown b65e193871
Bug 39279: Update the wording for the overdue notice - branch to library
This patch updates the terminology used in the overdue notice (ODUE)
to change 'branch' to 'library'.

Test plan:
1. Check the wording of the ODUE notice under Tools > Patrons and
   circulation > Notices and slips.
2. Note that it includes this wording that uses 'branch':
   "Please return or renew them at the branch below as soon as possible."
3. Apply the patch.
4. Check that the updated ODUE notice has changed 'branch' to 'library'
   by either:
   4.1 Resetting everything: reset_all
   4.2 Viewing the default notice - click "View default" when viewing
       the email notice
   The updated text is now: "Please return or renew your overdue items
   at the library as soon as possible."
5. Sign off.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Laura_Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 4bd1bc0a6f)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-22 09:48:11 +02:00
Jonathan Druart c60f0bfe85
Bug 40548: (bug 40337 follow-up): Fix DB comparison
00:40:25 koha-1       | <   `checkprevcheckout` enum('yes', 'no', 'inherit') NOT NULL DEFAULT 'inherit' COMMENT 'produce a warning for this patron if this item has previously been checked out to this patron if ''yes'', not if ''no'', defer to category setting if ''inherit''.',
00:40:25 koha-1       | ---
00:40:25 koha-1       | >   `checkprevcheckout` enum('yes','no','inherit') NOT NULL DEFAULT 'inherit' COMMENT 'produce a warning for this patron if this item has previously been checked out to this patron if ''yes'', not if ''no'', defer to category setting if ''inherit''.',
00:40:25 koha-1       | ERROR - DB structures are not identical
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit ffd7a4ec10)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-01 11:21:26 +02:00
Jonathan Druart 8dbd12aa16
Bug 40337: Remove test of datatype
Keep the UPDATE to adjust bad data however.

Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-01 11:21:25 +02:00
Martin Renvoize 8bdbbd74b8
Bug 40337: (QA follow-up) Make database update idempotent
Running this update twice fails before this patch with:

ERROR: {UNKNOWN}: DBI Exception: DBD::mysql::db do failed: Data truncated for column 'checkprevcheckout' at row 3 at /kohadevbox/koha/C4/Installer.pm line 825

Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-08-01 11:21:20 +02:00
Paul Derscheid a643bfb030
Increment version for 25.05.02 release
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-07-24 22:49:30 +02:00
Paul Derscheid 897e65fe8a
Bug 36947: DBRev 25.05.01.002
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-07-24 10:23:45 +02:00
Martin Renvoize 53488ff01c
Bug 36947: Add system preference for configurable locale-based facet sorting
This follow-up adds two major enhancements to the locale-based facet sorting
implementation:

1. **System Preference Integration**
   - Adds FacetSortingLocale system preference for configurable locale selection
   - Dynamically detects available system locales using Koha::I18N
   - Provides user-friendly dropdown with locale descriptions
   - Supports both Elasticsearch and Zebra search engines

2. **Zebra Search Engine Support**
   - Extends locale-based sorting to Zebra (in addition to existing Elasticsearch)
   - Implements _sort_facets_zebra() function in C4::Search
   - Maintains consistent Unicode-aware sorting behavior across search engines

Key Features:
- Dynamic locale detection via Koha::I18N::available_locales()
- Proper module architecture with comprehensive unit tests
- Clean fallback chain: preference → system LC_COLLATE → default
- Admin UI integration in System Preferences → I18N/L10N
- Universal facet sorting for international library systems

Test plan:
1. Apply patch and restart services
2. Install/run database update
3. Navigate to Administration → System Preferences → I18N/L10N
4. Verify "Sort facet names using" dropdown shows available system locales
5. Test facet sorting with different locales and both search engines
6. Run: prove t/Koha/I18N.t t/Koha/SearchEngine/Elasticsearch/Search.t t/db_dependent/Search_FacetSorting.t

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 146aca25f5)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-07-24 10:23:42 +02:00
Fridolin Somers f9f86d4c12
Bug 40160: Use HTTPS for links to community websites
Some web-browsers now only allow HTTPS, we should change links in
templates with SSL :
https://schema.koha-community.org, https://wiki.koha-community.org ...

Test plan :
Just look patch to check http > https

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 2f864811ef)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-07-24 10:23:13 +02:00
Paul Derscheid c34f53df6c
Bug 40337: DBRev 25.05.01.001
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-07-10 22:47:44 +02:00
Jonathan Druart c171f218ac
Bug 40337: Define checkprevcheckout as ENUM
On bug 40178 and bug 40179 we defined checkprevcheckout attributes as
ENUM at the REST API level, so the specs prevent us from inserting
values that are no yes, no, inherit in DB.
However the DB schema didn't have that constraint.
This has been caught by some tests that were failing:
eg. t/db_dependent/selenium/patrons_search.t with "Not in enum list: yes, no, inherit."

Test plan:
Apply this patch, run `updatedatabase`, `dbic` and `restart_all`
`prove t/db_dependent/selenium/patrons_search.t` should now pass.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 3c3cc6622c)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-07-10 22:47:43 +02:00
Paul Derscheid 636e3ffe32
Increment version for 25.05.01 release
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-06-24 18:38:09 +02:00
Emily Lamancusa 87e81b5826
Bug 36020: (QA follow-up) A few minor corrections
Remove unneeded <br> in RECALL_REQUESTER_DET

Add IFs to RECALL_REQUESTER_DET to avoid displaying empty lines if
there is no phone, email, and/or callnumber to display

Use checkout.date_due instead of item.onloan due to bug 39985

Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit d4450cdd5f)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-06-24 11:30:05 +02:00
Lisette Scheer 64e37b6e1f
Bug 36020: Port default recall notices to Template Toolkit
The following notices relating to recalls all need to be updated to use Template Toolkit syntax:

RETURN_RECALLED_ITEM
PICKUP_RECALLED_ITEM
RECALL_REQUESTER_DET

To test:
1) Observe the default notice contains <<>> tags
2) Apply the patch
3) reset_all
4) Check that the notice is now all in template toolkit [%  %] tags with html selected
5) Enable recalls
6) Enable SMS
7) Check an item out to a patron
8) Make sure the patron has a primary email, sms, and recall notices enabled
9) Make sure a secondary patron has a primary email, sms, and recall notices enabled
10) Generate a recall on the checked out item for the second patron
11) Check the first patron's notices tab to confirm the return recalled item notice generated properly.
12) Check the item back in and generate the recall slip and confirm it generated correctly.
13) Check the second patron's notices tab to confirm the pickup recalled item notice generated properly.

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 98c0cf2648)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-06-24 11:30:05 +02:00
Pedro Amorim 5eb5d33f2f
Bug 40057: Fix db revision
Test plan (ktd):
1) reset_all
2) Run first part of the 241200017.pl atomicupdate manually
	koha-mysql kohadev
	ALTER TABLE illrequests DROP FOREIGN KEY illrequests_bnfk;
3) Create an ILL request linked to a borrower that doesn't exist (simulate old data):
	INSERT INTO illrequests (`backend`, `borrowernumber`,`branchcode` ) VALUES ('Standard', '99999', 'CPL');
4) Run the 2nd part of the atomicupdate manually:
   ALTER TABLE illrequests ADD CONSTRAINT illrequests_bnfk FOREIGN KEY(`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE;
5) Notice you get the error:
	ERROR 1452 (23000): Cannot add or update a child row: a foreign key constraint fails (., CONSTRAINT  FOREIGN KEY () REFERENCES  () ON DELETE SET NULL ON UPDATE CASCADE)
6) Run the added query in the patch:
	UPDATE illrequests SET borrowernumber = NULL WHERE borrowernumber NOT IN (SELECT borrowernumber FROM borrowers);
7) Repeat step 4)
8) Notice there's no errors

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 94d5c37db8)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-06-22 23:48:32 +02:00
Katrin Fischer ae5fde9586
Koha 25.05.00 is here!
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-26 18:45:50 +02:00
Katrin Fischer 80464afe8a
25.05.05: Update kohastructure.sql
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-26 18:45:49 +02:00
Katrin Fischer d7af2cacff
Bug 26869: (QA follow-up) Fix missed sysprefs.sql
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-20 15:15:34 +02:00
Matthias Meusburger f51ec30438
Bug 38142: (follow-up) Choose language to report from authority to bibliographic record
- Rename LanguageToReportOnMerge system preference to LanguageToUseOnMerge
 - Use "use" instead of "report" in system preference description
 - Mark this feature as UNIMARC-only.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-20 15:15:33 +02:00
Katrin Fischer d17f6552a1
Bug 30301: DBRev 24.12.00.046
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-19 18:54:34 +02:00
Matt Blenkinsop c882117b95
Bug 30301: Add a new column to enforce the expiry notice
Signed-off-by: Hanna Leiker <tech.hanna@salinapublic.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-19 18:54:29 +02:00
Jonathan Druart 244ce5396b
Bug 38457: (follow-up) Update record_id to VARCHAR(80)
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-19 09:49:43 +02:00
Caroline Cyr La Rose 54abc78b72
Bug 36256: Port default MEMBERSHIP_EXPIRY notice to Template Toolkit syntax
This patch changes the sample MEMBERSHIP_EXPIRY email notice to Template
Toolkit syntax.

To test:
1. Apply patch and reset_all
2. Go to Tools > Notices and slips
3. Check the MEMBERSHIP_EXPIRY email notice, make sure everything looks good (TT syntax, grammar and spelling OK)
4. Add a value in MembershipExpiryDaysNotice
5. Change a patron's account so that it expires in the number of days in MembershipExpiryDaysNotice
6. Add an email address in the patron's account
7. Run /misc/cronjobs/membership_expiry.pl -c
8. Go to the patron's notices and check that the text of the notice was generated correctly and that the grammar and spelling are OK

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-05-16 14:25:50 +02:00