koha.git
6 months agoBug 35378: 'This authority type is used {count} times' missing dot
Tomas Cohen Arazi [Tue, 21 Nov 2023 17:30:50 +0000 (14:30 -0300)]
Bug 35378: 'This authority type is used {count} times' missing dot

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>
6 months agoBug 35327: Fix capitalization of language name
Lari Taskula [Mon, 13 Nov 2023 23:21:17 +0000 (23:21 +0000)]
Bug 35327: Fix capitalization of language name

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Updated opac to OPAC.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoDBRev 23.12.00.000: Start of a new release cycle
Katrin Fischer [Wed, 6 Dec 2023 12:51:10 +0000 (12:51 +0000)]
DBRev 23.12.00.000: Start of a new release cycle

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
6 months agoKoha 23.11.00 is here! v23.11.00
Tomas Cohen Arazi [Thu, 30 Nov 2023 19:23:30 +0000 (16:23 -0300)]
Koha 23.11.00 is here!

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months agoAdd release notes for 23.11.0
Tomas Cohen Arazi [Thu, 30 Nov 2023 19:17:58 +0000 (16:17 -0300)]
Add release notes for 23.11.0

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months agoBug 34587: DBIC schema
Tomas Cohen Arazi [Thu, 30 Nov 2023 17:58:11 +0000 (14:58 -0300)]
Bug 34587: DBIC schema

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months ago23.11.00: Update kohastructure.sql
Tomas Cohen Arazi [Thu, 30 Nov 2023 17:42:05 +0000 (14:42 -0300)]
23.11.00: Update kohastructure.sql

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months ago23.11.00: Update history.txt
Tomas Cohen Arazi [Thu, 30 Nov 2023 17:28:20 +0000 (14:28 -0300)]
23.11.00: Update history.txt

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months ago23.11.00: Update contributors.yaml
Tomas Cohen Arazi [Thu, 30 Nov 2023 17:19:20 +0000 (14:19 -0300)]
23.11.00: Update contributors.yaml

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months ago23.11.00: Update mailmap
Tomas Cohen Arazi [Thu, 30 Nov 2023 17:18:20 +0000 (14:18 -0300)]
23.11.00: Update mailmap

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
6 months agoBug 34955: One Koha Manual
Aude Charillon [Thu, 30 Nov 2023 17:08:47 +0000 (14:08 -0300)]
Bug 34955: One Koha Manual

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35418: Fix _get_usage_months
Pedro Amorim [Tue, 28 Nov 2023 13:24:49 +0000 (13:24 +0000)]
Bug 35418: Fix _get_usage_months

No longer falls in an endless loop if the last month in the report period is december.

Test plan:
1) Apply just the tests patch, run EUsage tests
prove t/db_dependent/Koha/ERM/EUsage/
2) Wait for a few seconds. Notice SushiCounter.t it hangs. CTRL+C (cancel it)
3) Apply the fix patch.
4) Run the tests again. Notice all EUsage tests pass with no issues.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Andrew Auld <andrew.auld@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35418: Add TR_B2 tests
Pedro Amorim [Tue, 28 Nov 2023 13:17:20 +0000 (13:17 +0000)]
Bug 35418: Add TR_B2 tests

This test file adds tests for the TR_B2 specific report.
But also tests for this specific bug, which only happens if
the report time period ends in december

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Andrew Auld <andrew.auld@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35115: (QA follow-up):
Pedro Amorim [Fri, 10 Nov 2023 15:07:35 +0000 (15:07 +0000)]
Bug 35115: (QA follow-up):

Spelling.
Tidyness.
Removal of leftover warn

Nick's patch fixes the issue as described, and I agree that it is the ideal solution here.
prove t/db_dependent/api/v1/erm_eholdings* passes
prove t/db_dependent/Koha/BackgroundJob/CreateEHoldingsFromBiblios.t passes

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35115: Move store routine from Resource to Title and update code
Nick Clemens [Wed, 8 Nov 2023 18:36:29 +0000 (18:36 +0000)]
Bug 35115: Move store routine from Resource to Title and update code

These patches move the store routine from Koha::ERM::EHoldings::Resource to Koha::ERM::EHoldings::Title as the code deals exclusively with title fields.

It updates the code to ensure that records are created when a title is not attched to a biblio, and that only the biblio title field is updated when updating an eholdings title.

To test:
 1 - Enable ERMModule sys pref
 2 - Create a new public list, visit:
     /cgi-bin/koha/virtualshelves/shelves.pl
 3 - Click "New list" enter name, set public -> public
 4 - Click "Add items", enter 112\n113\n114 (new line for each), in "Biblio numbers"
 5 - Notice that all added biblios have quite a few MARC fields
 6 - Go to packages, visit:
     /cgi-bin/koha/erm/eholdings/local/packages
 7 - Create a new package, add a name and hit 'Submit'
 8 - Go to titles, visit:
     /cgi-bin/koha/erm/eholdings/local/titles
 9 - Click "import from list"
10 - Pick the package created in 7)
11 - On the row of the list created in 2), click "Import"
12 - Go back to the list, visit:
     /cgi-bin/koha/virtualshelves/shelves.pl?op=view&shelfnumber=1
13 - Notice all the biblios have been stripped of their MARC data, and only title remains.
14 - Go to details page for one of the bibs
15 - Edit -> Replace record via Z39.50
16 - You can search for anything, just make sure to import a mostly full record
17 - Go back to ERM - eHoldings - Local - Titles
18 - Edit the title for the record that was replaced
19 - Save
20 - Go to record details - note the record is gone again
21 - Apply patches
22 - Search the catalog
23 - Check some titles
24 - Add to a new list
25 - repeat 8 - 11 with the new list
26 - View and confirm records are intact
27 - Edit the eholdings title for one of the records, changing the title field
28 - Save and view record details
29 - Confirm record is intact and title updated

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35366: (bug 33948 follow-up) Fix display of old checkouts if no checkouts exist
Jonathan Druart [Fri, 24 Nov 2023 07:04:16 +0000 (08:04 +0100)]
Bug 35366: (bug 33948 follow-up) Fix display of old checkouts if no checkouts exist

