Bug 35028 - Add OPAC self-registration alert on staff interface main page
Summary: Add OPAC self-registration alert on staff interface main page
Status: Pushed to main
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Julian Maurice
QA Contact: Lucas Gass (lukeg)
URL:
Keywords: additional_work_needed
Depends on:
Blocks:
 
Reported: 2023-10-11 12:54 UTC by Julian Maurice
Modified: 2025-02-04 10:12 UTC (History)
3 users (show)

See Also:
Change sponsored?: Sponsored
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
25.05.00
Circulation function:


Attachments
Bug 35028: Add pre-registrations alert on staff interface main page (7.85 KB, patch)
2023-10-11 12:54 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 35028: Add pre-registrations alert on staff interface main page (11.60 KB, patch)
2024-12-12 10:56 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 35028: Add self-registrations alert on staff interface main page (11.74 KB, patch)
2024-12-12 10:59 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 35028: Add self-registrations alert on staff interface main page (10.29 KB, patch)
2024-12-12 11:05 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 35028: Add self-registrations alert on staff interface main page (10.29 KB, patch)
2024-12-12 11:07 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 35028: Add self-registrations alert on staff interface main page (10.35 KB, patch)
2025-01-10 21:04 UTC, William Lavoie
Details | Diff | Splinter Review
Bug 35028: Add self-registrations alert on staff interface main page (10.41 KB, patch)
2025-01-14 17:11 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 35028: (QA follow-up) Fix file permission for DB update (622 bytes, patch)
2025-01-14 17:11 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Julian Maurice 2023-10-11 12:54:07 UTC

    
Comment 1 Julian Maurice 2023-10-11 12:54:58 UTC Comment hidden (obsolete)
Comment 2 Owen Leonard 2023-10-11 13:21:09 UTC
This looks like it works well but it assumes a procedure for self-registrations which is not necessarily universal. It sounds like the sponsoring library's workflow requires that self-registrations are reviewed by staff, and perhaps the patron category is updated after review?

By contrast, in my library we don't do a review of self-registrations which involves a category change. In our case these registrations are not "pre-registered" patrons, they're just patrons. Having a constantly increasing number displayed on the staff home page wouldn't be helpful.
Comment 3 Julian Maurice 2023-10-11 13:25:20 UTC
Should I add a syspref then ?
Comment 4 Katrin Fischer 2023-10-11 14:26:00 UTC
I think a system preference sounds good in that case.

I'd also change the terminology. We call the feature "self registration" and it's never appearing as pre-registered. - I'd suggest not to use a new term but stick to what we have already. Maybe:

Self registrations: 
OPAC self registrations:
Comment 5 Julian Maurice 2024-12-12 10:56:47 UTC Comment hidden (obsolete)
Comment 6 Julian Maurice 2024-12-12 10:59:14 UTC Comment hidden (obsolete)
Comment 7 Julian Maurice 2024-12-12 10:59:49 UTC
Patch rebased + added a new system preference as suggested
Comment 8 Julian Maurice 2024-12-12 11:05:28 UTC
Created attachment 175392 [details] [review]
Bug 35028: Add self-registrations alert on staff interface main page

This adds a new system preference PatronSelfRegistrationAlert to enable
or disable alerts (disabled by default)

Test plan:
1. Create patron category SELFREG
2. Enable PatronSelfRegistration and set
   PatronSelfRegistrationDefaultCategory to SELFREG and
   PatronSelfRegistrationAlert to "Show"
3. Go to OPAC, logout if needed, and create a new account. Remember the
   value you set for home library.
4. Go to staff interface, set the current library to the one you set in
   step 3.
5. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1 /
   <CURRENT LIBRARY>: 1" (numbers can vary if you already had
   self-registered patrons)
6. Click on both links and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)
7. Set the current library to another one (one that doesn't have
   self-registered patrons)
8. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1"
   (numbers can vary if you already had self-registered patrons)
9. Click on the link and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)

Co-authored-by: Fridolin Somers <fridolin.somers@biblibre.com>
Co-authored-by: Julian Maurice <julian.maurice@biblibre.com>
Sponsored-by: Écoles nationales supérieures d'architecture (ENSA)
Comment 9 Julian Maurice 2024-12-12 11:07:46 UTC
Created attachment 175393 [details] [review]
Bug 35028: Add self-registrations alert on staff interface main page

This adds a new system preference PatronSelfRegistrationAlert to enable
or disable alerts (disabled by default)

Test plan:
1. Create patron category SELFREG
2. Enable PatronSelfRegistration and set
   PatronSelfRegistrationDefaultCategory to SELFREG and
   PatronSelfRegistrationAlert to "Show"
3. Go to OPAC, logout if needed, and create a new account. Remember the
   value you set for home library.
4. Go to staff interface, set the current library to the one you set in
   step 3.
5. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1 /
   <CURRENT LIBRARY>: 1" (numbers can vary if you already had
   self-registered patrons)
6. Click on both links and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)
7. Set the current library to another one (one that doesn't have
   self-registered patrons)
8. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1"
   (numbers can vary if you already had self-registered patrons)
9. Click on the link and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)

Co-authored-by: Fridolin Somers <fridolin.somers@biblibre.com>
Co-authored-by: Julian Maurice <julian.maurice@biblibre.com>
Sponsored-by: Écoles nationales supérieures d'architecture (ENSA)
Comment 10 William Lavoie 2025-01-10 21:04:11 UTC
Created attachment 176399 [details] [review]
Bug 35028: Add self-registrations alert on staff interface main page

This adds a new system preference PatronSelfRegistrationAlert to enable
or disable alerts (disabled by default)

Test plan:
1. Create patron category SELFREG
2. Enable PatronSelfRegistration and set
   PatronSelfRegistrationDefaultCategory to SELFREG and
   PatronSelfRegistrationAlert to "Show"
3. Go to OPAC, logout if needed, and create a new account. Remember the
   value you set for home library.
4. Go to staff interface, set the current library to the one you set in
   step 3.
5. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1 /
   <CURRENT LIBRARY>: 1" (numbers can vary if you already had
   self-registered patrons)
6. Click on both links and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)
7. Set the current library to another one (one that doesn't have
   self-registered patrons)
8. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1"
   (numbers can vary if you already had self-registered patrons)
9. Click on the link and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)

Co-authored-by: Fridolin Somers <fridolin.somers@biblibre.com>
Co-authored-by: Julian Maurice <julian.maurice@biblibre.com>
Sponsored-by: Écoles nationales supérieures d'architecture (ENSA)
Signed-off-by: William Lavoie <william.lavoie@inLibro.com>
Comment 11 Lucas Gass (lukeg) 2025-01-14 17:10:44 UTC
Was using JS to do something like this previously. Nice to see it added for real. :)
Comment 12 Lucas Gass (lukeg) 2025-01-14 17:11:28 UTC
Created attachment 176522 [details] [review]
Bug 35028: Add self-registrations alert on staff interface main page

This adds a new system preference PatronSelfRegistrationAlert to enable
or disable alerts (disabled by default)

Test plan:
1. Create patron category SELFREG
2. Enable PatronSelfRegistration and set
   PatronSelfRegistrationDefaultCategory to SELFREG and
   PatronSelfRegistrationAlert to "Show"
3. Go to OPAC, logout if needed, and create a new account. Remember the
   value you set for home library.
4. Go to staff interface, set the current library to the one you set in
   step 3.
5. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1 /
   <CURRENT LIBRARY>: 1" (numbers can vary if you already had
   self-registered patrons)
6. Click on both links and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)
7. Set the current library to another one (one that doesn't have
   self-registered patrons)
8. Go to the staff interface main page. You should see at the bottom a
   message saying "Self-registrations from: All libraries: 1"
   (numbers can vary if you already had self-registered patrons)
9. Click on the link and verify that it shows the correct patrons (or
   redirect to the patron detail page if there is only one)

Co-authored-by: Fridolin Somers <fridolin.somers@biblibre.com>
Co-authored-by: Julian Maurice <julian.maurice@biblibre.com>
Sponsored-by: Écoles nationales supérieures d'architecture (ENSA)
Signed-off-by: William Lavoie <william.lavoie@inLibro.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Comment 13 Lucas Gass (lukeg) 2025-01-14 17:11:30 UTC
Created attachment 176523 [details] [review]
Bug 35028: (QA follow-up) Fix file permission for DB update

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Comment 14 Katrin Fischer 2025-02-03 13:26:42 UTC
Overall: I really like the idea of this and it's something libraries have definitely asked us about!

Since there is a system preference to completely turn this off, I am going to push, but some questions remain:

1) Permission check

We don't have a permission check. I feel that could lead to the situation where a staff user tries to resolve, but is then faced with a permission error trying to access the patron page as they are not allowed to view patron accounts of this library.

Could we do better here?

2) New vs. updated installations

Right now this feature has to always be explicitly activated. Should we install new installation with the feature defaulting to "Show"?

3) Database update

Please check the updated skeleton.pl for future database atomicupdates.
Also: this was missing any success message. Fixed before push.
Comment 15 Katrin Fischer 2025-02-03 13:29:16 UTC
Pushed for 25.05!

Well done everyone, thank you!