mirror of
https://github.com/postgres/pgweb.git
synced 2025-08-13 13:12:42 +00:00

This allows each account to have more than one email address, of which one is primary. Adding more addresses will trigger an email with a verification link (of course). The field previously known as "email" is now changed to be "primary email". Change the profile form to allow freely changing between the added addresses which one is the primary. Remove the functionality to directly change the primary email -- instead one has to add a new address first and then change to that one, which simplifies several things in the handling.
60 lines
2.4 KiB
Python
60 lines
2.4 KiB
Python
from django.conf.urls import url
|
|
from django.conf import settings
|
|
|
|
import pgweb.account.views
|
|
import pgweb.account.oauthclient
|
|
|
|
pgweb.account.oauthclient.configure()
|
|
|
|
urlpatterns = [
|
|
url(r'^$', pgweb.account.views.home),
|
|
|
|
# Community authenticatoin
|
|
url(r'^auth/(\d+)/$', pgweb.account.views.communityauth),
|
|
url(r'^auth/(\d+)/logout/$', pgweb.account.views.communityauth_logout),
|
|
url(r'^auth/(\d+)/consent/$', pgweb.account.views.communityauth_consent),
|
|
url(r'^auth/(\d+)/search/$', pgweb.account.views.communityauth_search),
|
|
url(r'^auth/(\d+)/getkeys/(\d+/)?$', pgweb.account.views.communityauth_getkeys),
|
|
|
|
# Profile
|
|
url(r'^profile/$', pgweb.account.views.profile),
|
|
url(r'^profile/add_email/([0-9a-f]+)/$', pgweb.account.views.confirm_add_email),
|
|
|
|
# List of items to edit
|
|
url(r'^edit/(.*)/$', pgweb.account.views.listobjects),
|
|
|
|
# News & Events
|
|
url(r'^news/(.*)/$', pgweb.news.views.form),
|
|
url(r'^events/(.*)/$', pgweb.events.views.form),
|
|
|
|
# Software catalogue
|
|
url(r'^organisations/(.*)/$', pgweb.core.views.organisationform),
|
|
url(r'^products/(.*)/$', pgweb.downloads.views.productform),
|
|
|
|
# Organisation information
|
|
url(r'^orglist/$', pgweb.account.views.orglist),
|
|
|
|
# Professional services
|
|
url(r'^services/(.*)/$', pgweb.profserv.views.profservform),
|
|
|
|
# Docs comments
|
|
url(r'^comments/(new)/([^/]+)/([^/]+)/$', pgweb.docs.views.commentform),
|
|
url(r'^comments/(new)/([^/]+)/([^/]+)/done/$', pgweb.docs.views.commentform_done),
|
|
|
|
# Log in, logout, change password etc
|
|
url(r'^login/$', pgweb.account.views.login),
|
|
url(r'^logout/$', pgweb.account.views.logout),
|
|
url(r'^changepwd/$', pgweb.account.views.changepwd),
|
|
url(r'^changepwd/done/$', pgweb.account.views.change_done),
|
|
url(r'^reset/$', pgweb.account.views.resetpwd),
|
|
url(r'^reset/done/$', pgweb.account.views.reset_done),
|
|
url(r'^reset/(?P<uidb64>[0-9A-Za-z_\-]+)-(?P<token>[0-9A-Za-z]{1,13}-[0-9A-Za-z]{1,20})/$', pgweb.account.views.reset_confirm),
|
|
url(r'^reset/complete/$', pgweb.account.views.reset_complete),
|
|
url(r'^signup/$', pgweb.account.views.signup),
|
|
url(r'^signup/complete/$', pgweb.account.views.signup_complete),
|
|
url(r'^signup/oauth/$', pgweb.account.views.signup_oauth),
|
|
]
|
|
|
|
for provider in list(settings.OAUTH.keys()):
|
|
urlpatterns.append(url(r'^login/({0})/$'.format(provider), pgweb.account.oauthclient.login_oauth))
|