Commit Graph

58581 Commits

Author SHA1 Message Date
Pedro Amorim 61f088dfc1
Bug 38819: Auto switch: Breadcrumbs+header titles
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:46 +02:00
Pedro Amorim 36e0a0d51b
Bug 38819: Auto migrate controller logic
Test plan, k-t-d:
0) Install the 'PluginBackend' plugin:
https://github.com/PTFS-Europe/koha-ill-backend-plugin/releases/tag/v2.0.6
1) Enable ILLModule syspref and check the "PluginBackend" backend in AutoILLBackendPriority:
http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=interlibrary_loans
2) Create a new 'auto' ILL request:
http://localhost:8081/cgi-bin/koha/ill/ill-requests.pl?method=create&backend=Standard
3) Select type 'journal article', add '123' as DOI, '42' as cardnumber and any library
4) You should be on the automatic backend screen. The PluginBackend has a 50% chance to return available, so this step may suggest PluginBackend or Standard. Pick whatever was suggested. Click 'confirm'.
5) You are now on the request detail page. Click "Switch provider". You should be back on the automatic backend screen.
Repeat this step as many times needed to switch from Standard <-> PluginBackend multiple times. Ensure it always succeeds.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:45 +02:00
Matt Blenkinsop 2186bf7fa8
Bug 39530: Make MARC order cronjob dependent on AcqCreateitems
Test plan:
1) View the patch diff and confirm that the hardcoded value of 'ordering' has been replaced with undef
2) In C4/Acquisition.pm, look at the method description for ModBasketHeader and observe the descritpion for 'create_items'
3) Note that if the value is set to undef as per step 1, the AcqCreateItem syspref takes precedence

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:45 +02:00
Katrin Fischer 7209d60824
Bug 33473: DBRev 24.12.00.031
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:44 +02:00
Katrin Fischer 5be7a215a6
Bug 33473: (QA follow-up) Fix alphabetic ordering of sysprefs.sql
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:44 +02:00
PerplexedTheta 1fb771c2a1
Bug 33473: Rename UseEmailReceipts to AutomaticEmailReceipts
This bug will rename the UseEmailReceipts to AutomaticEmailReceipts, to
make it clearer the purpose of this syspref. This is because the receipts
dropdown is no longer conditional, and will always show, even if
AutomaticEmailReceipts is switched off.

To test (steps a-e before applying patch):
a)  search sysprefs for 'EmailReceipts'
    1)  note the name is currently 'UseEmailReceipts'
    2)  enable this syspref
b)  go to members/maninvoice.pl?borrowernumber=51
    1)  enter an amount (e.g. 100)
    2)  save & pay, confirm
c)  go to members/boraccount.pl?borrowernumber=51
    1)  note that the receipt dropdown is visible
d)  go to members/notices.pl?borrowernumber=51
    1)  note that a receipt was automatically sent
e)  apply the patch, upgrade the db schema
f)  search sysprefs for 'EmailReceipts'
    1)  note the name is now 'AutomaticEmailReceipts'
g)  go to members/maninvoice.pl?borrowernumber=51
    1)  enter an amount (e.g. 100)
    2)  save & pay, confirm
h)  go to members/boraccount.pl?borrowernumber=51
    1)  note that the receipt dropdown is no longer visible
i)  go to members/notices.pl?borrowernumber=51
    1)  note that a receipt was automatically sent again
j)  disable the 'AutomaticEmailReceipts' syspref
k)  go to members/memberentry.pl?op=edit_form&destination=circ&borrowernumber=19
    1)  add a valid email address
k)  go to members/maninvoice.pl?borrowernumber=51
    1)  enter an amount (e.g. 100)
    2)  save & pay, confirm
l)  go to members/boraccount.pl?borrowernumber=51
    1)  note that the receipt dropdown is now visible
m)  go to members/notices.pl?borrowernumber=51
    1)  note that a receipt was NOT automatically sent
n)  go to members/boraccount.pl?borrowernumber=51
    1)  on any account line where a payment is made, click receipts > email
o)  go to members/notices.pl?borrowernumber=51
    1)  confirm a manual notice has been generated
p)  make coffee & have a mini disco

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:43 +02:00
Katrin Fischer 28a5e6545d
Bug 38694: DBRev 24.12.00.030
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:43 +02:00
Thomas Klausner 6ac7938293
Bug 38694: (follow-up) Rename syspref from ESBoostFieldMatch to ElasticsearchBoostFieldMatch
to keep the syspref names consistent with the existings values. Also "ES" is not as self-documenting as "Elasticsearch".

No code change, so the test plan stays the same.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:42 +02:00
Nick Clemens 77e0399811
Bug 38694: Unit tests
Adjust existing and add new

Signed-off-by: Matthias Meusburger <matthias.meusburger@biblibre.com>
Signed-off-by: Thomas Klausner <domm@plix.at>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:42 +02:00
Nick Clemens 1aca9ec140
Bug 38694: Add ESBoostFieldMatch option to Elasticsearch
What this patch does is:
1 - Wraps the existing search code in a a "bool" compound query as a "must". This should not affect
    relevancy or results of the existing searches.
2 - Before we clean/truncate terms, loop through the passed in search terms and indexes to build a
    new 'should' query, using the 'match' on the specified index/field that is added to the 'bool' query from above.
    This means that if a result from the original query is also returned here, that item will be boosted in the result.
    For searches on 'keyword' or 'title', or if no index is set, we use 'title-cover' as the most narrow form of title

This query isn't going to help when users enter CCL (i.e. ti:To die for) and it won't boost titles from 505, series, etc
when doing a general search. Nor will it have a detrimental effect, it will only boost field matches

To test:
1 - Add a record with
    245 $a novel
2 - Add a record with
    245 $a A novel : $b about things / $c by me
3 - Search for: novel
    - Above records are returned lower in the list (results #6 and #14 for me)
4 - Search for: a novel
    - Above records are returned lower in the list (results #6 and #14 for me)
5 - Apply patch, restart all, enable ESBoostFieldMatch option
6 - Repeat searches, note exact titles are boosted
    - For 'novel' record from #1 is #1 result and other is second
    - For 'a novel' record form #2 is #1 result and other is third
7 - Disable the new pref and repeat steps 3 and 4 and get results as before patch
8 - Experiment with other searches, turning pref on and off to verify relevant titles are boosted when enabled
9 - Search results when disabled should return as before the patch

Signed-off-by: Matthias Meusburger <matthias.meusburger@biblibre.com>
Signed-off-by: Thomas Klausner <domm@plix.at>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:41 +02:00
Paul Derscheid d7265ddd7f
Bug 36275: (follow-up) Only show tooltip on successful copy
Question is whether we should display anything on the failure case as well?

Test plan stays the same.

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:40 +02:00
Owen Leonard a43ac27381
Bug 36275: (follow-up) Add tooltip feedback
This patch adds some code to the copytoClipBoard function so that it
triggers a Bootstrap tooltip with the text "Copied to clipboard",
providing feedback to the user that something has happened.

The tooltip self-destructs after a few seconds.

Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:40 +02:00
Paul Derscheid 84a49dbcbb
Bug 36275: The displayed values for Client ID and Secret need copy to clipboard buttons in apikeys.tt
This patch adds:
- A new include with a prepared button that sets the passed
  copy_to_clipboard_value as the data-value attribute.
- A script, which is an IIFE that can also be used elsewhere that then
  adds event listeners for clicks on the above buttons (or other buttons
  with data-copy-to-clipboard)
- The included buttons and the associated js to apikeys.tt.

To test:
1) Activate the  RESTOAuth2ClientCredentials syspref.
2) Search for a patron, e.g. 42
3) Go to more -> Manage API keys
4) Generate a new client id/key pair
5) Notice that there are copy to clipboard buttons next to the client id
   and secret
6) Click one of them
7) Paste your clipboard into the top search input for example
8) Verify it works and the value is identical to the value you copied
9) Sign off

https://bugs.koha-community.org/show_bug.cgi?id=36275
Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:39 +02:00
nina martinez 91a934fbdf
Bug 39356: Change heading ranks when ranks are skipped
Test plan:

1- Check all headings on the pages (you can use tools like HeadingsMap)
2- Verify that no heading ranks are skipped
3- If it's the case, the test succeeds

