Skip to content

fix(records): use header login URL in restricted files notice#807

Open
TahaKhan998 wants to merge 1 commit into
CERNDocumentServer:masterfrom
TahaKhan998:fix/issue-798-restricted-record-login-link
Open

fix(records): use header login URL in restricted files notice#807
TahaKhan998 wants to merge 1 commit into
CERNDocumentServer:masterfrom
TahaKhan998:fix/issue-798-restricted-record-login-link

Conversation

@TahaKhan998
Copy link
Copy Markdown

@TahaKhan998 TahaKhan998 commented Jun 4, 2026

Closes #798
When you're logged out and view a public record with restricted files, the "Log in" link in the red Files notice goes to /account/settings/login instead of the normal login page. This PR fixes that in detail.html by using the same login URL as the header button , so both links go to /login/?next=....

Anonymous users on public records with restricted files saw a Log in
link to /account/settings/login. Override the files access message to
use url_for_security('login', next=request.path), matching the header.
@TahaKhan998 TahaKhan998 force-pushed the fix/issue-798-restricted-record-login-link branch from 9308664 to 24b4e87 Compare June 5, 2026 08:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Restricted record "log in" link redirects to wrong page

1 participant