Udi Bauman avatar Udi Bauman committed 1c2e949 Merge


Comments (0)

Files changed (5)

File contents unchanged.


+from django.contrib.auth import authenticate, login
 from django.contrib.auth.models import User
 from django.contrib.sites.models import RequestSite
 from common.util import get_current_site
+            user = authenticate(username=email, password=password)
+            login(request, user)
             return user
 from django.db import models
 from django.utils.translation import ugettext as _
 from datetime import datetime
+from registration import signals
+import logging
 def model_to_dict(model):
     def to_dict(self):
         return model_to_dict(self)
+def create_user_profile(user, request, **kwargs):
+    map_id = request.REQUEST.get('map_id', False)
+    map = Map.objects.get(id = map_id)
+    logging.info('ffffffffffffffff %s' % map.group_profile)
+    profile = UserProfile.objects.create(user=user,group_profile = map.group_profile)
+    profile.save()

File contents unchanged.


+{% extends "admin/base_site.html" %}
+{% load i18n adminmedia %}
+{% load url from future %}
+{% block extrastyle %}{{ block.super }}<link rel="stylesheet" type="text/css" href="{% admin_media_prefix %}css/forms.css" />{% endblock %}
+{% block userlinks %}{% url 'django-admindocs-docroot' as docsroot %}{% if docsroot %}<a href="{{ docsroot }}">{% trans 'Documentation' %}</a> / {% endif %} {% trans 'Change password' %} / <a href="../logout/">{% trans 'Log out' %}</a>{% endblock %}
+{% block breadcrumbs %}<div class="breadcrumbs"><a href="/">{% trans 'Home' %}</a> &rsaquo; {% trans 'Password change' %}</div>{% endblock %}
+{% block title %}{% trans 'Password change' %}{% endblock %}
+{% block content %}<div id="content-main">
+<form action="" method="post">{% csrf_token %}
+{% if form.errors %}
+    <p class="errornote">
+    {% blocktrans count form.errors.items|length as counter %}Please correct the error below.{% plural %}Please correct the errors below.{% endblocktrans %}
+    </p>
+{% endif %}
+<h1>{% trans 'Password change' %}</h1>
+<p>{% trans "Please enter your old password, for security's sake, and then enter your new password twice so we can verify you typed it in correctly." %}</p>
+<fieldset class="module aligned wide">
+<div class="form-row">
+    {{ form.old_password.errors }}
+    <label for="id_old_password" class="required">{% trans 'Old password' %}:</label>{{ form.old_password }}
+<div class="form-row">
+    {{ form.new_password1.errors }}
+    <label for="id_new_password1" class="required">{% trans 'New password' %}:</label>{{ form.new_password1 }}
+<div class="form-row">
+{{ form.new_password2.errors }}
+    <label for="id_new_password2" class="required">{% trans 'Password (again)' %}:</label>{{ form.new_password2 }}
+<div class="submit-row">
+    <input type="submit" value="{% trans 'Change my password' %}" class="default" />
+<script type="text/javascript">document.getElementById("id_old_password").focus();</script>
+{% endblock %}
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.