Same patch as
  commit bee2b3d33ed6030b5a63d22148b9955a9897e51d
  Bug 33949: Fix display of old checkouts if no checkouts exist

But for the staff interface.

"""
If we pass an empty array from the perl controller, we retrieve an empty
string from the template, and the merge does not work.

This patch fixes the following bug:
Pick a patron without checkout history
Check them an item out and check it in
=> The table is empty, whereas it should display the item that has been
checked in.
"""

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35291: (QA follow-up) Tidying script for QA test tools
Aleisha Amohia [Thu, 23 Nov 2023 21:08:09 +0000 (21:08 +0000)]
Bug 35291: (QA follow-up) Tidying script for QA test tools

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35291: Validate filepaths in linking files
David Cook [Thu, 9 Nov 2023 00:49:54 +0000 (00:49 +0000)]
Bug 35291: Validate filepaths in linking files

Validate that the files in linking files are contained within the ZIP.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35291: Don't allow symlinks for link files in cover image ZIP
David Cook [Thu, 9 Nov 2023 00:23:45 +0000 (00:23 +0000)]
Bug 35291: Don't allow symlinks for link files in cover image ZIP

There's no reason to allow symlinks for link files in cover image
ZIP files. Preventing their use prevents someone from uploading
a symlink pointing to an existing file on the Koha server.

Test plan:
0. Apply patch and restart/reload Koha
1. Create a PNG cover image
2. Create a datalink.txt file that contains something like the
following:
29,Untitled.PNG
3. Turn on "LocalCoverImages" system preference
4. Upload via http://localhost:8081/cgi-bin/koha/tools/upload-cover-image.pl
5. Go to http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=29
6. Note the cover image has been uploaded

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35291: Prevent leaks from FS
Jonathan Druart [Wed, 8 Nov 2023 16:14:55 +0000 (17:14 +0100)]
Bug 35291: Prevent leaks from FS

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34287: Add check on public availability endpoint
Martin Renvoize [Tue, 12 Sep 2023 09:25:36 +0000 (10:25 +0100)]
Bug 34287: Add check on public availability endpoint

A quick check for patron equals current user in the public availability
endpoint.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34287: Amend unit test
Martin Renvoize [Wed, 20 Sep 2023 12:47:19 +0000 (13:47 +0100)]
Bug 34287: Amend unit test

This patch updates the unit test to confirm that checkout availability
should be restricted to the patron checking the availability options on
the public side.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35290: (follow-up) Perltidy formatting corrections
Owen Leonard [Thu, 9 Nov 2023 19:46:35 +0000 (19:46 +0000)]
Bug 35290: (follow-up) Perltidy formatting corrections

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35290: Sanitize field input on cataloguing/ysearch.pl
David Cook [Wed, 8 Nov 2023 23:39:45 +0000 (23:39 +0000)]
Bug 35290: Sanitize field input on cataloguing/ysearch.pl

This change sanitizies the field input on cataloguing/ysearch.pl

Test plan:
0. Apply the patch and restart/reload Koha
1a. "Add marc21_field_260b.pl plugin to 260$b in the Default framework"
1b. Go to http://localhost:8081/cgi-bin/koha/admin/marc_subfields_structure.pl?
op=add_form&tagfield=260&frameworkcode=#subbfield
1c. Choose "marc21_field_260b.pl" from the dropdown next to "Plugin"
1d. Click "Save changes"
2a. "Add new record"
2b. Go to http://localhost:8081/cgi-bin/koha/cataloguing/addbiblio.pl?frameworkcode=
3. Click on tab "2" and scroll down to 260 "b"
4. Type in "Ori" into 260 subfield b
5. Some autocomplete suggestions should appear

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35229: Fix DataProviders_spec.ts
Pedro Amorim [Wed, 15 Nov 2023 14:10:22 +0000 (13:10 -0100)]
Bug 35229: Fix DataProviders_spec.ts

The intercept was wrong:
Was intercepting GET instead of POST
Was intercepting /run route intead of /process_SUSHI_response (this naming was updated in the rest of the code but not here)

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35229: Update cypress tests for usage reports
Matt Blenkinsop [Fri, 27 Oct 2023 16:25:27 +0000 (16:25 +0000)]
Bug 35229: Update cypress tests for usage reports

This patch adds some additional tests for usage reports to improve test coverage.
It also fixes a small error in the reports store - "platforms" v "platform". This was affecting which columns could be selected for platform reports

Test plan:
yarn cypress run
All tests should pass

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35393: Fix Objects.t - filter_by_last_update
Marcel de Rooy [Fri, 24 Nov 2023 07:22:48 +0000 (07:22 +0000)]
Bug 35393: Fix Objects.t - filter_by_last_update

Test plan:
Keep awake until just after midnight :)
Run t/db_dependent/Koha/Objects.t

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35365: fix stray td tag
Brendan Lawlor [Fri, 17 Nov 2023 21:40:38 +0000 (21:40 +0000)]
Bug 35365: fix stray td tag

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35335: Fix 500 on circulation history
Jonathan Druart [Tue, 21 Nov 2023 12:46:33 +0000 (13:46 +0100)]
Bug 35335: Fix 500 on circulation history

Koha::Patron->issuer is not covered by tests!

