Bug 1980809 - Logout reason not displayed on login screen
Summary: Logout reason not displayed on login screen
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-dashboard-theme
Version: 16.1 (Train)
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: z8
: 16.1 (Train on RHEL 8.2)
Assignee: Radomir Dopieralski
QA Contact: ikanias
URL:
Whiteboard:
Depends On:
Blocks: 2058283 2058290
TreeView+ depends on / blocked
 
Reported: 2021-07-09 15:12 UTC by Radomir Dopieralski
Modified: 2022-12-07 20:25 UTC (History)
2 users (show)

Fixed In Version: openstack-dashboard-theme-16.0.3-2.el8ost
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2058283 (view as bug list)
Environment:
Last Closed: 2022-12-07 20:24:45 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker OSP-6089 0 None None None 2021-12-01 14:21:50 UTC
Red Hat Product Errata RHBA-2022:8795 0 None None None 2022-12-07 20:25:09 UTC

Description Radomir Dopieralski 2021-07-09 15:12:41 UTC
Description of problem:

With the downstream theme enabled, Horizon does not display the logout reason on the login screen.

How reproducible:

Always.

Steps to Reproduce:
1. Login into Horizon.
2. Change your password.
3. The login screen should show text "Password changed. Please log in again to continue."

Actual results:

The text is not visible anywhere on the login screen.

Expected results:

The text should be visible.

Additional info:

This is probably due to wrong nesting of IF blocks in the _login.html template:

    {% if request.user.is_authenticated and 'next' in request.GET %}
    <div class="control-group clearfix error">
      <span class="help-inline"><p>{% trans "You don't have permissions to access:" %}</p>
        <p><b>{{ request.GET.next }}</b></p>
        <p>{% trans "Login as different user or go back to" %}
        <a href="{% url 'horizon:user_home' %}">{% trans "home page" %}</a></p>
      </span>
    </div>
    {% if request.COOKIES.logout_reason %}
    <div class="form-group clearfix error" id="logout_reason">
        <span class="help-block alert alert-danger"><p>{{ request.COOKIES.logout_reason }}</p></span>
    </div>
    {% endif %}

    {% endif %}

Note that one of the ENDIF statements should be moved to right before the second IF.

Comment 15 errata-xmlrpc 2022-12-07 20:24:45 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Red Hat OpenStack Platform 16.1.9 bug fix and enhancement advisory), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2022:8795


Note You need to log in before you can comment on or make changes to this bug.