Bug 38658 - SIP not marking patrons expired unless NotifyBorrowerDeparture has a positive value
Summary: SIP not marking patrons expired unless NotifyBorrowerDeparture has a positive...
Status: Signed Off
Alias: None
Product: Koha
Classification: Unclassified
Component: SIP2 (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Matthias Meusburger
QA Contact: Testopia
URL:
Keywords:
Depends on: 25813
Blocks:
  Show dependency treegraph
 
Reported: 2024-12-09 19:45 UTC by Nick Clemens (kidclamp)
Modified: 2025-01-02 17:51 UTC (History)
0 users

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


Attachments
Bug 38658: Display message for expired patrons in SIP when NotifyBorrowerDeparture is disabled (4.26 KB, patch)
2024-12-27 13:54 UTC, Matthias Meusburger
Details | Diff | Splinter Review
Bug 38658: Display message for expired patrons in SIP when NotifyBorrowerDeparture is disabled (4.32 KB, patch)
2025-01-02 17:51 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 Nick Clemens (kidclamp) 2024-12-09 19:45:52 UTC
Bug 25813 changed the way that SIP reports patron expiry. 

Prior to this bug patrons could eb marked as expired without setting this pref, now it requires a value.

To recreate:
0 - Set NotifyBorrowerDeparture to 30
1 - Set a patron's expiry date to be in the past, I used Edna Acosta
2 - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -t CR --patron 23529001000463 -m patron_information
3 - Note you are warned patron is expired
4 - Set NotifyBorrowerDeparture to 0
5 - repeat 2
6 - No notice that patron is expired, and patron status does not show any blocks
Comment 1 Matthias Meusburger 2024-12-27 13:54:56 UTC
Created attachment 175954 [details] [review]
Bug 38658: Display message for expired patrons in SIP when NotifyBorrowerDeparture is disabled

This patch restores the behavior that existed in SIP before Bug 25813 - Enhance patron expiration in SIP display:
Always consider an expired patron as expired, even if NotifyBorrowerDeparture is set to 0 (disabled) or unset.

Test plan:

 - Set NotifyBorrowerDeparture to 0

 - Set a patron's expiry date to be in the past

 - Use misc/sip_cli_emulator.pl to display patron information:
   perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -t CR --patron <cardnumber> -m patron_information

 - Check that you have the following message (AF field):
 "Greetings from Koha. Your account has expired as of <expired date>"
Comment 2 Matthias Meusburger 2024-12-27 14:01:50 UTC
Please note that the behavior with NotifyBorrowerDeparture now differs in SIP and at the OPAC, where no warning is displayed to an expired patron when NotifyBorrowerDeparture is disabled or unset.

To be fair, now that you've pointed it, I find it strange that the warning about being expired is not displayed at the OPAC when NotifyBorrowerDeparture is disabled or unset, but that can be the subject of another bug.
Comment 3 Lucas Gass (lukeg) 2025-01-02 17:51:42 UTC
Created attachment 176099 [details] [review]
Bug 38658: Display message for expired patrons in SIP when NotifyBorrowerDeparture is disabled

This patch restores the behavior that existed in SIP before Bug 25813 - Enhance patron expiration in SIP display:
Always consider an expired patron as expired, even if NotifyBorrowerDeparture is set to 0 (disabled) or unset.

Test plan:

 - Set NotifyBorrowerDeparture to 0

 - Set a patron's expiry date to be in the past

 - Use misc/sip_cli_emulator.pl to display patron information:
   perl misc/sip_cli_emulator.pl -a localhost -p 6001 -su term1 -sp term1 -l CPL -t CR --patron <cardnumber> -m patron_information

 - Check that you have the following message (AF field):
 "Greetings from Koha. Your account has expired as of <expired date>"

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>