Test plan:
1. Set RecordStaffUserOnCheckout to "record"
2. Check an item out and in to a patron
3. Go to their circulation history
=> Without the patch you get an error
=> With this patch applied the table displayed correct. The "checkout by" column contains the name and the link to the librarian

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35374: Remove ES6 template literals to fix translation strings
Jonathan Druart [Tue, 21 Nov 2023 12:36:17 +0000 (13:36 +0100)]
Bug 35374: Remove ES6 template literals to fix translation strings

The .po files contains the whole block after this line. I don't really
understand what's happening but this change fixes the problem.

Test plan:
1. Run the following command before and after the patch and compare the
diff
% gulp po:update --lang de-DE --task messages-js
2. Confirm that the list on this vue is correctly populated

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35377: Fix Callnumber => Call number
Jonathan Druart [Wed, 22 Nov 2023 08:54:47 +0000 (09:54 +0100)]
Bug 35377: Fix Callnumber => Call number

in Preservation/WaitingList.vue
See: https://wiki.koha-community.org/wiki/Terminology

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35174: update control files for koha-l10n dependency package
Mason James [Thu, 16 Nov 2023 10:06:27 +0000 (23:06 +1300)]
Bug 35174: update control files for koha-l10n dependency package

 to test...

 - apply patch
 - build koha-common package
 - install koha-common package, and confirm koha-l10n package is installed

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35174: Don't run gulp po commands if po dir is missing
Jonathan Druart [Thu, 16 Nov 2023 07:45:15 +0000 (08:45 +0100)]
Bug 35174: Don't run gulp po commands if po dir is missing

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35174: Add misc/translator/po to .gitignore
Jonathan Druart [Thu, 16 Nov 2023 07:44:56 +0000 (08:44 +0100)]
Bug 35174: Add misc/translator/po to .gitignore

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35174: Add a warning to the about page
Jonathan Druart [Thu, 16 Nov 2023 07:43:43 +0000 (08:43 +0100)]
Bug 35174: Add a warning to the about page

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35174: Do not explode if po dir does not exist
Jonathan Druart [Thu, 16 Nov 2023 07:27:10 +0000 (08:27 +0100)]
Bug 35174: Do not explode if po dir does not exist

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35174: Remove .po files from Koha
Koha translators [Thu, 16 Nov 2023 07:46:24 +0000 (08:46 +0100)]
Bug 35174: Remove .po files from Koha

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35266: Fix biblio check in opac-MARCdetail
Marcel de Rooy [Mon, 6 Nov 2023 13:11:49 +0000 (13:11 +0000)]
Bug 35266: Fix biblio check in opac-MARCdetail

We should check before retrieving metadata.

Test plan;
Try /cgi-bin/koha/opac-MARCdetail?biblionumber=X
Replace X by a not-existing biblionumber.
Verify that you get a 404 error page.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
JD amended patch: Use ternary op

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 12133: (follow-up) Fix failing tests
Jonathan Druart [Wed, 15 Nov 2023 11:11:39 +0000 (12:11 +0100)]
Bug 12133: (follow-up) Fix failing tests

Tests were still failing

 #   Failed test 'No tests run for subtest "Test where parameter for SendQueuedMessages"'
 #   at t/db_dependent/Letters.t line 1274.
 [Child patron needs a guarantor]# Looks like your test exited with 11 just after 97.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 35012: Apply change to all events
Marcel de Rooy [Thu, 9 Nov 2023 13:16:05 +0000 (13:16 +0000)]
Bug 35012: Apply change to all events

We should not just look at Click.

Test plan:
[1] Apply the example patch for a Blur action in barcode.pl.
[2] Check that barcode.pl is active in your framework and that
    autoBarcode is not disabled.
[3] Open the browser dev console.
[4] Tab a few times through barcode in the neworderempty form of
    Acquisition. If you leave the field, the Blur event fires.
    => Without this patch you will see two console lines (FF may
    show a little '2' icon at the right side) added. With this
    patch just one.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jan Kissig <jkissig@th-wildau.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35012: Prevent Click handler firing twice
Jan Kissig [Tue, 10 Oct 2023 11:36:04 +0000 (13:36 +0200)]
Bug 35012: Prevent Click handler firing twice

test plan:
a) build a new basket + order line using "item create on placing an order"
b) in the item creation dialog (neworderempty.pl) please use the webbrowsers dev tools to analyze the [...] button next to subfield d (Date acquired) and inspect the events that get fired by clicking
c) notice the Clicktag_952_subfield_d_* event gets fired twice.
d) apply patch and reload page
e) there should be only 1 click handler left (besides the jquery one), which points to the Clicktag_952_subfield_* function

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
See also bug 35298. You may have seen that the Focus event of dateaccessioned
did not fire. But that is related to use of Flatpickr in this plugin.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35276: Remove authentication params from suggestion hash
Marcel de Rooy [Tue, 7 Nov 2023 12:57:42 +0000 (13:57 +0100)]
Bug 35276: Remove authentication params from suggestion hash

These would be forwarded to Koha::Objects->as_list and crash on
unknown column.

Test plan:
Logout from staff.
Enter URL /suggestion/suggestion.pl
Without this patch, it crashes. Now it does not.

Note: The crash may show auth_forwarded_hash but I also saw
koha_login_context passing by. Same issue.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35306: Fix Expired holds when modding request
Lucas Gass [Fri, 10 Nov 2023 14:54:00 +0000 (14:54 +0000)]
Bug 35306: Fix Expired holds when modding request

To test:
1. Make some holds on a record and make sure some are set to expired.
2. Go to to reserve/request.pl?biblionumber=X for the biblionumber
3. Try updating something besides the expiration date. i.e. Pickup library
4. Click Update hold(s)
5. Notice the expirated holds have lost their expiration date.
6. APPLY PATCH
7. Try steps 2-4 again, this time the expiration date shold be retained.
8. Make sure Table settings still work and you can properly hide columns.
9. The hold expiration date should be hide-able.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35298: Remove focus handler from dateaccessioned plugin.
Marcel de Rooy [Thu, 9 Nov 2023 08:05:34 +0000 (08:05 +0000)]
Bug 35298: Remove focus handler from dateaccessioned plugin.

