This document covers various components of pinax.apps.account.
Required. This setting is used to control whether or not email verification is sent upon signup:
ACCOUNT_EMAIL_VERIFICATION = True
The name defined in the URLconf that maps to the url that the user will be redirected to after login success.
LOGIN_REDIRECT_URLNAME = "home"
Required. Permit signing up for an account via OpenID.
ACCOUNT_OPEN_SIGNUP = True
The named URLs in this app should enable the use of of the {% url %} template tag as well as reverse lookups in your project code without having to know the implementation details of this app.
This is the URL that on POST will process a number of actions related to an email address on an account and on GET will render a template that provides the email form in context.
This URL will process a form to create an account on POST and render a template with a signup form instance in context on GET requests.
Process a login request from POST requests and render a template with a login form instance in context on GET requests.
Process the login POST request while associating submitted OpenID credentials to the account if they don’t already exist.
Process a password change form POST or render a template with a password change form instance in context.
Process a password set form POST or render a template with a password set form instance in context.
Process a password delete form POST or render a template with a password delete form instance in context.
Renders static template to inform user that the password delete is complete.
Processes a timezone form POST request to change a user’s timezone or renders a template with the timezone change form instance in context.
Adds credentials for Twitter on form POST, or renders a template with the form instance in context.
Removes Twitter account association with user.
Processes a default language selection form POST request or renders a template with the language change form in context.
Calls the django.contrib.auth.views.logout view.
Calls the emailconfirmation.views.confirm_email view.
arguments: | The token generated in the emailconfirmation app that matches (\w+). |
---|
Process a password reset form POST request and redirect to acct_passwd_reset_done or render a template with the password reset form instance in context.
Renders a template confirming the password reset process is complete.
Process a password reset using user key form POST request or render a template with the form in context.
keyword arguments: | |
---|---|
The UUID and Key for the reset reset request that matches (?P<uidb36>[0-9A-Za-z]+)-(?P<key>.+) |
Calls the ajax_validation.views.validate view with the pinax.apps.account.forms.SignupForm.
Templates should be placed in an account/ folder at the root of one of your template search paths.
context: | group, form, url_required, redirect_field_name, redirect_field_value |
---|
context: | group, form, redirect_field_name, redirect_field_value |
---|
context: | group, email, success_url |
---|
context: | group, add_email_form |
---|
context: | group, password_change_form |
---|
context: | group, password_set_form |
---|
context: | group |
---|
context: | None |
---|
context: | group, password_reset_form |
---|
context: | group |
---|
If there is a valid token:
context: | group, form |
---|
otherwise:
context: | group, token_fail = True |
---|
context: | group, form |
---|
context: | group, form |
---|
context: | group, twitter_form, twitter_authorized |
---|
This is a very simple middleware that parses a request and decides what translation object to install in the current thread context depending on the user’s account. This allows pages to be dynamically translated to the language the user desires (if the language is available, of course).
Account(id, user_id, timezone, language)
OtherServiceInfo(id, user_id, key, value)
PasswordReset(id, user_id, temp_key, timestamp, reset)
retrieve the other service info for given key for the given user.
return default_value (“”) if no value.
update the other service info for the given user using the given keyword args.
e.g. update_other_services(user, twitter_user=..., twitter_password=...)
Example usage:
{% user_display user %}
or if you need to use in a {% blocktrans %}:
{% user_display user as user_display}
{% blocktrans %}{{ user_display }} has sent you a gift.{% endblocktrans %}
Returns the URL to be used in login procedures by looking at different values in the following order: