def bind(request):
    name = setting('SOCIAL_AUTH_PARTIAL_PIPELINE_KEY', 'partial_pipeline')
    try:
        backend = request.session[name]['backend']
    except:
        return redirect("account_login")
    c = {}
    if request.method == 'GET':
        form = SocialSignupForm()
    else:
        timestamp = int(time.time() * 1000)
        password = random.randrange(timestamp - 100000, timestamp)
        form = SocialSignupForm(request.POST)
        if form.is_valid():
            signup_view = SignupView()
            signup_view.request = request
            form.cleaned_data['password'] = password
            form.cleaned_data['password_confirm'] = password
            signup_view.form_valid(form)
            request.session['pass_bind'] = True
            return redirect('socialauth_complete', backend=backend)
    c['form'] = form
    c['backend'] = backend
    return render(request, 'misc/bind.html', c)
Exemple #2
0
def bind(request):
    name = setting('SOCIAL_AUTH_PARTIAL_PIPELINE_KEY', 'partial_pipeline')
    try:
        backend = request.session[name]['backend']
    except:
        return redirect("account_login")
    c = {}
    if request.method == 'GET':
        form = SocialSignupForm()
    else:
        timestamp = int(time.time() * 1000)
        password = random.randrange(timestamp - 100000, timestamp)
        form = SocialSignupForm(request.POST)
        if form.is_valid():
            signup_view = SignupView()
            signup_view.request = request
            form.cleaned_data['password'] = password
            form.cleaned_data['password_confirm'] = password
            signup_view.form_valid(form)
            request.session['pass_bind'] = True
            return redirect('socialauth_complete', backend=backend)
    c['form'] = form
    c['backend'] = backend
    return render(request, 'misc/bind.html', c)
Exemple #3
0
from __future__ import unicode_literals

from django.conf.urls import url

from account.views import SignupView, LoginView, LogoutView, DeleteView
from account.views import ConfirmEmailView
from account.views import ChangePasswordView, PasswordResetView, PasswordResetTokenView
from account.views import SettingsView


<<<<<<< HEAD
urlpatterns = [
    #url(r"^signup/$", SignupView.as_view(), name="account_signup"),
    url(r"^register/$", SignupView.as_view(), name="account_signup"),
    url(r"^login/$", LoginView.as_view(), name="account_login"),
    url(r"^logout/$", LogoutView.as_view(), name="account_logout"),
    url(r"^confirm_email/(?P<key>\w+)/$", ConfirmEmailView.as_view(), name="account_confirm_email"),
    url(r"^password/$", ChangePasswordView.as_view(), name="account_password"),
    url(r"^password/reset/$", PasswordResetView.as_view(), name="account_password_reset"),
    url(r"^password/reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$", PasswordResetTokenView.as_view(), name="account_password_reset_token"),
    url(r"^settings/$", SettingsView.as_view(), name="account_settings"),
    url(r"^delete/$", DeleteView.as_view(), name="account_delete"),
]
Exemple #4
0
from django.conf.urls import include, url
from account.forms import QuizAuthenticationForm
from account.views import SignupView

urlpatterns = [
    url(r'^signup/$', SignupView.as_view(), name='signup'),
    url(r'^login/$',
        'django.contrib.auth.views.login', {
            'authentication_form': QuizAuthenticationForm,
        },
        name='login'),
    url(r'', include('django.contrib.auth.urls')),
]
Exemple #5
0
# -*- coding: utf-8 -*-
from __future__ import unicode_literals

try:
    from django.conf.urls import patterns, include, url
except ImportError:
    from django.conf.urls.defaults import patterns, include, url
from django.contrib import admin
from test.example_thirdparty.forms import SignupFormWithCaptcha

admin.autodiscover()

from account.views import ChangePasswordView, SignupView, LoginView

urlpatterns = patterns(
    '',
    url(r'^admin/', include(admin.site.urls)),

    # aliases to match original django-registration urls
    url(r"^accounts/password/$",
        ChangePasswordView.as_view(),
        name="auth_password_change"),
    url(r"^accounts/signup/$",
        SignupView.as_view(form_class=SignupFormWithCaptcha),
        name="registration_register"),
    url(r"^accounts/login/$", LoginView.as_view(), name="auth_login"),
    url(r'^accounts/', include('account.urls')),
    url(r'^captcha/', include('captcha.urls')),
    url(r'^', include('pybb.urls', namespace='pybb')),
)
Exemple #6
0
# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from account.views import ChangePasswordView, SignupView, LoginView
from django.conf.urls import include, url
from django.contrib import admin
from example_thirdparty.forms import SignupFormWithCaptcha