Test plan:
Verify that setting focus to date acquired field in items editor
fills date of today when field is empty but does not replace existing
date.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 12133: Fix failing tests
Emmi Takkinen [Tue, 14 Nov 2023 11:44:11 +0000 (13:44 +0200)]
Bug 12133: Fix failing tests

Tests in erm_users.t and Letters.t failed because when
we mock patrons they receive category where setting
can_be_guarantee is not 0. This triggers error "Child
patron cannot be a guarantor". We also need to mock
syspref "ChildNeedsGuarantor" accordingly.

To test prove t/db_dependent/api/v1/erm_users.t and
t/db_dependent/Letters.t.

Sponsored-by: Koha-Suomi Oy
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35103: Add option to gulp tasks to pass a list of tasks
Jonathan Druart [Thu, 19 Oct 2023 07:41:03 +0000 (09:41 +0200)]
Bug 35103: Add option to gulp tasks to pass a list of tasks

You can now generate the messages.po for all languages with:
  gulp po:update --task messages

or for only es-ES
  gulp po:update --task messages --lang es-ES

It may be helpful for the "update po" script that will be used on
weblate.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 34517: (follow-up) Add test for attribute search field and make cleanup more...
Nick Clemens [Mon, 13 Nov 2023 14:11:13 +0000 (14:11 +0000)]
Bug 34517: (follow-up) Add test for attribute search field and make cleanup more robust

This patch adds a test to cover the new functionality of searching an attribute not searched by default.

It also moves the addition of objects to the cleanup array right after they are created. Patrons are added to the front of the array to ensure no constraints are violated when deleting. This change ensures that if the tests die before reachign the end, the data generated is still cleaned up.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 34517: (follow-up) Mark test attribute as searched_by_default
Nick Clemens [Mon, 13 Nov 2023 12:48:06 +0000 (12:48 +0000)]
Bug 34517: (follow-up) Mark test attribute as searched_by_default

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
7 months agoBug 12133: DBRev 23.06.00.079
Tomas Cohen Arazi [Fri, 10 Nov 2023 13:59:22 +0000 (10:59 -0300)]
Bug 12133: DBRev 23.06.00.079

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 12133: (QA follow-up) Tidy for qa script
Kyle M Hall [Fri, 3 Nov 2023 15:35:35 +0000 (15:35 +0000)]
Bug 12133: (QA follow-up) Tidy for qa script

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 12133: (QA follow-up) Fix number of tests
Kyle M Hall [Fri, 3 Nov 2023 15:06:17 +0000 (15:06 +0000)]
Bug 12133: (QA follow-up) Fix number of tests

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 12133: Fix QA issue
Emmi Takkinen [Fri, 29 Sep 2023 12:19:36 +0000 (15:19 +0300)]
Bug 12133: Fix QA issue

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 12133: Add requirements for guarantor and guarantee
Emmi Takkinen [Fri, 17 Feb 2023 11:15:17 +0000 (13:15 +0200)]
Bug 12133: Add requirements for guarantor and guarantee

Add two requirements when registering a new patron:

- A child patron must have a guarantor. This is controlled by
  a new syspref ChildNeedsGuarantor.
- A guarantor cannot be a guarantee.

Test plan:
1. Add a child patron without guarantor or child patron with guarantee
as guarantor succesfully.
2. Apply this patch.
3. Add a child patron as a guarantor.
=> Error is raised.
4. Turn syspref "ChildNeedsGuarantor" ON.
5. Add a child patron without a guarantor and error "Child needs a
guarantor" is raised.
6. Add guarantor. Guarantor can either be existing patron or added with
"Contact" section.
=> Save without errors.

Also prove t/db_dependent/Koha/Patron.t

Sponsored-by: Koha-Suomi Oy
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34868: (QA follow-up) Tidy sip_circulation_status
Kyle M Hall [Tue, 7 Nov 2023 19:30:04 +0000 (14:30 -0500)]
Bug 34868: (QA follow-up) Tidy sip_circulation_status

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34868: (QA follow-up) Fix XML
Kyle M Hall [Tue, 7 Nov 2023 19:20:50 +0000 (14:20 -0500)]
Bug 34868: (QA follow-up) Fix XML

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34868: (QA follow-up) Rename new option, add comments
Kyle M Hall [Tue, 31 Oct 2023 17:33:19 +0000 (13:33 -0400)]
Bug 34868: (QA follow-up) Rename new option, add comments

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34868: Add ability for SIP2 to distinguish missing item from other lost types
Kyle M Hall [Thu, 21 Sep 2023 15:44:49 +0000 (11:44 -0400)]
Bug 34868: Add ability for SIP2 to distinguish missing item from other lost types

The SIP circulation status specifies that a 12 means an item is lost, and 13 means an item is missing. In Koha, missing items are simply a type of lost item so we never send a 13. This is an important distinction for some SIP based inventory tools. It would be good to be able to specify when lost status means "missing" at the SIP login level.

Test Plan:
1) Apply this patch
2) prove t/db_dependent/SIP/Transaction.t

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34791: Add links to HTML Customizations to CookieConsent preferences
Martin Renvoize [Thu, 14 Sep 2023 14:28:27 +0000 (15:28 +0100)]
Bug 34791: Add links to HTML Customizations to CookieConsent preferences