Pages to check:
- opac-main.pl
- opac-curbside-pickups.pl
- opac-memberentry.pl
- opac-recalls.pl
- opac-user.pl
- opac-details.pl (shelf browser, the modal that open after a click on
  "Cite" in the sidebar)

Signed-off-by: Emmanuel Bétemps <e.betemps@gmail.com>
Signed-off-by: Andrew Auld <andrew.auld@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:39 +02:00
Katrin Fischer ccebc42872
Bug 38142: DBRev 24.12.00.029
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:38 +02:00
Matthias Meusburger 4dd5b2a891
Bug 38142: Choose language to report from authority to bibliographic record.
Currently, when reporting authority field to the bibliographic records,
the merge function uses the first matching authority field.

However, authorities can provide multiple versions of the same field, with
different languages, identified by a code in the $7 field.

French reference for languages codes for example, but any code system could be
used:
https://documentation.abes.fr/sudoc/formats/unmb/DonneesCodees/CodesZone104.htm#$d

This patch introduces the LanguageToReportOnMerge system preference, which
allows to specify a language code.

When set, if there is an authority field with the given language code, it will
be used to report to the bibliographic record.

If the system preference is not set, or there is no matching field, the default
behavior will apply: the first field will be used.

The $7 in the authority field can be in a short or long form:

 - the short form is 2 characters long. Example: ba
 - the long form is 8 characters long, with the short form in position 5 and 6
   (starting from 1). Example: ba0yba0y

Test plan:
----------

1) Edit the 'Personal Name' authority type framework to make the 100 field
repeatable

2) Add an authority with several languages, like this (the order is important):

100    _7ba0yda0y
       _a伊東豊雄
100    _7ba0yba0y
       _aItō

3) Add a bibliographic record linked to that authority.
(Click on the "tag editor" icon next to the 100$a field in the bibliographic record to
 search for the authority, then Search main heading ($a only): contains Itō)

Note that you can choose which version you want when searching for the
authority, under the "Get it!" column

For this example, choose the latin version: Itō

You should now have this in your bibliographic record:
100    _aItō
       _92646

4) Edit the authority, you don't have to change anything, just edit and save.
Note that your bibliographic record now looks like this:

100    _7ba0yda0y
       _a伊東豊雄
       _92646

The first 100 field of the authority has been reported back to the bibliographic
record, regardless of what you chose when selecting the authority.

5) Apply the patch, set the LanguageToReportOnMerge system preference to: 'ba'

6) Edit the authority again, and check that your bibliographic record now looks
like this, according to the system preference:

100    _7ba0yba0y
       _aItō
       _92646

7) Edit the authority again, but set the $7 of the latin field to its short
form:

100    _7ba0yda0y
       _a伊東豊雄
100    _7ba
       _aItō

8) Check that the bibliographic record still has the latin field reported:

100    _7ba
       _aItō
       _92646

9) prove koha/t/db_dependent/Authority/Merge.t

10) Sign-off :)

Sponsored-by: ENSA

Works smoothly, both with UNIMARC/MARC21
Signed-off-by: Frédéric Demians <f.demians@tamil.fr>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:38 +02:00
Brendan Lawlor d8fd987851
Bug 37860: Add Main contact method to Holds awaiting pickup table
This patch adds the main contact method to the patron column of the
Holds awaiting pickup table. The style is intended to match the
modal on the hold found modal.

To test:
1. Apply patch and run yarn build && restart_all
2. Place a hold for a patron and check in the item
3. Notice the modal displays the main contact method in a yellow box
4. Go to Circulation > Holds awaiting pickup
5. Notice the main contact method displays in the Patron column in the same style

Signed-off-by: Shi Yao Wang <shi-yao.wang@inlibro.com>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-25 08:46:37 +02:00
Nick Clemens e744f001ae
Bug 39652: (QA follow-up) Update misc/maintenance/pseudonymize_statistics.pl
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:17 +02:00
Pedro Amorim 54205bd6ba
Bug 39652: Rename new_from_statistic
This new method name better reflects the fact that it now creates - and stores - the PseudonymizedTransaction object

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:17 +02:00
Pedro Amorim f23632a352
Bug 39652: store PseudonymizedTransaction before adding related entries
Test plan:
Run the tests before and after applying this patch:
perl t/db_dependent/Koha/Pseudonymization.t