urlpatterns = [
    url(r"^admin/", include(admin.site.urls)),
    # aliases to match original django-registration urls
    url(r"^accounts/password/$", ChangePasswordView.as_view(), name="auth_password_change"),
    url(r"^accounts/signup/$", SignupView.as_view(form_class=SignupFormWithCaptcha), name="registration_register"),
    url(r"^accounts/login/$", LoginView.as_view(), name="auth_login"),
    url(r"^accounts/", include("account.urls")),
    url(r"^captcha/", include("captcha.urls")),
    url(r"^", include("pybb.urls", namespace="pybb")),
]
from django.conf.urls import include, url
from account.forms import QuizAuthenticationForm
from account.views import SignupView

urlpatterns = [
    url(r'^signup/$', SignupView.as_view(), name='signup'),
    url(r'^login/$', 'django.contrib.auth.views.login', {
        'authentication_form': QuizAuthenticationForm,
    }, name='login'),
    url(r'', include('django.contrib.auth.urls')),
]

Exemple #8
0
from dal import autocomplete
from django.urls import path
from django.conf.urls import url
from account.views import (
    LoginView,
    PhotoSignatureView,
    ProfileView,
    SignupView,
    organization_autocomplete,
    school_autocomplete,
    VerificationView,
)
from account.models import School
urlpatterns = [
    path('login/', LoginView.as_view(), name='login'),
    path('signup/', SignupView.as_view(), name="signup"),
    path('signup/photo-signature/<pk>',
         PhotoSignatureView.as_view(),
         name="photo-sig"),
    path('activate/<uidb64>/<token>',
         VerificationView.as_view(),
         name='activate'),
    path('profile/', ProfileView.as_view(), name="profile"),
    url(r'^school-autocomplete/$',
        school_autocomplete.as_view(create_field='school_name'),
        name='school-autocomplete'),
    url(r'^organization-autocomplete/$',
        organization_autocomplete.as_view(create_field='organization_name'),
        name='organization-autocomplete')
]
Exemple #9
0
# -*- coding: utf-8 -*-
try:
    from django.conf.urls import patterns, include, url
except ImportError:
    from django.conf.urls.defaults import patterns, include, url
from django.contrib import admin

admin.autodiscover()

from account.views import ChangePasswordView, SignupView, LoginView