This patch simply adds a note to the CookieConsent and CookieConsentedJS
system preferences to link to the HTML customizations page and hint at
which customization should be used to affect the components governed by
the preferences.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35144: Update style of 'Required' label for OPAC patron attributes
Owen Leonard [Tue, 7 Nov 2023 19:06:13 +0000 (19:06 +0000)]
Bug 35144: Update style of 'Required' label for OPAC patron attributes

This patch makes some changes to style and markup of the part of the
OPAC patron entry form which displays patron attribute entry fields.

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

- Create at least two patron attributes which have both "Display in
  OPAC" and "Editable in OPAC" checked: One which is linked to an
  authorized value, one which isn't. At least one attribute should be
  mandatory. At least one attribute should be repeatable.
- Test the form using either patron self-registration or by logging in
  to the OPAC and clicking the "Personal details" link in the sidebar.
- Check the appearance of required fields in the form, including the
  mandatory patron attributes.
- Confirm that the "Clear" and "New" controls look good and work
  correctly, including fields cloned with the "New" button.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35273: Fix item selection when receiving
Jonathan Druart [Tue, 7 Nov 2023 10:23:34 +0000 (11:23 +0100)]
Bug 35273: Fix item selection when receiving

For partial receives with items created on order, the
aqorders_items table was not correctly updated when only
some of the ordered items were received.

To test:
1) Create a basket with creating items on order
2) Create an order line with 3 items
3) Close basked
4) Receive shipment and create invoice
5) Receive your created order line
6) Edit first item displayed, add barcode
7) Check checkbox and receive
8) Verify the order line has been split 2:1
9) Receive again - notice all 3 items are showing.
  We should only see the remaining 2
10) Undo receive
11) Apply patch
12) Repeat steps 5)-9)
13) Verify that in step 9) only the remaining 2 items display now.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 29007: Add cancellation reason input on check in
Thibaud Guillot [Fri, 3 Nov 2023 14:30:04 +0000 (15:30 +0100)]
Bug 29007: Add cancellation reason input on check in

Test plan:

1) Check an item in with already a confirmed hold
2) Cancel the hold, it was cancelled without possibility to choosing a
   reason
3) Apply this patch and do it again, you must see an input to choose
   your cancellation reason (list from VA)

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35251: Update checkout count when refreshing issue table
Lucas Gass [Fri, 3 Nov 2023 16:51:11 +0000 (16:51 +0000)]
Bug 35251: Update checkout count when refreshing issue table

1. Have some checkouts
2. Go to the issue-table and select some of those checkouts and check them in.
3. Look at the tab, Checkouts(X)
4. This is not updated and now shows an incorrect number of checkouts.
4. APPLY PATCH, clear browser cache/
5. Try again, now when the table reloads the 'Checkouts(X)' tab should be correctly updated.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35068: (follow-up): Make sure renew/checkin selections get retained on reload
Lucas Gass [Fri, 3 Nov 2023 15:24:49 +0000 (15:24 +0000)]
Bug 35068: (follow-up): Make sure renew/checkin selections get retained on reload

To test:
1. Have two checkouts. Click one for Renew and one for Checkin. Click on Check in selected items.
2. When the table reloads the 'renew' selections should be retained
3. Have two checkouts. Click one for Renew and one for Checkin. Click on Renew selected items.
4. When the table reloads the 'check in' selections should be retained

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35068: (follow-up) Update button order and icons
Owen Leonard [Thu, 19 Oct 2023 14:50:18 +0000 (14:50 +0000)]
Bug 35068: (follow-up) Update button order and icons

This patch updates the Renew and Check-in buttons so that they have
icons matching the ones used for the Renew and Check-in search tabs in
the header.

The patch also moves the Renew button so that it is next to the Renew
all button. I think this makes more logical sense. So the order is:

- Check in selected items
- Renew selected items
- Renew all

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35068: (follow-up) Always disable buttons after action
Lucas Gass [Wed, 18 Oct 2023 20:04:49 +0000 (20:04 +0000)]
Bug 35068: (follow-up) Always disable buttons after action

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Kelly <kelly@bywatersolutions.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35068: (follow-up) Disable button after clicking Renew all
Lucas Gass [Tue, 17 Oct 2023 14:52:07 +0000 (14:52 +0000)]
Bug 35068: (follow-up) Disable button after clicking Renew all

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Kelly <kelly@bywatersolutions.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35068: Split RenewCheckinChecked button into seperate renew/checkin buttons
Lucas Gass [Mon, 16 Oct 2023 22:20:54 +0000 (22:20 +0000)]
Bug 35068: Split RenewCheckinChecked button into seperate renew/checkin buttons

To test:
1. APPLY patch, clear browser's cache
2. Have more than 1 checkout issued to a borrower.
3. Load the checkout table on circ/circulation.pl
4. Notice that there is now 'Renew selected items' and 'Checkin
   selected items' button.
5. Play around with each making sure that they work as excepted when
   checkouts are checked in either the 'Check in' or 'Renew' columns.
6. Uncheck everything in the 'Renew column', the 'Renew selected items'
   button should be disabled.
7. Uncheck everything in the 'Checkin column', the 'Checkin selected
   items' button should be disabled.
8. Try unchecking some of these to make sure the Renew/Checkin button is
   properly disabled when no related checkboxes are checked.
9. Try using the select all/none options at the top of both the 'Renew'
   and 'Checkin' columns. Make sure the 'Renew selected items' and
   'Checkin selected items' become properly disabled/enabled.
10. Make sure the 'Renew all' button still works properly.
11. Do the test plan of 5th patch "Make sure renew/checkin selections"

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Kelly <kelly@bywatersolutions.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35284: Fix tests
Jonathan Druart [Thu, 9 Nov 2023 09:45:32 +0000 (10:45 +0100)]
Bug 35284: Fix tests

