You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Find attached a patch which replaces the logout link (<a href=...) with a form. In order to maintain formatting
a label with a hidden submit button is used. I do not know if this works for all browsers.
Note: in urls.py the next_page parameter uses a plain ../ which might not do what is meant in all situations. It could be
replaced by reverse_lazy("helpdesk:home"), however I plan to integrate a more general solution in a future PR for improving
integration of django-helpdesk into a django-project with other apps.
To Reproduce
Steps to reproduce the behavior:
Install django-helpdesk with a Django version greater or equal to 4.1
Set up a user and login
Click on the "Logout" link in the user dropdown
Click on the back button of the browser and optionally reload
The user is still logged in.
Expected behavior
The user is logged out
The text was updated successfully, but these errors were encountered:
Hi uhurusurfa: please consider the attached patch, it's almost trivial, and my resources are bound. I have more enhancements with broader scope in preparation on which I'd like to focus.
Describe the bug
Since Django 4.1 the contributed
LogoutView
requires the POST method, see:https://docs.djangoproject.com/en/4.1/releases/4.1/#log-out-via-get
Find attached a patch which replaces the logout link (
<a href=
...) with a form. In order to maintain formattinga label with a hidden submit button is used. I do not know if this works for all browsers.
django_logout_post.patch.txt
Note: in
urls.py
thenext_page
parameter uses a plain../
which might not do what is meant in all situations. It could bereplaced by
reverse_lazy("helpdesk:home")
, however I plan to integrate a more general solution in a future PR for improvingintegration of django-helpdesk into a django-project with other apps.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The user is logged out
The text was updated successfully, but these errors were encountered: