Bug 41796

Summary: "Forgot your password" link is not visible if OpacResetPassword is enabled but OpacPasswordChange is disabled
Product: Koha Reporter: Lari Taskula <lari.taskula>
Component: OPACAssignee: Lari Taskula <lari.taskula>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low    
Version: unspecified   
Hardware: All   
OS: All   
GIT URL: Initiative type: ---
Sponsorship status: --- Comma delimited list of Sponsors:
Crowdfunding goal: 0 Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 41796: "Forgot your password" link is not visible if OpacResetPassword is enabled but OpacPasswordChange is disabled

Description Lari Taskula 2026-02-09 09:46:28 UTC
"Forgot your password" is not visible if OpacResetPassword is enabled but OpacPasswordChange is disabled

"OpacResetPassword" / "Forgot your password" is the functionality that patrons can use to reset a forgotten password using a recovery link that is sent to their email. This is a feature controlled by system preference "OpacResetPassword".

"OpacPasswordChange" is the functionality that logged in patrons can use to change their password, provided that they remember their current password.

OpacPasswordChange should not be linked to OpacResetPassword.
Comment 1 Lari Taskula 2026-02-09 10:52:07 UTC
Created attachment 192727 [details] [review]
Bug 41796: "Forgot your password" link is not visible if OpacResetPassword is enabled but OpacPasswordChange is disabled

Before applying this patch, to reproduce the issue:
1. Set system preference OpacResetPassword to 'not allowed'
2. Set system preference OpacPasswordChange to 'Don't allow'
3. Set preference opacuserlogin to 'Allow'
4. Navigate to OPAC
5. Observe no "Forgot your password?" link on the OPAC main page
6. Set system preference OpacResetPassword to 'allowed'
7. Observe no "Forgot your password?" link on the OPAC main page
8. Set system preference OpacPasswordChange 'Allow'
9. Observe "Forgot your password?" link is present on the OPAC main page.

Instead, it should be already present when OpacResetPassword is allowed.

To test this patch:
1. Apply this patch
2. Set system preference OpacResetPassword to 'not allowed'
3. Set system preference OpacPasswordChange to 'Don't allow'
4. Set preference opacuserlogin to 'Allow'
5. Navigate to OPAC
6. Observe no "Forgot your password?" link on the OPAC main page
7. Set system preference OpacResetPassword to 'allowed'
8. Observe "Forgot your password?" link is present