This fix patrons_search.t but other selenium tests certainly need
adjustements

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35284: Add throttling to column filters
Jonathan Druart [Thu, 9 Nov 2023 07:58:41 +0000 (08:58 +0100)]
Bug 35284: Add throttling to column filters

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35284: Fix Vue tables
Jonathan Druart [Thu, 9 Nov 2023 07:58:11 +0000 (08:58 +0100)]
Bug 35284: Fix Vue tables

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35284: Add DT delay to kohaTable
Jonathan Druart [Wed, 8 Nov 2023 21:23:20 +0000 (22:23 +0100)]
Bug 35284: Add DT delay to kohaTable

To test:
* When a specific initComplete exists (general patron search)
* When no specific initComplete exists (cities)

=> KO
* ERM tables display twice the "show X entries" dropdown list
* Column filters are not affected

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35008: (QA follow-up) Add selenium unit tests
David Cook [Fri, 10 Nov 2023 01:06:39 +0000 (01:06 +0000)]
Bug 35008: (QA follow-up) Add selenium unit tests

This patch addds selenium tests for the ILS-DI feature.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35008: Make ILS-DI not require auth when OpacPublic disabled
Aleisha Amohia [Sun, 8 Oct 2023 21:59:19 +0000 (21:59 +0000)]
Bug 35008: Make ILS-DI not require auth when OpacPublic disabled

To test, disable OpacPublic and ensure a call to ilsdi.pl will still return expected results from a private browser, not logged into the OPAC.

Sponsored-by: Auckland University of Technology
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35283: Add missing subfield h to action note 583 in OPAC detail page
Katrin Fischer [Thu, 9 Nov 2023 21:33:10 +0000 (21:33 +0000)]
Bug 35283: Add missing subfield h to action note 583 in OPAC detail page

$x is nonpublic note, so it makes sense to only display it in staff, but
$h is Jurisdiction and we should show it in OPAC and staff alike.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35283: Add missing subfields h and x to field 583 for staff XSLT
David Cook [Wed, 8 Nov 2023 02:24:01 +0000 (02:24 +0000)]
Bug 35283: Add missing subfields h and x to field 583 for staff XSLT

This change adds the missing subfields h and x to field 583 for
the detail XSLT in the staff interface.

Test plan:
0. Apply the patch and koha-plack --reload kohadev
1. Go to http://localhost:8081/cgi-bin/koha/cataloguing/addbiblio.pl?biblionumber=29
2. Click on tab "5"
3. Scroll down to 583 and click on "ACTION NOTE" to expand subfields
4. Fill in using the following example:
   583 0#$adowngraded$c19910110$hJoe Smith$otitle$xfrom secret FRD to confidential NSI
5. Click "Save"
6. Note that the "Action note" now shows "Joe Smith" and "from secret
   FRD to confidentail NSI"

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35304: Add new Sortable library to didyoumean configuration
Emily Lamancusa [Thu, 9 Nov 2023 16:24:40 +0000 (11:24 -0500)]
Bug 35304: Add new Sortable library to didyoumean configuration

To test:
1. Go to Administration > Did You Mean
2. Attempt to drag and drop plugin options.
--> Confirm that they are not draggable
3. Apply patch and clear browser cache
4. Reload the page
--> Confirm that drag-and-drop now works

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 33164: Do not prevent processing of all error messages
Aleisha Amohia [Mon, 23 Oct 2023 22:28:55 +0000 (22:28 +0000)]
Bug 33164: Do not prevent processing of all error messages

This follow-up patch removes the use of $exit_required_p completely. The sysprefs BlockReturnOfLostItems and BlockReturnOfWithdrawnItems are handled in other scripts, and should not prevent the processing of all returns error messages when enabled.

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 33164: Ensure return claim message shows if lost item return blocked
Aleisha Amohia [Tue, 7 Mar 2023 22:07:04 +0000 (11:07 +1300)]
Bug 33164: Ensure return claim message shows if lost item return blocked

This fix ensures that a return claim confirmation always shows, even if
the return of lost items has been blocked by BlockReturnOfLostItems
being enabled.

To test:

1. Set BlockReturnOfLostItems system preference to Block
2. Check out an item to a patron
3. Go to the patrons page and claim a return on the item
4. Check in the item and keep checking in the item. Notice the message
"Item is lost, cannot be checked in." shows every time, but the return
claim message only shows sometimes.

5. Apply the patch and restart services

6. Check in the item and keep checking in the item. Confirm both the
lost message shows and the return claim message shows every time.
7. Confirm the return of the item is still blocked.

Sponsored-by: Pymble Ladies' College
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 21431: Adjust template for logviewer
Marcel de Rooy [Thu, 2 Nov 2023 13:41:21 +0000 (13:41 +0000)]
Bug 21431: Adjust template for logviewer

Test plan:
Verify that you can filter by reset password.
And that the uppercase code is replaced by a description.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 21431: Add unit test
Marcel de Rooy [Thu, 2 Nov 2023 12:59:03 +0000 (12:59 +0000)]
Bug 21431: Add unit test

Test plan:
Run t/db_dependent/Koha/Patrons.t

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 21431: Add action parameter to set_password
Marcel de Rooy [Thu, 2 Nov 2023 12:51:35 +0000 (12:51 +0000)]
Bug 21431: Add action parameter to set_password

Added to the call in opac-password-recovery.pl. This allows
differentiating between password change and password reset when
viewing the logs.

