Info: | Wrapper of django-impersonate for django-oscar |
---|---|
Version: | 0.1.3 |
Author: | Nicolas Dubois <[email protected]> |
- It was written for Python 3.3+ and Django 1.6+
- It depends on your project using the
django.contrib.session
framework (requirement
from django-impersonate
)
$ pip install django-oscar-impersonate
django-oscar-impersonate
relies on ``django-impersonate` (which is installed )
- Add
impersonate
to yourINSTALLED_APPS
INSTALLED_APPS = ( # … 'impersonate', )
- Add
- Add
django-oscar-impersonate
middleware MIDDLEWARE_CLASSES = ( # … 'oscar_impersonate.middleware.OscarImpersonateMiddleware', )
- Add
- Add
django-impersonate
URLs urlpatterns = patterns('', # … url(r'^impersonate/', include('impersonate.urls')), # … )
- Add
- Add
OSCAR_IMPERSONATE_TEMPLATE_DIRS
toTEMPLATE_DIRS
, before Oscar's from oscar import OSCAR_MAIN_TEMPLATE_DIR from oscar_impersonate import OSCAR_IMPERSONATE_TEMPLATE_DIR TEMPLATE_DIRS = ( # … OSCAR_IMPERSONATE_TEMPLATE_DIR, OSCAR_MAIN_TEMPLATE_DIR, )
- Add
django-oscar-impersonate
adds a “Log as” button on customers' dashboard:
When a staff member impersonates a customer, a button appears to stop impersonation.
When a staff member impersonates a customer, a small toolbar appears at the top to display who is impersonated
For other features and custom settings, please check django-impersonate
's docs.
BSD License