Go to file
CJ Lynce e7e8ec8073
Bug 36536: Make REST APIs validateUserAndPassword update borrowers.lastseen
This patch added the option to update borrowers.lastseen when a patron username
    and password is verified via the REST API. This can be enabled or disabled
    selectively using the TrackLastPatronActivityTriggers system preference
    using the [ ] Patron authentication via API option..

To test:
1.  Create a new user, ensuring to set the Username and password fields.
	    *Import to do this first*
2.  Edit the TrackLastPatronActivityTriggers syspref and check all options.
3.  Ensure the RESTBasicAuth syspref is set to Enable.
4.  Check the lastseen date of your new user using a SQL report
        SELECT borrowernumber, userid, lastseen FROM borrowers WHERE userid = 'USERNAME'
        (Replace USERNAME with your chosen username for the new patron)
        NOTE: **Ensure the cache expiry of the SQL report is set to 0**
5.  The lastseen for your new user should be null
6.  'restart_all' Koha services to clear plack cache.
7.  Run the attached api_verify_lastseen.pl test script
        **Change P_USERNAME and P_PASSWORD to the username and password of your new user.
        (script contains expected output for successful verification)
8.  Re-check the lastseen date of your new user again via SQL (step 4)
        The lastseen should still be null.

9.  Apply Patch
10. 'restart_all' Koha services

11. Edit the TrackLastPatronActivityTriggers syspref and check the '[ ] Patron authentication via API' option
12. Rerun the api_verify_lastseen.pl
13. Re-check the lastseen date of your new user again via SQL (step 4)
        The lastseen should now be updated to the time of the last script run.

For good measure:
14. Edit the TrackLastPatronActivityTriggers syspref and **UNcheck** the '[ ] Patron authentication via API' option
15. 'restart_all' Koha services to clear plack cache.
16. Rerun the api_verify_lastseen.pl
17. Re-check the lastseen date of your new user again via SQL (step 4)
        The lastseen should have remained the same as previous.

Sponsored-by: Westlake Porter Public Library <https://westlakelibrary.org>
Signed-off-by: Bernard Scaife <bernard.scaife@openfifth.co.uk>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit ba43483f4d)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-09-20 10:43:14 +02:00
C4 Bug 37651: (follow-up) Still skip future holds for renewals 2025-09-20 10:43:07 +02:00
Koha Bug 36536: Make REST APIs validateUserAndPassword update borrowers.lastseen 2025-09-20 10:43:14 +02:00
acqui Bug 39572: Improve EDIFACT order confirmation message 2025-07-24 10:23:14 +02:00
admin Bug 40395: (QA follow-up): Add checkbox column to table settings 2025-09-20 10:42:59 +02:00
api Bug 40395: Preparation: suspension_bulk REST API endpoint 2025-09-20 10:42:54 +02:00
authorities Bug 38514: Filter out autocomplete list of authorities with ConsiderHeadingUse 2025-08-22 09:47:58 +02:00
basket Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
bin
…
bookings Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
catalogue Bug 37883: Add ability to filter search results location column by logged in location 2025-09-16 14:02:11 +02:00
cataloguing Bug 37116: Redirect to serial modification when modifying an item 2025-09-20 10:42:40 +02:00
circ Bug 40515: Fix regexp for cud-mark_as_lost_and_notify 2025-09-20 10:43:13 +02:00
clubs Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
course_reserves Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
debian Bug 39906: (QA follow-up) Feature needs to be enabled specifically 2025-08-26 21:05:12 +02:00
docs Bug 40022: Sync teams in Koha, Wiki and release-tools 2025-07-10 22:47:12 +02:00
erm Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
errors Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
etc Bug 40304: Zebrasrv configs now work on ARM CPUs 2025-07-24 10:23:34 +02:00
ill Bug 40075: Only show pickup_location libraries 2025-08-22 09:48:34 +02:00
installer Bug 40071: MARC21 Addition to relator terms in technical notice 2025-06-04 2025-09-20 10:43:10 +02:00
koha-tmpl Bug 36536: Make REST APIs validateUserAndPassword update borrowers.lastseen 2025-09-20 10:43:14 +02:00
labels Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
lib Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
members Bug 40305: Fix 'tendered' vs 'collected' variable name inconsistency 2025-09-16 14:02:24 +02:00
misc Bug 35654: (follow-up) Update example script to be compatible with change to using Koha::Items 2025-09-20 10:43:04 +02:00
offline_circ Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
opac Bug 40075: Only show pickup_location libraries in OPAC 2025-08-22 09:48:34 +02:00
patron_lists Bug 37266: patron_lists/delete.pl should have CSRF protection 2025-03-06 13:54:49 +01:00
patroncards Bug 39800: Error 500 when trying to delete patron card template 2025-05-19 09:49:41 +02:00
plugins Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
pos Bug 40305: Fix 'tendered' vs 'collected' variable name inconsistency 2025-09-16 14:02:24 +02:00
preservation Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
recalls Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
reports Bug 40419: Fix wrong license 2025-07-24 10:23:34 +02:00
reserve Bug 40671: Update method calls from revert_waiting to revert_found 2025-09-20 10:43:02 +02:00
reviews Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
rotating_collections Bug 31930: Ignore whitespace before and after barcodes 2025-08-22 09:48:05 +02:00
serials Bug 34971: (QA follow-up) Op is now cud-reopen 2025-02-12 15:28:17 +01:00
services Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
skel
…
suggestion Bug 33430: (follow-up) Fix the data filtering from the left menu 2025-05-19 18:54:22 +02:00
svc Bug 39325: Manual fixes 2025-04-28 18:51:23 +02:00
t Bug 36536: Unit tests 2025-09-20 10:43:13 +02:00
tags Bug 38969: (QA follow-up) fix tidy 2025-04-28 18:51:18 +02:00
tools Bug 39900: Preparation: Move html customizations options to class for reusability 2025-09-20 10:42:42 +02:00
virtualshelves Bug 37434: Sort by publicationyear when copyrightdate is set in UNIMARC 2025-02-13 16:18:02 +01:00
xt Bug 40315: (QA follow-up) Fix shebang for both tests 2025-09-16 14:02:27 +02:00
.codespell-ignore Bug 39325: (QA follow-up) Adjust some issues 2025-04-28 18:51:30 +02:00
.editorconfig Bug 27375: Set YAML file settings in .editorconfig 2021-11-03 15:40:52 +01:00
.git-blame-ignore-revs Bug 39096: Add 'tidy all' commits to a git blame ignore file 2025-02-17 13:10:25 +01:00
.gitignore Bug 40539: Add cypress videos and screenshots to gitignore 2025-08-22 09:48:22 +02:00
.htaccess
…
.mailmap 25.05.00: Update .mailmap (part 4) 2025-05-26 10:19:09 -03:00
.perlcriticrc
…
.perltidyrc Bug 30002: Adjust perltidy 2023-06-08 08:32:42 -03:00
.prettierrc.js Bug 38664: Treat .vue files like other JS files 2025-02-11 14:58:25 +01:00
.proverc.dist
…
.stylelintrc.json Bug 31528: (follow-up) A few additional rules 2022-10-03 08:23:15 -03:00
INSTALL
…
Koha.pm Bug 35467: DBRev 25.05.03.007 2025-09-20 10:42:29 +02:00
LICENSE
…
MANIFEST.SKIP
…
Makefile.PL Bug 39834: Replace some tabs with spaces 2025-06-17 21:42:59 +02:00
README
…
README.md
…
README.robots
…
about.pl Bug 40608: (follow-up) Add warning in about page 2025-09-20 10:42:34 +02:00
app.psgi Bug 36149: Add userenv middleware to app.psgi 2024-05-14 15:04:37 -03:00
build-resources.PL Bug 32609: Use the current yarn.lock to generate node_modules 2023-02-10 11:07:57 -03:00
changelanguage.pl Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
cpanfile Bug 40164: Add Template::Plugin::JSON dependency 2025-07-10 22:47:33 +02:00
cypress.config.ts Bug 40346: Use KOHA_INTRANET_URL for the baseUrl 2025-08-22 09:47:41 +02:00
eslint.config.mjs Bug 38524: Enable ESLint for .ts and .vue files 2025-01-16 15:56:17 +01:00
fix-perl-path.PL Bug 39325: (QA follow-up) Adjust some issues 2025-04-28 18:51:30 +02:00
gulpfile.js Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
help.pl Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
kohaversion.pl Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
mainpage.pl Bug 38664: Tidy the whole codebase 2025-02-11 14:58:24 +01:00
package.json Bug 40170: Replace cypress-mysql with mysql2 - Cypress tests 2025-07-10 22:47:37 +02:00
rewrite-config.PL Bug 39834: Replace some tabs with spaces 2025-06-17 21:42:59 +02:00
rspack.config.js Bug 40173: Make http-client reusable from Cypress tests 2025-08-22 09:47:30 +02:00
tsconfig.json Bug 32030: Move cypress to t - fix build_js/watch_js 2022-11-08 09:44:52 -03:00
yarn.lock Bug 40170: Update yarn.lock 2025-07-10 22:47:42 +02:00

README.md

Koha is a free software integrated library system (ILS).

Koha is distributed under the GNU GPL version 3 or later.

Note: Koha does not accept pull requests from git hosting sites.

Note: This project has its own bug tracker, to report a bug or submit a patch visit http://bugs.koha-community.org.

For guidelines on submitting patches for Koha please visit https://wiki.koha-community.org/wiki/SubmitingAPatch

The developers handbook can be found at https://wiki.koha-community.org/wiki/Developer_handbook

http://koha-community.org/

Koha Logo