From f552b41f4b337e6844f71c29ff177915abbfa417 Mon Sep 17 00:00:00 2001 From: Alvin Li Date: Fri, 4 Oct 2013 23:56:35 +0800 Subject: * indicator/static/javascripts/card_chart.js: improved the display position of 'detail_card_info' * indicator/templates/indicator/SheetDefault.html: destroy 'qtip' when close card * added new app 'apps/sfaccount' * implemented 'signup' and 'activate' functions * implemented async sending activation mail (using 'django-celery' and 'redis') * moved 'registration/*' templates to 'sfaccount/templates' * implemented 'password_change' function: o password_change o password_change_done * implemented 'password_reset' function o password_reset o password_reset_done o password_reset_confirm o password_reset_complete o re-write 'sfaccount.fomrs.SFPasswordResetForm' o re-write 'sfaccount.views.password_reset_view' * improved 'sfaccount.functional' send mail functions o to send 'multipart' mail * added 'README.txt' * added app 'apps/recommend': for comparing with the SCI papers and then recommending most related papers for user. --- 97suifangqa/apps/profile/views.py | 31 ++++++++----------------------- 1 file changed, 8 insertions(+), 23 deletions(-) (limited to '97suifangqa/apps/profile/views.py') diff --git a/97suifangqa/apps/profile/views.py b/97suifangqa/apps/profile/views.py index c41e62b..e7d17e9 100644 --- a/97suifangqa/apps/profile/views.py +++ b/97suifangqa/apps/profile/views.py @@ -1,30 +1,15 @@ # -*- coding: utf-8 -*- from django.http import HttpResponse, HttpResponseRedirect -from django.conf import settings +from django.conf import settings from django.shortcuts import render -from django.contrib.auth.views import login, logout -from django.contrib.auth import login as auth_login -from .forms import UserCreationForm - - -def signup(request): - u''' - 用户注册 - ''' - if request.user.is_authenticated(): - return HttpResponseRedirect(settings.LOGIN_REDIRECT_URL) - - if request.method == 'POST': - form = UserCreationForm(request.POST) - if form.is_valid(): - user = form.save() - return HttpResponseRedirect(request.REQUEST.get('next')) - else: - form = UserCreationForm() - - return render(request, 'registration/signup.html', - locals()) +# profile home {{{ +def profile_view(request, username): + """ + show profile of given user + """ + return HttpResponse('Hi, %s' % username) +# }}} -- cgit v1.2.2