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

Requesting an easier way to return to control panel after impersonating a user #7281

Closed
sparkalow opened this issue Dec 16, 2020 · 3 comments
Labels
enhancement improvements to existing features user management 😇 features related to user management
Milestone

Comments

@sparkalow
Copy link

Description

Impersonating a user is a great feature. Thank you! It's especially useful for some e-commerce administrators. Id like to request that getting back to the control panel as an admin, after impersonating a user, be improved if possible.

Currently, you impersonate a user from the control panel and are taken to the frontend. When you're ready to return to the control panel you must logout of the impersonated user's account and re-login to the admin.

I'd like to request a way to get back to the admin without logging out and then logging back in. Not sure the best way to handle this, but perhaps a route and maybe an event/session var to allow developers to output a button returning to the control panel on the frontend would work.

@brandonkelly brandonkelly added enhancement improvements to existing features user management 😇 features related to user management and removed enhancement labels Dec 17, 2020
@brandonkelly brandonkelly added this to the 3.6 milestone Dec 17, 2020
brandonkelly added a commit that referenced this issue Dec 17, 2020
@brandonkelly
Copy link
Member

Just came up with what I think is a pretty nice solution to this.

In Craft 3.6 there will be a new user action after “Login as [username]”, called “Copy impersonation URL”:

The user action menu, with the new “Copy impersonation URL” option highlighted

When you click it, Craft will generate a single-use tokenized URL, and then prompt you to copy it:

The “Copy URL” prompt

You’ll then be able to copy the URL and paste it into a new private/incognito window, which will log you in as the user and redirect you to either the control panel or front end, depending on whether they have CP access.

@brandonkelly
Copy link
Member

Craft 3.6 RC3 is out now with that change.

@brandonkelly
Copy link
Member

Craft 3.6 has now been officially released ✨

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement improvements to existing features user management 😇 features related to user management
Projects
None yet
Development

No branches or pull requests

2 participants