urlpatterns = patterns('',
    url(r'^admin/', include(admin.site.urls)),
    url(r'^accounts/', include('account.urls')),

    # aliases to match original django-registration urls
    url(r"^accounts/password/$", ChangePasswordView.as_view(), name="auth_password_change"),
    url(r"^accounts/signup/$", SignupView.as_view(), name="registration_register"),
    url(r"^accounts/login/$", LoginView.as_view(), name="auth_login"),

    url(r'^', include('pybb.urls', namespace='pybb')),
)
Exemple #10
0
     LoginView.as_view(allow_token=True,
                       after_login_callback=callback_on_login,
                       debug_dispatch_method=False,
                       template_name="account/account_form_as_ul.html",
                       delete_token_after_use=True),
     name='login'),
 url(r'^logout/$',
     LogoutView.as_view(redirect_to='/',
                        clean_response_cookies=True,
                        debug_dispatch_method=False),
     name='logout'),
 url(r'^signup/$',
     SignupView.as_view(model=Account,
                        use_captcha=True,
                        additional_exclude_formfields=['token'],
                        require_formfields=['email'],
                        after_signup_callback=callback_on_signup,
                        debug_dispatch_method=True,
                        debug_dispatch_method_full=False,
                        template_name="account/account_form_as_ul.html"),
     name='signup'),
 url(r'^password/change/((?P<slug>\d+)/)?$',
     ChangePasswordView.as_view(
         model=Account,
         use_login_required_decorator=True,
         template_name="account/account_form_as_ul.html",
         change_done_template_name="account/pswchanged.html",
         slug_field="id"),
     name='chpsw'),
 url(r'^password/forgot/((?P<token>.+)/)?$',
     ForgotPasswordView.as_view(
         template_name="account/account_form_as_ul.html",
Exemple #11
0
"""waterlily URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/1.10/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  url(r'^$', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  url(r'^$', Home.as_view(), name='home')
Including another URLconf
    1. Import the include() function: from django.conf.urls import url, include
    2. Add a URL to urlpatterns:  url(r'^blog/', include('blog.urls'))
"""
from django.conf.urls import url
from django.contrib import admin

from account.views import LoginView, LogoutView, IsLoggedInView, SignupView, ForgotUsernamePasswordView, \
    ResetPasswordView

urlpatterns = [
    url(r'^signup/', SignupView.as_view()),
    url(r'^login/', LoginView.as_view()),
    url(r'^forgot-password/', ForgotUsernamePasswordView.as_view()),
    url(r'^reset-password/', ResetPasswordView.as_view()),
    url(r'^logout/', LogoutView.as_view()),
    url(r'^is-logged-in/', IsLoggedInView.as_view()),
]
Exemple #12
0
from django.urls import path

from account.views import (
    ChangePasswordView,
    ConfirmEmailView,
    DeleteView,
    LoginView,
    LogoutView,
    PasswordResetTokenView,
    PasswordResetView,
    SettingsView,
    SignupView,
)

urlpatterns = [
    path("signup/", SignupView.as_view(), name="account_signup"),
    path("login/", LoginView.as_view(), name="account_login"),
    path("logout/", LogoutView.as_view(), name="account_logout"),
    path("confirm_email/<str:key>/",
         ConfirmEmailView.as_view(),
         name="account_confirm_email"),
    path("password/", ChangePasswordView.as_view(), name="account_password"),
    path("password/reset/",
         PasswordResetView.as_view(),
         name="account_password_reset"),
    path("password/reset/<str:uidb36>/<str:token>/",
         PasswordResetTokenView.as_view(),
         name="account_password_reset_token"),
    path("settings/", SettingsView.as_view(), name="account_settings"),
    path("delete/", DeleteView.as_view(), name="account_delete"),
]
Exemple #13
0
from account.views import SignupView
from django.conf.urls import patterns, include, url
from django.conf.urls.static import static
from django.conf import settings
from django.contrib import admin
from django.views.generic.base import TemplateView
from pybbm_org.forms import PybbmRegistrationForm

admin.autodiscover()

urlpatterns = patterns(
    '',
    url(r'^robots.txt$', TemplateView.as_view(template_name='robots.txt')),
    url(r'^admin/', include(admin.site.urls)),
    url(r'^', include('pybb.urls', namespace='pybb')),
    url(r'^accounts/signup/$',
        SignupView.as_view(form_class=PybbmRegistrationForm),
        name='registration_register'),
    url(r"^accounts/", include("account.urls")),
    url(r'^captcha/', include('captcha.urls')),
) + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
 def test_get(self):
     request = self.factory.get(reverse("account_signup"))
     response = SignupView.as_view()(request)
     self.assertEqual(response.status_code, 200)
Exemple #15
0
from account.views import SignupView
from account.views import CreateUserView
from django.contrib.auth.views import LoginView
from django.contrib.auth.views import LogoutView
from django.contrib.auth.views import PasswordResetView
from django.contrib.auth.views import PasswordResetDoneView
from django.contrib.auth.views import PasswordResetConfirmView
from django.contrib.auth.views import PasswordResetCompleteView
from django.contrib.auth.views import PasswordChangeView
from django.contrib.auth.views import PasswordChangeDoneView
from account.views import index

urlpatterns = [

    path("index",index,name="index"),
    path("signup",SignupView.as_view(),name = 'signup'),
    path('login/', LoginView.as_view(template_name='account/login.html'), name='login'),
    path('logout/', LogoutView.as_view(), name='logout'),
    path('password_reset/', 
        PasswordResetView.as_view(template_name="account/password_reset_form.html"), name='password_reset'),
    path('password_reset/done/', PasswordResetDoneView.as_view(
        template_name="account/password_reset_done.html"), name='password_reset_done'),
    path('reset/<uidb64>/<token>/', PasswordResetConfirmView.as_view(
        template_name="account/password_confirm.html"), name='password_reset_confirm'),
    path('reset/done/', PasswordResetCompleteView.as_view(
        template_name="account/password_reset_complete.html"), name='password_reset_complete'),
    path('password_change/', PasswordChangeView.as_view(
        template_name="account/password_change_form.html"), name='password_change'),
    path('password_change/done/', PasswordChangeDoneView.as_view(
        template_name="account/password_change_done.html"), name='password_change_done'),
    path("create_user",CreateUserView.as_view(),name="create_user"),
Exemple #16
0
from django.conf.urls import url
from account.views import AddressView, LoginView, SignupView, InstitutionView, TokenView, UserView, UserFormView

urlpatterns = [
    url('login', LoginView.as_view()),
    url('^signup', SignupView.as_view()),
    url('^institutionsignup', InstitutionView.as_view()),
    url('token', TokenView.as_view()),

    url('users/(?P<id>[0-9]+)', UserView.as_view()),
    url('users', UserView.as_view()),
#     url('user', UserFormView.as_view()),
    url('addresses', AddressView.as_view())
]
Exemple #17
0
v1_api = Api(api_name='v1')
v1_api.register(BookmarkResource())
v1_api.register(ListResource())
v1_api.register(UserResource())
v1_api.register(FeedbackResource())
v1_api.register(FollowResource())
v1_api.register(CommentResource())
v1_api.register(ListInvitationResource())
v1_api.register(UserTourResource())
v1_api.register(FeedCountResource())

urlpatterns = patterns("",
    url(r"^admin/", include(admin.site.urls)),
    #url(r'adminx/', include(xadmin.site.urls)),
    url(r'^harvest/', include("harvest.urls")),
    url(r"^accounts/signup/$", SignupView.as_view(form_class=SignupForm), name="account_signup"),
    url(r"^accounts/settings/$", SettingsView.as_view(form_class=SettingsForm), name="account_settings"),
    url(r"^accounts/login/$", LoginView.as_view(form_class=LoginEmailOrUsernameForm), name="account_login"),

    url(r'', include('social_auth.urls')),
    url(r'misc/', include('misc.urls')),
    url(r"^accounts/", include("account.urls")),
    url(r'^api/', include(v1_api.urls)),
    url(r'^comments/', include('django.contrib.comments.urls')),
    url(r'^profiles/profile/(?P<username>\w+)/', redirect_to, {'url': '/profiles/edit'}),
    url(r'^help/', direct_to_template, {'template': 'help.html'}, name="help"),
    url(r'^about/', direct_to_template, {'template': 'about.html'}, name="about"),
    url(r'^profiles/', include('idios.urls')),
    url(r'^invite/', include('kaleo.urls')),
    url(r'^notifications/', include('notifications.urls', namespace="notifications")),
    url(r'^avatar/', include('avatar.urls')),
Exemple #18
0
# -*- coding: utf-8 -*-
from django.conf.urls import patterns, include, url
from django.contrib import admin

admin.autodiscover()

from account.views import ChangePasswordView, SignupView, LoginView

urlpatterns = patterns(
    '',
    url(r'^admin/', include(admin.site.urls)),
    url(r'^accounts/', include('account.urls')),

    # aliases to match original django-registration urls
    url(r"^accounts/password/$",
        ChangePasswordView.as_view(),
        name="auth_password_change"),
    url(r"^accounts/signup/$",
        SignupView.as_view(),
        name="registration_register"),
    url(r"^accounts/login/$", LoginView.as_view(), name="auth_login"),
    url(r'^', include('pybb.urls', namespace='pybb')),
)
Exemple #19
0
from django.urls import path
from . import views
from account.views import SignupView, profile
from django.contrib.auth import views as auth_views

urlpatterns = [
    #path("",views.index, name='blog home'),
    path('signup/', SignupView.as_view(), name='signup'),
    path('login/',
         auth_views.LoginView.as_view(template_name='account/login.html'),
         name='login'),
    path('logout/',
         auth_views.LogoutView.as_view(template_name='account/logout.html'),
         name='logout'),
    path('profile/', views.profile, name='profile'),
]
Exemple #20
0
from account.views import SignupView
from django.conf.urls import patterns, include, url
from django.conf.urls.static import static
from django.conf import settings
from django.contrib import admin
from django.views.generic.base import TemplateView
from pybbm_org.forms import PybbmRegistrationForm

admin.autodiscover()

urlpatterns = patterns(
    '',
    url(r'^robots.txt$', TemplateView.as_view(template_name='robots.txt')),
    url(r'^admin/', include(admin.site.urls)),
    url(r'^', include('pybb.urls', namespace='pybb')),
    url(r'^accounts/signup/$', SignupView.as_view(form_class=PybbmRegistrationForm), name='registration_register'),

    url(r"^accounts/", include("account.urls")),
    url(r'^captcha/', include('captcha.urls')),

) + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
Exemple #21
0
# -*- coding: utf-8 -*-
from __future__ import unicode_literals

import django
from account.views import ChangePasswordView, SignupView, LoginView
from django.conf.urls import include, url
from django.contrib import admin
from example_thirdparty.forms import SignupFormWithCaptcha

urlpatterns = [
    url(r'^admin/', include(admin.site.urls) if django.VERSION < (1, 10) else admin.site.urls),

    # aliases to match original django-registration urls
    url(r"^accounts/password/$", ChangePasswordView.as_view(),
        name="auth_password_change"),
    url(r"^accounts/signup/$",
        SignupView.as_view(form_class=SignupFormWithCaptcha),
        name="registration_register"),
    url(r"^accounts/login/$", LoginView.as_view(), name="auth_login"),

    url(r'^accounts/', include('account.urls')),
    url(r'^captcha/', include('captcha.urls')),
    url(r'^', include('pybb.urls', namespace='pybb')),
]
Exemple #22
0
        '',
        url(r'^$', root_redirects_to_home, name='core_root'),
    )


if 'account' in settings.INSTALLED_APPS:
    # We use localized URLs in our app. django-user-accounts doesn't. Too bad.

    from account.views import (SignupView, LoginView, LogoutView, DeleteView,
                               ConfirmEmailView, ChangePasswordView,
                               PasswordResetView, PasswordResetTokenView,
                               SettingsView)

    urlpatterns += i18n_patterns(
        "",
        url(_(r"^signup/$"), SignupView.as_view(),
            name="account_signup"),
        # original is: url(_(r"^login/$"), but we prefer:
        url(_(ur'^signin/$'), never_cache(LoginView.as_view()),
            name="signin"),
        # original is: url(_(r"^logout/$"), but we prefer:
        url(_(ur'^signout/$'), never_cache(LogoutView.as_view()),
            name="signout"),
        url(_(r"^confirm_email/(?P<key>\w+)/$"), ConfirmEmailView.as_view(),
            name="account_confirm_email"),
        url(_(r"^password/$"), ChangePasswordView.as_view(),
            name="account_password"),
        url(_(r"^password/reset/$"), PasswordResetView.as_view(),
            name="account_password_reset"),
        url(_(r"^password/reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$"),
            PasswordResetTokenView.as_view(),
Exemple #23
0
admin.autodiscover()

##---FORMS

@form_with_captcha
class CaptchaSignupForm(SignupForm):
    pass

##---URLS

## core

urlpatterns = patterns('',
    url(r'^$', TemplateView.as_view(template_name='home.html'), name='home'),
    url(r'^admin/', include(admin.site.urls)),
    url(r'^account/signup/$', SignupView.as_view(form_class=CaptchaSignupForm), name="account_signup"),
    url(r'^account/', include("account.urls")),
)

## spike

urlpatterns += patterns('',
    url(r'^spike/', include('spike.urls')),
    url(r'^imprint/$', TemplateView.as_view(template_name='about/imprint.html'), name='imprint'),
    url(r'^team/$', TemplateView.as_view(template_name='about/team.html'), name='team'),
)

## static files

urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
Exemple #24
0
from __future__ import unicode_literals

from django.conf.urls import patterns, url

from account.views import SignupView, LoginView, LogoutView, DeleteView
from account.views import ConfirmEmailView
from account.views import ChangePasswordView, PasswordResetView, PasswordResetTokenView
from account.views import SettingsView

urlpatterns = patterns("",
    url(r"^signup/$", SignupView.as_view(), name="account_signup"),
    url(r"^login/$", LoginView.as_view(), name="account_login"),
    url(r"^logout/$", LogoutView.as_view(), name="account_logout"),
    url(r"^confirm_email/(?P<key>\w+)/$", ConfirmEmailView.as_view(), name="account_confirm_email"),
    url(r"^password/$", ChangePasswordView.as_view(), name="account_password"),
    url(r"^password/reset/$", PasswordResetView.as_view(), name="account_password_reset"),
    url(r"^password/reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$", PasswordResetTokenView.as_view(), name="account_password_reset_token"),
    url(r"^settings/$", SettingsView.as_view(), name="account_settings"),
    url(r"^delete/$", DeleteView.as_view(), name="account_delete"),
)
Exemple #25
0
from django.urls import path, re_path
from account.views import (
    ChangePasswordView,
    ConfirmEmailView,
    DeleteView,
    LoginView,
    LogoutView,
    PasswordResetTokenView,
    PasswordResetView,
    SettingsView,
    SignupView,
)

urlpatterns = [
    path('signup/', SignupView.as_view(), name="account_signup"),
    path('login/', LoginView.as_view(), name="account_login"),
    path('logout/', LogoutView.as_view(), name="account_logout"),
    re_path(r'^confirm_email/(?P<key>\w+)/$',
            ConfirmEmailView.as_view(),
            name="account_confirm_email"),
    path('password/', ChangePasswordView.as_view(), name="account_password"),
    path('password/reset/',
         PasswordResetView.as_view(),
         name="account_password_reset"),
    re_path(r'^password/reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$',
            PasswordResetTokenView.as_view(),
            name="account_password_reset_token"),
    path('settings/', SettingsView.as_view(), name="account_settings"),
    path('delete/', DeleteView.as_view(), name="account_delete"),
]
Exemple #26
0
from account.views import SignupView
from django_markdown import flatpages as markdown_flatpages
import symposion.views

from misc.views import LoginEmailView
from speakers.views import ExportAcceptedSpeakerEmailView

WIKI_SLUG = r"(([\w-]{2,})(/[\w-]{2,})*)"

urlpatterns = [
    url(r"^admin/", include(admin.site.urls)),
    url(r"^$",
        TemplateView.as_view(template_name="homepage.html"),
        name="home"),
    url(r"^account/signup/$", SignupView.as_view(), name="account_signup"),
    url(r"^account/login/$", LoginEmailView.as_view(), name="account_login"),
    url(r"^account/", include("account.urls")),
    url(r"^dashboard/", symposion.views.dashboard, name="dashboard"),
    url(r"^speaker/export/$",
        staff_member_required(ExportAcceptedSpeakerEmailView.as_view()),
        name="speaker_email_export"),
    url(r"^speaker/", include("symposion.speakers.urls")),
    url(r"^proposals/", include("symposion.proposals.urls")),
    url(r"^sponsors/", include("symposion.sponsorship.urls")),
    url(r"^teams/", include("symposion.teams.urls")),
    url(r"^reviews/", include("symposion.reviews.urls")),
    url(r"^schedule/", include("symposion.schedule.urls")),
    url("^markdown/", include("django_markdown.urls")),
    url(r"^markitup/", include("markitup.urls")),
]
Exemple #27
0
v1_api = Api(api_name='v1')
v1_api.register(BookmarkResource())
v1_api.register(ListResource())
v1_api.register(UserResource())
v1_api.register(FeedbackResource())
v1_api.register(FollowResource())
v1_api.register(CommentResource())
v1_api.register(ListInvitationResource())
v1_api.register(UserTourResource())
v1_api.register(FeedCountResource())

urlpatterns = patterns("",
    url(r"^admin/", include(admin.site.urls)),
    #url(r'adminx/', include(xadmin.site.urls)),
    url(r'^harvest/', include("harvest.urls")),
    url(r"^accounts/signup/$", SignupView.as_view(form_class=SignupForm), name="account_signup"),
    url(r"^accounts/settings/$", SettingsView.as_view(form_class=SettingsForm), name="account_settings"),
    url(r"^accounts/login/$", LoginView.as_view(form_class=LoginEmailOrUsernameForm), name="account_login"),

    url(r'', include('social_auth.urls')),
    url(r'misc/', include('misc.urls')),
    url(r"^accounts/", include("account.urls")),
    url(r'^api/', include(v1_api.urls)),
    url(r'^comments/', include('django.contrib.comments.urls')),
    url(r'^profiles/profile/(?P<username>\w+)/', redirect_to, {'url': '/profiles/edit'}),
    url(r'^help/', direct_to_template, {'template': 'help.html'}, name="help"),
    url(r'^about/', direct_to_template, {'template': 'about.html'}, name="about"),
    url(r'^profiles/', include('idios.urls')),
    url(r'^invite/', include('kaleo.urls')),
    url(r'^notifications/', include('notifications.urls', namespace="notifications")),
    url(r'^avatar/', include('avatar.urls')),