Exemplo n.º 1
0
from django.contrib import admin

from django.conf.urls import url, include
from accounts import views
from django.contrib.auth.views import login, logout
from accounts.views import HomeView

urlpatterns = [
    url(r'^$', views.home),
    url(r'^about/$', HomeView.as_view(), name='about'),
    #url(r'^profile/edit_bio/$',views.update_profile,name='edit_bio'),
    url(r'^login/$', login, {'template_name': 'accounts/login.html'}),
    url(r'^logout/$', logout, {'template_name': 'accounts/logout.html'}),
    url(r'^register/$', views.register, name='register'),
    url(r'^profile/$', views.view_profile, name='view_profile'),
    url(r'^profile/edit/$', views.update_profile, name='update_profile'),
]
#
Exemplo n.º 2
0
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. Add an import:  from blog import urls as blog_urls
    2. Add a URL to urlpatterns:  url(r'^blog/', include(blog_urls))
"""


from django.conf.urls import include, url
from django.contrib import admin
from django.contrib.staticfiles.urls import staticfiles_urlpatterns

from accounts.views import HomeView, LogoutPageView, RegisterView, RegisterSuccessView

urlpatterns = [
    url(r'^admin/', include(admin.site.urls)),
    url(r'^$', 'django.contrib.auth.views.login'),
    url(r'^logout/$', LogoutPageView.as_view()),
    url(r'^register/$', RegisterView.as_view()),
    url(r'^register/success/$', RegisterSuccessView.as_view()),
    url(r'^home/$', HomeView.as_view()),
    url(r'^ckeditor/', include('ckeditor.urls')),


]

urlpatterns += staticfiles_urlpatterns()
Exemplo n.º 3
0
"""online_pizza URL Configuration

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

urlpatterns = [
    path('', HomeView.as_view(), name='home'),
    path('contact-us', ContactView.as_view(), name='contact-us'),
    path('accounts/', include('accounts.urls')),
    path('admin/', admin.site.urls),
]
Exemplo n.º 4
0
from django.conf.urls import include, url
from django.contrib import admin
from django.conf.urls.static import static
from django.conf import settings


from accounts.views import HomeView, LoginView

urlpatterns = [
    # Examples:
    url(r'^$', HomeView.as_view(template_name='dashboard.html'), name='home'),
    url(r'^about/$', 'promanage.views.about', name='about'),
    url(r'^account/', include('accounts.urls')),
    url(r'^program/', include('programs.urls')),
    url(r'^group/', include('groups.urls')),
    url(r'^permission/', include('permissions.urls')),
    url(r'^schedule/', include('schedules.urls')),
    url(r'^scheduledaily/', include('scheduledaily.urls')),
    url(r'^genschedule/', include('genschedule.urls')),
    url(r'^lineschedule/', include('lineschedule.urls')),
    url(r'^reworkschedule/', include('reworkschedule.urls')),
    url(r'^workreports/', include('workreports.urls')),
    # superadmin 
    url(r'^nimda/', include(admin.site.urls)),

    # auth user
    url(r'^login/$', LoginView.as_view(template_name='AdminLTE/login.html'), name='auth_login'),
    url(r'^logout/$', 'accounts.views.auth_logout', name='auth_logout'),


Exemplo n.º 5
0
from django.conf.urls import patterns, url

from accounts.views import LoginView, HomeView, ChangeView

urlpatterns = patterns(
    'accounts.views',
    url(r'^logout/$', 'logout_view', name='logout'),
)

urlpatterns += patterns(
    '',
    url(r'^login/$', LoginView.as_view(), name='login'),
    url(r'^$', HomeView.as_view(), name='home'),
    url(r'^change/password/$', ChangeView.as_view(), name='change'),
)
Exemplo n.º 6
0
"""billiardmate URL Configuration

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

urlpatterns = [
    path('admin/', admin.site.urls),
    path('accounts/', include('accounts.urls')),
    path('tournament/', include('tournament.urls')),
    path('', HomeView.as_view(), name='index'),
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
Exemplo n.º 7
0
from django.urls import path, include, re_path

from accounts.views import (
    HomeView,
    LogInView,
    LogOutView,
)

app_name = 'accounts'
urlpatterns = [
    re_path(r'^$', HomeView.as_view(), name='home'),
    re_path(r'^login/$', LogInView.as_view(), name='login'),
    re_path(r'^logout/$', LogOutView.as_view(), name='logout'),
]
Exemplo n.º 8
0
from django.conf.urls import url, include
from django.urls import path
from accounts.views import HomeView, GuardsView, RemoveGuardsView

app_name = "accounts"

urlpatterns = [
    path('home/', HomeView.as_view(), name="home"),
    path('guards/', GuardsView.as_view(), name="guards"),
    url(r'^remove_guards/(?P<pk>[0-9A-Fa-f-]+)/$',
        RemoveGuardsView.as_view(),
        name="remove_guards"),
]
Exemplo n.º 9
0
from django.conf import settings
from django.contrib import admin
from django.urls import path
from django.contrib.auth.decorators import login_required
from django.conf.urls.static import static
from accounts.views import login_view, register_view, HomeView, logout_view
# from django.contrib.auth.views import LogoutView

urlpatterns = [
    path('admin/', admin.site.urls),
    path('', login_required(HomeView.as_view()), name='home'),
    path('login/', login_view, name='login'),
    path('logout/', logout_view, name="logout"),
    path('register/', register_view, name='register'),
]

urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
Exemplo n.º 10
0
from accounts.views import HomeView, AccountView, AccountEditView
from django.conf.urls import patterns, url

urlpatterns = patterns('',
    url(r'^login/$', 'django.contrib.auth.views.login',
        {'template_name': 'accounts/login.html'},
        name='login'),
    url(r'^logout/$', 'django.contrib.auth.views.logout',
        {'template_name': 'accounts/logged_out.html'},
        name='logout'),
    url(r'^change_password/$', 'django.contrib.auth.views.password_change',
        {'template_name': 'accounts/password_change_form.html'},
        name='password_change'),
    url(r'^change_password/done/$', 'django.contrib.auth.views.password_change_done',
        {'template_name': 'accounts/password_change_done.html'},
        name='password_change_done'),

    url(r'^home/$', HomeView.as_view(), name='home_page'),
    url(r'^profile/$', AccountView.as_view(), name='account'),
    url(r'^profile/edit/$', AccountEditView.as_view(), name='account_edit'),
)
Exemplo n.º 11
0
from django.conf.urls import patterns, url

from accounts.views import LoginView, HomeView


urlpatterns = patterns(
    'accounts.views',

    url(r'^logout/$', 'logout_view', name='logout'),

)

urlpatterns += patterns(
    '',

    url(r'^login/$', LoginView.as_view(), name='login'),
    url(r'^$', HomeView.as_view(), name='home'),
)
Exemplo n.º 12
0
from django.conf.urls import url
from accounts.views import HomeView

urlpatterns = [
    url(r'^$', HomeView.as_view(), name="home"),
]
Exemplo n.º 13
0
from django.urls import path
from django.contrib.auth import views as auth_views
from accounts.views import (SignUpView, LogInView, ProfileSetupView,
                            ProfileUpdateView, HomeView)

urlpatterns = [
    path('signup/', SignUpView.as_view(), name='signup'),
    path('login/', LogInView.as_view(), name='login'),
    path('login/profiles/home',
         ProfileSetupView.as_view(),
         name='profile-setup'),
    path('login/accounts/update',
         ProfileUpdateView.as_view(),
         name='profile-update'),
    path('login/profiles/submit/redirect',
         HomeView.as_view(),
         name='home-view'),
    path('login/profiles/home-view', HomeView.as_view(),
         name='show-home-view'),
    # path('logout/', auth_views.LogoutView.as_view(), name='logout'),
]
Exemplo n.º 14
0
from django.conf.urls import patterns, include, url

from django.views.generic.base import TemplateView
from accounts.views import signup, signin, signout, HomeView

urlpatterns = patterns('',
    # Examples:
    # url(r'^$', 'ShareUrThoughts.views.home', name='home'),
    # url(r'^blog/', include('blog.urls')),

    url(r'^$', HomeView.as_view(template_name='base.html'), name='home'),

    url(r'^signin/$', signin, name='signin'),
    url(r'^signout/$', signout, name='signout'),

    url(r'^signup/$', signup, name='signup'),

)