They should fail before this patch and pass after applying patch.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:16 +02:00
Pedro Amorim bdb428978f
Bug 39652: Add tests
These tests prove the bug:
perl t/db_dependent/Koha/Pseudonymization.t

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:16 +02:00
Tomas Cohen Arazi 5b61784138
Bug 39619: Fix typo in mappings.tt
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:15 +02:00
Nick Clemens 85003674ad
Bug 39717: Use numeric comparison for stock rotation stages
To test:
 1 - Enable SotckRotation
     http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=StockRotation
 2 - Browse to "Cataloging -> StockRotation"
 3 - 'New rota' - fill out the form and save
 4 - Manage->stages
 5 - Add many stages, more than 10 at least
 6 - Try to move a stage form the bottom to position 3
 7 - Note message above list: Saving changes... Error: Bad Request
 8 - Apply patch, restart_all
 9 - Attempt to move stages, try many combinations
10 - Success!

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:15 +02:00
Katrin Fischer 07ae4d883b
Bug 37934: DBIC schema update
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:14 +02:00
Katrin Fischer 8dbe0438c3
Bug 39062: DBIC schema update
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-24 19:53:14 +02:00
Owen Leonard 18d9297bda
Bug 25947: (follow-up) Tidiness fix
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:22 +02:00
Baptiste Wojtkowski 20a87564f1
Bug 25947: (follow-up) Improve locked account message
Test plan:

To test:
1. Change system preference 'FailedLoginAttempts' to a small number,
   like 2
2. Go to a patron's account and copy their username (while you're there,
   change the password and add some fines, too)
3. In the OPAC, try to log in with the username and a wrong password 3
   times
4. Go back to the patron's account in the staff interface
5. Note that there is a message : "Patron's account has been locked (due
   to 3 failed login attempts)". Note there is a tooltip at the right
6. Click on "Change password", you go to change password page

Note: the follow-up might be unclear to understand:
1 - it moves the button outside the IF patron.login_attempt < 0
2 - Hence it requires the </li> to be moved out so button remains on the
    lane
3 - Finally the <li> must be put before the if and changed a bit

Signed-off-by: Imani Thomas <imani.thomas@bywatersolutions.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:21 +02:00
Fridolin Somers 54bf6c815c
Bug 25947: Improve locked account message
When using system preference 'FailedLoginAttempts', a patron's account
is blocked after X many failed login attempts on the OPAC.

This patch adds, like for "Patron's card has expired" message :
  * a message "Patron's account has been locked (due to X failed login
    attempts)" on the patron details and circulation pages
  * a link to change password
Links are only displayed if libarian has permission to edit patrons.

For administrative lock, only a message is displayed :
"Patron's account has been administratively locked"

To test:
1. Change system preference 'FailedLoginAttempts' to a small number,
   like 2
2. Go to a patron's account and copy their username (while you're there,
   change the password and add some fines, too)
3. In the OPAC, try to log in with the username and a wrong password 3
   times
4. Go back to the patron's account in the staff interface
5. Note that there is a message : "Patron's account has been locked (due
   to 3 failed login attempts)"
6. Click on "Change password", you go to change password page

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:21 +02:00
Tomas Cohen Arazi dbc941cb06
Bug 39191: Add `format` parameter to Koha::Exceptions::ArticleRequest::WrongFormat
This patch just adds a new parameter so any exception consumer or even
the logs contain more information about the context in which the
exception was thrown. This would be useful debugging issues.

No behavior change in Koha.

To test:
1. Run:
   $ ktd --shell
  k$ prove t/db_dependent/Koha/ArticleRequest.t
=> SUCCESS: Tests pass!
2. Apply this patch
3. Repeat 2
=> SUCCESS: Tests pass!
4. Sign off :-D

Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:20 +02:00
Jonathan Druart e81ab4036e
Bug 39061: Export all functions from i18n.js
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:20 +02:00
Caroline Cyr La Rose 6945fa70b8
Bug 39061: Allow translation context in vue files
This patch adds the possibility to add translation context clues in vue
files.

Syntax is

$__p("context","term")

To test, see bug 39045.

Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:19 +02:00
Katrin Fischer 2190d4020c
Bug 39147: DBRev 24.12.00.028
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:19 +02:00
Janusz Kaczmarek 075ab1db28
Bug 39147: Add more missing languages
When languages come into facets in ES, Koha should know the names
for the codes used records.  Otherwise the three-letters language
code is being displayed in the facet instead of name.  Koha now
(as for February 2025) knows about 180 languages, many are still
missing. On the official MARC 21 language codes list
(https://loc.gov/marc/languages/language_code.html) there are
485 languages. We are going to add now next 230 most popular
ones (= existing in our real catalogue), i.e.:
abk, ach, ada, ady, afa, ain, aka, ale, alg, alt, anp, apa, arg, arn,
art, arw, asm, ath, aus, ava, awa, aym, bad, bak, bal, bam, bas,
bat, ber, bho, bin, bre, bua, bug, cai, car, cau, ceb, cha, chb,
chg, chk, chm, chn, chr, chv, chy, cmc, cnr, cos, cpe, cpf, cpp,
crh, crp, cus, dak, dar, day, del, din, div, dra, dsb, dua, dyu,
dzo, efi, elx, ewe, ewo, fan, fat, fij, fil, fiu, fon, fry, ful,
gaa, gil, glv, grb, grn, gsw, guj, hat, haw, him, hmn, hmo, ibo,
ido, ijo, ile, ina, ine, inh, iro, jav, jpr, kaa, kab, kam, kar,
kau, kaw, kbd, khi, kik, kir, kok, kom, kon, krc, kum, lah, lam,
lim, lol, ltz, lua, lug, lui, lun, luo, lus, mad, mai, man, map,
mas, mdf, mdr, men, mkh, mnc, mos, mun, mus, mwl, myv, nai, nap,
nau, nav, nde, new, nia, nic, niu, nog, non, nso, nub, nyn, oci,
oji, ori, orm, oss, oto, paa, pap, phi, phn, pon, raj, rap, roh,
run, rup, sag, sah, sai, sal, sas, sat, scn, sco, sel, sga, sgn,
shn, sin, sio, sit, smo, sna, snk, sog, son, srd, ssa, sun, tah,
tai, tel, tgk, tig, tiv, tkl, tli, tmh, ton, tpi, tsi, tsn, tso,
tum, tup, twi, tyv, udm, uig, umb, vai, ven, vol, wak, was, wln,
wol, xal, xho, yap, ypk, zap, znd, zul

and additionally ca. 15 Polish translations to existing languages.

Subtags and names for language_subtag_registry are taken from
https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry,
English names for language_descriptions.description - from
https://www.loc.gov/marc/languages/language_code.html, and Polish names -
from https://przepisy.bn.org.pl/aneksy#25-kody-jezykow---marc-21.

Test plan:
==========
1. Hava a ES installation with reasonable number of records,
   with a variety of languages in 008/35-37 not present in
   Koha (you can modify your record with codes from the list above).
   Set FacetMaxCount to a high number (like 500 or so,
   dependiing on the size of your data set).
2. Do a search, like '*'.
3. Controll the content of the Language faset -- you should
   see some bare codes instead of language names.
4. Apply the patch -- update the database.
5. Perform the same search.
6. You should see the names in place of the codes.
7. Optionally, you can activate the Polish translation and
   you should be able to see Polish names for the added languages.

Sponsored-by: Ignatianum University in Cracow
Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Thomas Klausner <domm@plix.at>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:18 +02:00
Jonathan Druart 5e2eea4e2b
Bug 39365: Fix 3 files
Those 3 were failing but an easy fix can make them pass

Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:18 +02:00
Jonathan Druart eca3591d74
Bug 39365: Add tests
We exclude (for now) some files that needs additional work:
1. Koha/Account/Credit.pm, Koha/Account/Debit.pm and Koha/Old/Hold.pm
  "Inconsistent hierarchy during C3 merge of class"
2. misc/translator/TmplTokenizer.pm
  Can't locate VerboseWarnings.pm in @INC

We also ignore some known warnings.

Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:17 +02:00
Jonathan Druart ff14f582de
Bug 39367: Replace tabs with spaces in POD
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:17 +02:00
Jonathan Druart 043009250a
Bug 39367: Add new dependency
Nothing to do here, libpod-coverage-perl 0.23 is available in all debian
versions

Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:16 +02:00
Jonathan Druart d2a0147932
Bug 39367: Add POD coverage tests
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:16 +02:00
Jonathan Druart 14e66bfe84
Bug 39367: Remove .pod files from C4/SIP
Include them into the pm instead.

Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:15 +02:00
Jonathan Druart b40ceb1cf5
Bug 39367: Manual changes
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:15 +02:00
Jonathan Druart 9fbff51f0a
Bug 39367: Automatic changes
Added head2 right before sub with missing POD

Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:14 +02:00
Owen Leonard 573c231877
Bug 39323: Print dropdown in members toolbar should auto close
The upgrade to Bootstrap 5 broke some code which was designed to close a
dropdown menu:

$(".btn-group").removeClass("open");

This doesn't work in Bootstrap 5. You have to use:

$(".dropdown-menu").removeClass("show");

However, I found that in most cases this extra code wasn't needed if we
adjust the way we do the click handlers. Using "e.preventDefault()"
instead of "return false" seems to be the preferred practice.

This patch also makes a minor
change to CSS to fix a display issue with dropdown menus.

To test apply the patch and rebuild the staff interface CSS.

- Clear your browser cache if necessary.
- Search the catalog and click "Edit record" on one of the results.
- In the basic MARC editor click the dropdown menu on the "Save" button.
  - Test the three options there: "Save and view record", "Save and edit
    items", and "Save and continue editing".
  - In each case clicking one of those options should result in the menu
    closing before the page redirects.
  - The main "Save" button should still work correctly.

- Perform a patron search which will return results.
  - Check one or more patrons in the result and then click the "Add to
    patron list" button. The dropdown menu should look consistent with
    other dropdowns.

- View the detail page for one of the patron in your results.
  - Test each of the options under the "Print" dropdown menu. In each
    case the menu should close itself when you click one of the menu
    items.
  - Test the "Renew patron" and "Update child to adult patron"
  - Click "Search to hold" and perform a catalog search which will
    return results.
    - Check one or more results and test the "Place hold" dropdown menu
      items.

Sponsored-by: Athens County Public Libraries
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:13 +02:00
Marcel de Rooy 81359cc8a6
Bug 39485: Fix wide character in print-warn in opac-export
Similar change in intranet counterpart: catalogue/export.

Test plan:
Verify no warning anymore when using ris or isbd when record
contains specific Unicode character(s).

Signed-off-by: Magnus Enger <magnus@libriotech.no>
I could not trigger "Wide character" for RIS in the OPAC, but for
ISBD I can see it removes that warning.
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:13 +02:00
Owen Leonard b3c93d1ea2
Bug 39081: (follow-up) Use "data-order" instead of "data-sort"
Both attribute names work the same but "data-order" is more frequent in
our templates.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:12 +02:00
Jonathan Druart e8dd50bbf5
Bug 39081: Allow sort on item type
There is no reason to not allow ordering on item type.

We can now use the same parameters for both tables

Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:12 +02:00
Jonathan Druart 19f2b928b6
Bug 39081: Adjust the result table
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:11 +02:00
Jonathan Druart f3ecd2da73
Bug 39081: Fix order by due dates
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:11 +02:00
Owen Leonard 1d3cc2c5c7
Bug 39081: Fix date and title sorting on batch extend due dates page
This patch updates sorting of the batch extend due dates page so that
dates and titles are sorted correctly.

To test, apply the patch and go to Tools -> Batch extend due dates.

- Submit parameters which will return multiple results
- On the "Confirm selection" page, test the sorting of these columns:
  - Due date
  - Title
  - Checked out on
  - New due date

Sponsored-by: Athens County Public Libraries
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-04-23 09:35:10 +02:00
Nick Clemens c1af78c1df
Bug 23875: Explicitly sort searches by score and provide local-number as tie breaker
To test:
 1 - Set search engine to ES
 2 - Search the catalog for "*"
 3 - Note results
 4 - Edit first result
 5 - Repeat search, results are reordered
 6 - Apply patch
 7 - Search for "*"
 8 - Highest biblionumbers are returned first
 9 - Edit first result, repeat search
10 - Order does not change
11 - Confirm sorting by author, title, etc passes the same trials

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>
2025-04-23 09:35:10 +02:00
Lucas Gass b0cfcea861
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>
2025-04-23 09:35:09 +02:00