Test plan:
Enable BorrowersLog.
Do a password recovery on OPAC.
Check with log viewer for 'RESET PASS' action.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35065: DBRev 23.06.00.078
Tomas Cohen Arazi [Thu, 9 Nov 2023 17:48:33 +0000 (14:48 -0300)]
Bug 35065: DBRev 23.06.00.078

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35065: (follow-up) Add entry to HTML customization help include
Owen Leonard [Wed, 25 Oct 2023 16:21:44 +0000 (16:21 +0000)]
Bug 35065: (follow-up) Add entry to HTML customization help include

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35065: Convert SelfCheckHelpMessage system preference to HTML customization
Owen Leonard [Mon, 16 Oct 2023 16:16:13 +0000 (16:16 +0000)]
Bug 35065: Convert SelfCheckHelpMessage system preference to HTML customization

This patch moves the SelfCheckHelpMessage system preference into HTML
customizations, making it possible to have language- and
library-specific content.

To test you should have some content in the SelfCheckHelpMessage
system preference before applying the patch. Apply the patch, run the
database update process, and rebuild the OPAC CSS.

- In the staff client, go to Tools -> HTML customizations and verify
  that the content from SelfCheckHelpMessage is now stored there.
- The HTML customization entry form should offer SelfCheckHelpMessage
  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.
- Enable the "opaclanguagesdisplay" preference if necessary.
- Edit the SelfCheckHelpMessage HTML customization and add unique
  content to the "fr-FR" tab.

- Log into the self checkout system and click the "Help" link at the
  top.
- On the help page, confirm that the SelfCheckHelpMessage content is
  shown there.
- 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
  "SelfCheckHelpMessage." It should return no results.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35278: Fix warn from column_settings.pl
Marcel de Rooy [Mon, 6 Nov 2023 14:00:49 +0000 (14:00 +0000)]
Bug 35278: Fix warn from column_settings.pl

We need to add scalar to the calls. These parameters are not meant
to be used as multi_param.

Test plan:
Try With and without this patch on staff:

Try: /cgi-bin/koha/admin/columns_settings.pl
=> WITHOUT: No warnings
=> WITH: Same. No change.
Try: /cgi-bin/koha/admin/columns_settings.pl?module=acqui&page=basket
=> WITHOUT: Opens module, scrolls down. CGI::param called in list context in logfile
=> WITH: Opens module, scrolls down.
Try: /cgi-bin/koha/admin/columns_settings.pl?module=acqui&page=basket&table=orders
=> WITHOUT: Opens module, scrolls down. CGI::param called in list context in logfile
=> WITH: Opens module, scrolls down.

Try: /cgi-bin/koha/admin/columns_settings.pl?module=acqui&module=admin
* Hash like: panel => acqui, admin => page, undef  => table, undef => modules, $modules (SHIFTED)
=> WITHOUT: Acqui expanded showing: There is no page using the table configuration in this module.
=> CGI::param warning in log.
=> And: Problem = a value of table has been passed to param without key
=> And: Problem = a value of modules has been passed to param without key
=> WITH: Only the first module (Acqui) should be expanded.

Try: /cgi-bin/koha/admin/columns_settings.pl?module=acqui&module=admin&page=basket&table=orders
* Hash like: panel => acqui, admin => page, basket => table, orders => modules, $modules hash (SHIFTED)
=> WITHOUT: Acqui expanded showing: There is no page using the table configuration in this module.
=> And: CGI param log warning.
=> WITH:: Opens Acqui. Second module ignored. Scrolling.

Try: /cgi-bin/koha/admin/columns_settings.pl?module=admin&module=acqui&page=basket&table=orders
* Hash like: panel => admin, acqui=> page, basket => table, orders => modules, $modules hash (SHIFTED)
=> WITHOUT: Admin expanded showing: There is no page using the table configuration in this module.
=> And: CGI param log warning.
=> WITH: Admin should be expanded (page and table ignored, not in Admin). No scroll.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34587: (follow-up) Remove unnecessary code
Matt Blenkinsop [Thu, 9 Nov 2023 17:31:57 +0000 (17:31 +0000)]
Bug 34587: (follow-up) Remove unnecessary code

This patch removes some commented out lines and some unnecessary imports. No impact to working code - self signoff

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35063: (follow-up) Adjust dbrevs to the reference format
Tomas Cohen Arazi [Thu, 9 Nov 2023 17:39:45 +0000 (14:39 -0300)]
Bug 35063: (follow-up) Adjust dbrevs to the reference format

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35063: (follow-up) Add reference example for HTML customizations on skeleton.pl
Tomas Cohen Arazi [Thu, 9 Nov 2023 17:33:59 +0000 (14:33 -0300)]
Bug 35063: (follow-up) Add reference example for HTML customizations on skeleton.pl

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35063: DBRev 23.06.00.077
Tomas Cohen Arazi [Thu, 9 Nov 2023 17:26:27 +0000 (14:26 -0300)]
Bug 35063: DBRev 23.06.00.077

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35063: (follow-up) Add entry to HTML customization help include
Owen Leonard [Wed, 25 Oct 2023 16:14:38 +0000 (16:14 +0000)]
Bug 35063: (follow-up) Add entry to HTML customization help include

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35063: Convert SelfCheckInMainUserBlock system preference to HTML customization
Owen Leonard [Mon, 16 Oct 2023 15:16:22 +0000 (15:16 +0000)]
Bug 35063: Convert SelfCheckInMainUserBlock system preference to HTML customization

This patch moves the SelfCheckInMainUserBlock system preference into
HTML customizations, making it possible to have language- and
library-specific content.

To test you should have some content in the SelfCheckInMainUserBlock
system preference before applying the patch. Apply the patch, run the
database update process, and rebuild the OPAC CSS.

- In the staff client, go to Tools -> HTML customizations and verify
  that the content from SelfCheckInMainUserBlock is now stored there.
- The HTML customization entry form should offer
  SelfCheckInMainUserBlock 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.
- Enable the "opaclanguagesdisplay" preference if necessary.
- Edit the SelfCheckInMainUserBlock HTML customization and add unique
  content to the "fr-FR" tab.

