Exemple #1
0
from django.conf.urls import patterns, url
from explorer.views import QueryView, CreateQueryView, PlayQueryView, DeleteQueryView, ListQueryView

urlpatterns = patterns('',
    url(r'(?P<query_id>\d+)/$', QueryView.as_view(), name='query_detail'),
    url(r'(?P<query_id>\d+)/download$', 'explorer.views.download_query', name='query_download'),
    url(r'(?P<pk>\d+)/delete$', DeleteQueryView.as_view(), name='query_delete'),
    url(r'new/$', CreateQueryView.as_view(), name='query_create'),
    url(r'play/$', PlayQueryView.as_view(), name='explorer_playground'),
    url(r'csv$', 'explorer.views.csv_from_sql', name='generate_csv'),
    url(r'schema/$', 'explorer.views.schema', name='explorer_schema'),
    url(r'$', ListQueryView.as_view(), name='explorer_index'),
)
Exemple #2
0
    ListQueryLogView,
    DownloadFromSqlView,
    DownloadQueryView,
    StreamQueryView,
    EmailCsvQueryView,
    SchemaView,
    format_sql,
)

urlpatterns = [
    url(r'(?P<query_id>\d+)/$', QueryView.as_view(), name='query_detail'),
    url(r'(?P<query_id>\d+)/download$',
        DownloadQueryView.as_view(),
        name='download_query'),
    url(r'(?P<query_id>\d+)/stream$',
        StreamQueryView.as_view(),
        name='stream_query'),
    url(r'download$', DownloadFromSqlView.as_view(), name='download_sql'),
    url(r'(?P<query_id>\d+)/email_csv$',
        EmailCsvQueryView.as_view(),
        name='email_csv_query'),
    url(r'(?P<pk>\d+)/delete$', DeleteQueryView.as_view(),
        name='query_delete'),
    url(r'new/$', CreateQueryView.as_view(), name='query_create'),
    url(r'play/$', PlayQueryView.as_view(), name='explorer_playground'),
    url(r'schema/$', SchemaView.as_view(), name='explorer_schema'),
    url(r'logs/$', ListQueryLogView.as_view(), name='explorer_logs'),
    url(r'format/$', format_sql, name='format_sql'),
    url(r'^$', ListQueryView.as_view(), name='explorer_index'),
]
Exemple #3
0
from django.conf.urls import url
from explorer.views import (
    QueryView,
    CreateQueryView,
    PlayQueryView,
    DeleteQueryView,
    ListQueryView,
    ListQueryLogView,
    download_query,
    download_from_sql,
    stream_query,
    email_csv_query,
    schema,
    format_sql,
)

urlpatterns = [
    url(r'(?P<query_id>\d+)/$', QueryView.as_view(), name='query_detail'),
    url(r'(?P<query_id>\d+)/download$', download_query, name='download_query'),
    url(r'(?P<query_id>\d+)/stream$', stream_query, name='stream_query'),
    url(r'download$', download_from_sql, name='download_sql'),
    url(r'(?P<query_id>\d+)/email_csv$', email_csv_query, name='email_csv_query'),
    url(r'(?P<pk>\d+)/delete$', DeleteQueryView.as_view(), name='query_delete'),
    url(r'new/$', CreateQueryView.as_view(), name='query_create'),
    url(r'play/$', PlayQueryView.as_view(), name='explorer_playground'),
    url(r'schema/$', schema, name='explorer_schema'),
    url(r'logs/$', ListQueryLogView.as_view(), name='explorer_logs'),
    url(r'format/$', format_sql, name='format_sql'),
    url(r'^$', ListQueryView.as_view(), name='explorer_index'),
]
Exemple #4
0
    DownloadQueryView,
    ListQueryLogView,
    ListQueryView,
    PlayQueryView,
    QueryView,
)

urlpatterns = [
    path('', PlayQueryView.as_view(), name='explorer_index'),
    path('auth/', include('authbroker_client.urls', namespace='authbroker')),
    path('download/', DownloadFromSqlView.as_view(), name='download_sql'),
    path('queries/', ListQueryView.as_view(), name='list_queries'),
    path('queries/create/', CreateQueryView.as_view(), name='query_create'),
    path('queries/<int:query_id>/', QueryView.as_view(), name='query_detail'),
    path('queries/<int:query_id>/download/', DownloadQueryView.as_view(), name='download_query'),
    path('queries/<int:pk>/delete/', DeleteQueryView.as_view(), name='query_delete'),
    path('logs/', ListQueryLogView.as_view(), name='explorer_logs'),
]

if settings.DEBUG:
    import debug_toolbar

    urlpatterns = [path('__debug__/', include(debug_toolbar.urls)),] + urlpatterns

# Build schema cache at startup in background
if not settings.MULTIUSER_DEPLOYMENT and not settings.TEST:

    def build_schema():
        for alias in settings.EXPLORER_CONNECTIONS:
            build_schema_cache_async(alias)
Exemple #5
0
from django.urls import re_path
from explorer.views import MainView
from explorer.views import QueryView, NewQueryView
from explorer.views import DeleteQueryView, DownloadQueryView
from explorer.views import SqlQueryView

app_name = 'rdrf'

urlpatterns = [
    re_path(r'^query/(?P<query_id>\w+)/?$',
            QueryView.as_view(),
            name='explorer_query'),
    re_path(r'^query/download/(?P<query_id>\w+)?/(?P<action>\w+)?/?$',
            DownloadQueryView.as_view(),
            name='explorer_query_download'),
    re_path(r'^query/delete/(?P<query_id>\w+)/?$',
            DeleteQueryView.as_view(),
            name='explorer_query_delete'),
    re_path(r'^sql$', SqlQueryView.as_view(), name='explorer_sql_query'),
    re_path(r'^new$', NewQueryView.as_view(), name='explorer_new'),
    re_path(r'$', MainView.as_view(), name='explorer_main'),
]
from django.conf.urls import patterns, url
from explorer.views import QueryView, CreateQueryView, PlayQueryView, DeleteQueryView, ListQueryView, ListQueryLogView

urlpatterns = patterns(
    "",
    url(r"(?P<query_id>\d+)/$", QueryView.as_view(), name="query_detail"),
    url(r"(?P<query_id>\d+)/download$", "explorer.views.download_query", name="query_download"),
    url(r"(?P<query_id>\d+)/csv$", "explorer.views.view_csv_query", name="query_csv"),
    url(r"(?P<query_id>\d+)/email_csv$", "explorer.views.email_csv_query", name="email_csv_query"),
    url(r"(?P<pk>\d+)/delete$", DeleteQueryView.as_view(), name="query_delete"),
    url(r"new/$", CreateQueryView.as_view(), name="query_create"),
    url(r"play/$", PlayQueryView.as_view(), name="explorer_playground"),
    url(r"csv$", "explorer.views.download_csv_from_sql", name="generate_csv"),
    url(r"schema/$", "explorer.views.schema", name="explorer_schema"),
    url(r"logs/$", ListQueryLogView.as_view(), name="explorer_logs"),
    url(r"format/$", "explorer.views.format_sql", name="format_sql"),
    url(r"^$", ListQueryView.as_view(), name="explorer_index"),
)