示例#1
0
# -*- coding: utf-8 -*-
"""
Urls for backend ember-django application.

@author: Ioannis Stenos, Nick Vrionis
"""

from django.conf import settings
from django.conf.urls import patterns, include, url
from django.contrib import admin
from views import SessionView, StatusView, JobsView, HdfsView, MainPageView, StatisticsView, NewsView, OrkaImagesView, VreServerView, VreImagesView

urlpatterns = patterns('', url(r'^$', MainPageView.as_view()),
                       url(r'^api/statistics', StatisticsView.as_view()),
                       url(r'^api/newsitems', NewsView.as_view()),
                       url(r'^api/orkaimages', OrkaImagesView.as_view()),
                       url(r'^api/vreimages', VreImagesView.as_view()),
                       url(r'^admin', include(admin.site.urls)),
                       url(r'^api/users', SessionView.as_view()),
                       url(r'^api/clusters', StatusView.as_view()),
                       url(r'^api/clusterchoices', StatusView.as_view()),
                       url(r'^api/jobs', JobsView.as_view()),
                       url(r'^api/vreservers', VreServerView.as_view()),
                       url(r'^api/hdfs', HdfsView.as_view()))

# if settings.DEBUG:
#     import debug_toolbar
#     urlpatterns += patterns('',
#         url(r'^__debug__/', include(debug_toolbar.urls)),
#     )
示例#2
0
文件: urls.py 项目: averrin/emergent
from django.conf import settings
from django.conf.urls import patterns, include, url
from views import IndexView, StatusView, ProfileView, MyProfileView, LoginView, LoginErrorView, UserListView

from django.contrib.auth import views as auth_views

# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()

urlpatterns = patterns(
    '',
    url(r'^$', IndexView.as_view(), name='index'),
    url(r'^status$', StatusView.as_view(), name='status'),
    url(r'^(favicon\.ico)$', 'django.views.static.serve',
        {'document_root': settings.STATIC_ROOT}),
    (r'^grappelli/', include('grappelli.urls')),
    url(r'^admin/', include(admin.site.urls)),

    url(r'^zen/', include('zen.urls'), name='zen'),
    url(r'^rpg/', include('rpg.urls'), name='rpg'),

    url(r'^users/(?P<username>.*)/$', ProfileView.as_view(), name='profile'),
    url(r'^users/$', UserListView.as_view(), name='profuserlistile'),
    url(r'^account/', include('social_auth.urls')),
    url(r'^account/login/$', LoginView.as_view(), name='login'),
    url(r'^account/login_error/$', LoginErrorView.as_view(), name='login_error'),
    url(r'^account/logout/$', auth_views.logout, {'next_page': '/'}, name='auth_logout'),
    url(r'^account/profile/$', MyProfileView.as_view(), name='me'),

示例#3
0
#!/usr/bin/env python
# -*- coding: utf-8 -*-

"""
Urls for backend ember-django application.

@author: Ioannis Stenos, Nick Vrionis
"""

from django.conf import settings
from django.conf.urls import patterns, include, url
from django.contrib import admin
from views import SessionView, StatusView, JobsView, HdfsView

urlpatterns = patterns('', url(r'^$', 'backend.views.main_page'),
                       url(r'^admin', include(admin.site.urls)),
                       url(r'^api/users', SessionView.as_view()),
                       url(r'^api/clusters', StatusView.as_view()),
                       url(r'^api/clusterchoices', StatusView.as_view()),
                       url(r'^api/jobs', JobsView.as_view()),
                       url(r'^api/hdfs', HdfsView.as_view())
                       )

# if settings.DEBUG:
#     import debug_toolbar
#     urlpatterns += patterns('',
#         url(r'^__debug__/', include(debug_toolbar.urls)),
#     )
示例#4
0
文件: urls.py 项目: coinvestclub/api
from api.widget import *

from api.sitemaps import sitemaps
from views import LandingView, HumansTXTView, StatusView, autocomplete, get_user_from_email
from configuration.views import UserSignupDoneView
from api.views import TeamView, LegalView, UseTermsView, ContactView, SocietyCreateView, SearchView, TestView
from storage.views import SignupKYCView

import notifications

urlpatterns = patterns('',
    url(r'^test$', TestView.as_view(), name='test'),

    url(r'^$', LandingView.as_view(), name='landing_page'),
    url(r'^humans\.txt$', HumansTXTView.as_view(), name='humanstxt'),
    url(r'^(?P<code>\d0\d)$', StatusView.as_view(), name='humanstxt'),

    url(r'^search$', SearchView.as_view(), name='search'),

    url(r'^team$', TeamView.as_view(), name='team'),
    url(r'^legal$', LegalView.as_view(), name='legal'),
    url(r'^useterms$', UseTermsView.as_view(), name='useterms'),
    url(r'^contact$', ContactView.as_view(), name='contact'),

    url(r'^autocomplete(?P<types>(/\w+)*)$', autocomplete, name='autocomplete'),

    url(r'^user_from_email$', get_user_from_email, name='get_user_from_email'),

    url(r'^activity/', include('activity.urls')),
    url(r'^captcha/', include('captcha.urls')),
    url(r'^configuration/', include('configuration.urls')),
示例#5
0
    path('about/contact/', ContactView.as_view(), name='contact'),
    path('about/help/', HelpView.as_view(), name='help'),
    path('about/privacy-policy/', PrivacyView.as_view(), name='privacy-policy'),
    path('about/terms-and-conditions/', TermsView.as_view(), name='terms-and-conditions'),

    # Accounts App
    path('accounts/', include(accounts_patterns)),

    # API
    path('api/', include(api_patterns)),

    # Testing errors
    path('test/403', Test403View.as_view()),
    path('test/404', Test404View.as_view()),
    path('test/500', Test500View.as_view()),

    # status
    path('status/', StatusView.as_view())
]

handler403 = permission_denied
handler404 = page_not_found
handler500 = Error500View.as_view()

if settings.DEBUG:
    import debug_toolbar

    urlpatterns = [
        path('debug/', include(debug_toolbar.urls)),
    ] + urlpatterns + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
示例#6
0
from django.conf.urls.defaults import patterns, include, url
from views import StatusView

urlpatterns = patterns('',
    (r'^status/$', StatusView.as_view(), {}, "tweetfetcher_status_view"),
    
)