- Log into the self check-in system and confirm that the
  SelfCheckInMainUserBlock content is shown there.
- 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
  "SelfCheckInMainUserBlock." It should return no results.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35048: DBRev 23.06.00.076
Tomas Cohen Arazi [Thu, 9 Nov 2023 17:24:29 +0000 (14:24 -0300)]
Bug 35048: DBRev 23.06.00.076

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35048: (follow-up) Add entry to HTML customization help include
Owen Leonard [Wed, 25 Oct 2023 16:08:45 +0000 (16:08 +0000)]
Bug 35048: (follow-up) Add entry to HTML customization help include

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35048: Convert SCOMainUserBlock system preference to HTML customization
Owen Leonard [Thu, 12 Oct 2023 18:01:04 +0000 (18:01 +0000)]
Bug 35048: Convert SCOMainUserBlock system preference to HTML customization

This patch moves the SCOMainUserBlock system preference into HTML
customizations, making it possible to have language- and
library-specific content.

The patch also makes a minor fix to CSS in order to get the "Back to
top" link to show up correctly in self-checkout and self-checkin.

To test you should have some content in the SCOMainUserBlock
system preference before applying the patch. Apply the patch, run the
database update process, and rebuild the OPAC CSS.

- In the staff client, go to Tools -> HTML customizations and verify
  that the content from SCOMainUserBlock is now stored there.
- The HTML customization entry form should offer SCOMainUserBlock
  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.
- Enable the "opaclanguagesdisplay" preference if necessary.
- Edit the SCOMainUserBlock HTML customization and add unique
  content to the "fr-FR" tab.

- Log into the self checkout system and confirm that the
  SCOMainUserBlock content is shown there.
- 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
  "SCOMainUserBlock." It should return no results.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35194: Remove obsoleted sortable function
Marcel de Rooy [Thu, 9 Nov 2023 10:35:06 +0000 (10:35 +0000)]
Bug 35194: Remove obsoleted sortable function

Removes two occurrences and a commented one.

Test plan:
[1] Go to cataloguing editor. Open dev console. Clone 500.
[2] Go to Admin/Did you mean. Try to toggle options.

With this patch it works. Without this patch, JS errors.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34413: Fix style of Flatpickr in iOS mobile view
Owen Leonard [Thu, 9 Nov 2023 13:21:06 +0000 (13:21 +0000)]
Bug 34413: Fix style of Flatpickr in iOS mobile view

This patch updates Flatpickr CSS in the OPAC and staff interface so that
date fields are displayed correctly in iOS mobile views.

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

- In the OPAC, click "Create new account"
- In the account entry form, confirm that the date of birth field looks
  correct and that the date-picker works as it should.
- In the staff client, go to Patrons -> New patron.
- Check the date of birth field in this form too.

This patch has been tested in the Xcode iOS device simulator with iOS
17. While I wasn't able to reproduce the problem in Firefox, I was able
to use the developer tools' responsive design mode to trigger the mobile
view and thus be able to see the styles which are being applied:

- In the OPAC, on the "Create new account" screen, open the Web
  Developer Tools panel (Tools -> Browser tools -> Web Developer Tools).
- Click the "Responsive Design Mode" button in the upper-right corner of
  the developer tools panel (it looks like a phone and tablet together).
- The main browser window will now how some settings at the top.
- In the first dropdown, choose an iPhone model.
- The date of birth field should now be styled differently because of
  the addition of a "flatpickr-mobile" style.
- Right-click the field and choose "Inspect." In the developer console
  you can see the styles which are being applied to the field. One of
  those should be ".flatpickr-input.flatpickr-mobile"

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34058: Use buildSearchPatronQuery when searching for patrons on left side filters
Pedro Amorim [Tue, 27 Jun 2023 09:08:52 +0000 (09:08 +0000)]
Bug 34058: Use buildSearchPatronQuery when searching for patrons on left side filters

This will now use the centered logic from buildSearchPatronQuery, not only
fixing the original issue of not being considering all the terms in the
search input, but also reusing already established code.

Test plan, k-t-d:
1) Install FreeForm, enable ILLModule sys pref, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
2) Create a FreeForm ILL request and input 23529000035676 in the cardnumber, that's "Henry Acevedo".
3) Go back to the ILL list table, input "henry" in the bottom "Patron" filter input and press the "Search" button, notice it fetches the request correctly.
4) Now do the the same search but with "henry acevedo", notice the request is not retrieved.
5) Apply patch. Repeat. Do the same for the "patron" input field and the "keyword" input field.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 34058: Preparation: buildPatronSearchQuery
Pedro Amorim [Tue, 27 Jun 2023 09:07:49 +0000 (09:07 +0000)]
Bug 34058: Preparation: buildPatronSearchQuery

Add table_prefix argument to buildPatronSearchQuery.
This allows the buildPatronSearchQuery function to also perform the search
on a related table, instead of the default patron table.
This is relevant because the query will be performed on the ILL API endpoint,
so the table being searched will have to be prefixed with 'patron.', instead of the
default 'me.'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35303: (bug 26916 follow-up) Fix paton autocomplete
Jonathan Druart [Thu, 9 Nov 2023 14:10:39 +0000 (15:10 +0100)]
Bug 35303: (bug 26916 follow-up) Fix paton autocomplete

Fix the following JS error:
Uncaught TypeError: search_fields.forEach is not a function

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
7 months agoBug 35295: Move JS asset in returns.tt
Lucas Gass [Wed, 8 Nov 2023 21:18:27 +0000 (21:18 +0000)]
Bug 35295: Move JS asset in returns.tt

To Test:
1. Place a hold
2. Check-in an item of the held record
3. No hold modal ðŸ˜±
4. APPLY PATCH
5. Hold modal!!!

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>