Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RST-5599 add password reset button when admin logged in #55

Merged
merged 3 commits into from
Sep 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion admin/password_reset/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def index():
for key, value in session.items():
logger.log(LogLevel.INFO, f"Session entry: {key} = {value}")

if 'email' not in session:
if 'emailAddress' not in session and 'signedIn' not in session:
logger.log(LogLevel.WARN, f"Forgotten password accessed for no user")
return local_redirect(url_for('forgot_password.index'))

Expand Down
5 changes: 5 additions & 0 deletions admin/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@
Tools
</a>
</li>
<li class="govuk-header__navigation-item">
<a href="{{ url_for('password_reset.index') }}" class="govuk-header__link">
Reset password
</a>
</li>
<li class="govuk-header__navigation-item">
<a href="{{ url_for('signout.index') }}" class="govuk-header__link">
Sign out
Expand Down
Loading