urlpatterns = [ path('accounts/', include('django.contrib.auth.urls')), url(r'^markdownx/', include('markdownx.urls')), path('about', TemplateView.as_view(template_name='about.html'), name='about'), #url(r'^admin/', admin.site.urls), path('signup/', UserCreateView.as_view(), name='signup'), path('users/<int:pk>/', UserDetailView.as_view(), name='user_detail'), #path('users/(?P<userid>\d+)/$', search.views.user_detail, name='user_detail'), path('users/<int:pk>/edit/', UpdateUserView.as_view(), name='user_update'), path('password_reset_form/', auth_views.PasswordChangeView.as_view()), path('users/logout/', auth_views.LogoutView.as_view( template_name='registration/logout.html'), name='logout'), path('', EventMap.as_view(), name='index'), path('', EventMap.as_view(), name='home'), path('event/', EventList.as_view(), name='event_list'), path('event/<int:pk>/', EventDetail.as_view(), name='event_detail'), path('event/<int:pk>/edit/', EventUpdate.as_view(), name='event_edit'), path('event/new/', EventCreate.as_view(), name='event_new'), path('paper/', PaperList.as_view(), name='paper_list'), path('paper/<int:pk>/', PaperDetail.as_view(), name='paper_detail'), path('paper/<int:pk>/edit/', PaperUpdate.as_view(), name='paper_edit'), path('paper/new/', PaperCreate.as_view(), name='paper_new'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=Event, properties=('title', 'city', 'date')), name='data') ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
from django.contrib.auth import urls urlpatterns = patterns('', url(r'^$', TemplateView.as_view (template_name='temp/index.html'), name='index'), url(r'^contacts/$','mlisho.views.contact', name='contacts'), url(r'^register/$', 'mlisho.views.register_user', name='register_user'), #url(r'^events/(?P<event_id>\d+)/export/', 'mlisho.views.export', name="event_ics_export"), url(r'^calendars/$', 'mlisho.views.calendar', name='calendar'), #url(r'^index/', BlogIndex.as_view(), name="indexs"), url(r'^about/', 'mlisho.views.about', name="about"), url(r'^map/$', 'mlisho.views.map', name='map'), url(r'^markets/$', 'mlisho.views.market_portal', name='market'), url(r'^market_report/$', 'mlisho.views.add_point', name='market_report'), url(r'^pasture_data/$', GeoJSONLayerView.as_view(model=Pasture, properties=('dn')), name='pasture_data'), url(r'^rainfall2014_data/$', GeoJSONLayerView.as_view(model=Wet_Season2014, properties=('dn')), name='rainfall2014_data'), url(r'^market_data/$', GeoJSONLayerView.as_view(model=Market, properties=('market_id', 'market_name','livestock','price_livestock','price_kg','premium','compensation','category','country', 'county','town','status','date_applied')), name='market_data'), url(r'^pastoralist_data/$', GeoJSONLayerView.as_view(model=Pastoralist, properties=('last_name','mobile','geom',)), name='pastoralist_data'), url(r'^landmark_data/$', GeoJSONLayerView.as_view(model=Landmark, properties=('name','geom')), name='landmark_data'), url(r'^points/$', 'mlisho.views.points', name='points'), url(r'^accounts/login/$', 'mlisho.views.user_login', name='login'), url(r'^accounts/logout/', 'mlisho.views.user_logout', name='loggedout'), url(r'^accounts/', include('registration.backends.simple.urls')), url(r'^register_success/', ('mlisho.views.register_success')), url(r'^apply/$', 'mlisho.views.pastoralist_portal', name='apply'), url(r'^status/$', 'mlisho.views.status', name='status'), url(r'^add_point/error$', 'mlisho.views.form_error'), url(r'^add_point/success$', 'mlisho.views.form_success'), #url(r'^grappelli/', include('grappelli.urls')),
from django.conf.urls import url from .models import * from .views import * from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView urlpatterns = [ url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data/$', GeoJSONLayerView.as_view(model=SeoulPoint, properties=('number', 'name', 'juso', 'latitude', 'longitude')), name='data'), # url(r'^geodata/$', Geo_datasets, name = 'geo_data'), # url(r'^incidence_data/$', GeoDjangoView.as_view(), name='home'), ]
from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from .models import TravelSpotGeoMaps from . import views app_name = 'geomaps' urlpatterns = [ # url(r'^admin/', admin.site.urls), #url(r'^$', TemplateView.as_view(template_name='geomaps.html'), name='geomaps'), #url(r'^', TemplateView.as_view(template_name='base_geomaps_withoutdjango.html'), name='geomaps'), url(r'^shortlist', views.geomaps_shortlist, name='geomaps_shortlist'), url(r'^directions', views.geomaps_directions, name='geomaps_directions'), url(r'^ordering', views.geomaps_ordering, name='geomaps_ordering'), url(r'^sorting_rubaxa', views.geomaps_sorting_rubaxa, name='geomaps_sorting_rubaxa'), url(r'^reverse_geocoding', views.reverse_geocoding, name='reverse_geocoding'), url(r'^shortlisted_list', views.geomaps_shortlisted_display, name='geomaps_shortlisted_display'), url(r'^', views.geomaps, name='geomaps'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=TravelSpotGeoMaps, properties=('title', 'description', 'picture_url')), name='data') ] #+ static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
from django.urls import include, path from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from paths.models import GeoWalk, SinglePoint, Neighborhood urlpatterns = [ path('', TemplateView.as_view(template_name='maps/map.html'), name='map'), path('mapdata/', GeoJSONLayerView.as_view(model=GeoWalk, properties=('name', 'description', 'picture_url')), name='mapdata'), path('pointsdata/', GeoJSONLayerView.as_view(model=SinglePoint, properties=('name')), name='pointsdata'), path('neighborhoodsdata/', GeoJSONLayerView.as_view(model=Neighborhood, properties=('name')), name='neighborhoodsdata'), ]
from pages import views from harvest.models import Property from djgeojson.views import GeoJSONLayerView from django.conf.urls import url, include from django.contrib.auth import views as auth_views urlpatterns = [ url(r'^$', views.Index.as_view(), name='index'), url(r'^login$', auth_views.login, name='login'), url(r'^calendar$', views.Calendar.as_view(), name='calendar'), url(r'^jsoncal', views.JsonCalendar.as_view(), name='calendarJSON'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=Property, properties=('id', 'get_owner_name', 'short_address')), name='data') ]
from django.conf.urls import patterns, include, url from django.contrib.gis import admin from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from world.models import Country, Hotspot from world.views import CountriesLayer,HotspotDetail urlpatterns = patterns('', # Examples: # url(r'^$', 'osepdjango.views.home', name='home'), # url(r'^blog/', include('blog.urls')), url(r'^admin/', include(admin.site.urls)), url(r'^$',TemplateView.as_view(template_name='index.html'),name='home'), url(r'^hotspots.geojson$',GeoJSONLayerView.as_view(model=Hotspot,geometry_field='wkb_geometry',properties=('acq_date','acq_time','satellite','scan')),name='data'), url(r'^countries.geojson$',CountriesLayer.as_view(model=Country,geometry_field='wkb_geometry'),name='countries'), url(r'hotspot/(?P<pk>\d+)/$',view=HotspotDetail.as_view(),name='hotspot_detail'), )
url(r'^$', TemplateView.as_view(template_name='temp/index.html'), name='index'), url(r'^contacts/$', 'dss.views.contact', name='contacts'), url(r'^register/$', 'dss.views.register_user', name='register_user'), #url(r'^events/(?P<event_id>\d+)/export/', 'dss.views.export', name="event_ics_export"), url(r'^calendars/$', 'dss.views.calendar', name='calendar'), url(r'^feed/$', LatestPosts(), name="feed"), url(r'^index/', BlogIndex.as_view(), name="indexs"), url(r'^about/', 'dss.views.about', name="about"), url(r'^entry/(?P<slug>\S+)$', BlogDetail.as_view(), name="entry_detail"), url(r'^map/$', 'dss.views.map', name='map'), url(r'^incident/$', 'dss.views.incident_portal', name='incident'), url(r'^admin_data/$', GeoJSONLayerView.as_view( model=administration, properties=('id', 'kenya_id', 'kenya_field', 'location_b', 'females', 'males', 'total')), name='data'), url(r'^events_data/$', GeoJSONLayerView.as_view( model=Events, properties=('name', 'organizers', 'sponsors', 'date', 'location', 'venue', 'event_type')), name='events'), url(r'^incidence_data/$', GeoJSONLayerView.as_view( model=incidence, properties=('date_applied', 'incidence_id', 'status', 'incidence_title', 'category', 'county', 'closest_town')), name='incidencedata'),
from django.conf.urls import url from . import views from djgeojson.views import GeoJSONLayerView from GDELT.models import GkgCounts urlpatterns = [ url(r'^data.geojson$', GeoJSONLayerView.as_view(model=GkgCounts), name='data'), ]
from django.conf.urls import patterns, include, url from djgeojson.views import GeoJSONLayerView from models import * urlpatterns = patterns('globenocturneapp.views', # Home page URL url(r'^home/$','home'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=WorldBorder), name='worldborderdata'), # Query on map click url(r'getcountry/$','get_country',name='url_get_country'), # Import Data from CSV url(r'dataimport/csv/world_country$','importcsv_world_country'), url(r'dataimport/csv/world_population$','importcsv_world_population'), url(r'dataimport/csv/world_gdp$','importcsv_world_gdp'), url(r'dataimport/csv/world_originsol$','importcsv_world_original_sol'), url(r'analysis/world_sol$','analysis_world_sol'), url(r'dataimport/csv/world_country_sol$','importcsv_world_country_sol'), url(r'dataimport/csv/world_country_sol_cali$','importcsv_world_country_sol_cali'), )
# WAStD Encounters path('encounters/', wastd_views.EncounterTableView.as_view(), name="encounter_list"), path('animal-encounters/', wastd_views.AnimalEncounterTableView.as_view(), name="animalencounter_list"), # API re_path(r'^api/1/swagger/$', wastd_views.schema_view, name="api-docs"), re_path(r'^api/1/docs/', include_docs_urls(title='API')), re_path(r'^api/1/', include((wastd_router.urls, 'api'), namespace="api")), re_path(r'^api-auth/', include(('rest_framework.urls', 'api-auth'), namespace='rest_framework')), re_path(r'^api-token-auth/', drf_authviews.obtain_auth_token, name="api-auth"), # Djgeojson re_path(r'^observations.geojson$', GeoJSONLayerView.as_view( model=wastd_models.Encounter, properties=('as_html', ), geometry_field="where"), name='observation-geojson'), re_path(r'^areas.geojson$', GeoJSONLayerView.as_view( model=wastd_models.Area, properties=('leaflet_title', 'as_html')), name='areas-geojson'), # Encounter as tiled GeoJSON re_path(r'^data/(?P<z>\d+)/(?P<x>\d+)/(?P<y>\d+).geojson$', TiledGeoJSONLayerView.as_view( model=wastd_models.AnimalEncounter, properties=('as_html', 'leaflet_title', 'leaflet_icon', 'leaflet_colour'), geometry_field="where"),
from . import views from django.conf.urls import url, include, patterns from djgeojson.views import GeoJSONLayerView, TiledGeoJSONLayerView from envdata.models import Sample urlpatterns = patterns('', url(r'^data.geojson$', GeoJSONLayerView.as_view(model=Sample, properties=['name','species']), name='data'), url(r'^$', views.index, name='index'), )
from django.conf.urls import patterns, include, url from django.conf import settings from djgeojson.views import GeoJSONLayerView from sisyphus.models import Trail from sisyphus.feeds import PhotosFeed from django.contrib.gis import admin admin.autodiscover() urlpatterns = patterns('', url(r'^admin/', include(admin.site.urls)), url(r'^api/trails.json', GeoJSONLayerView.as_view(model=Trail, properties=('name'), geometry_field='line'), name='data'), url(r'^images/$', 'sisyphus.views.images', name='images'), url(r'^images/feed/$', PhotosFeed()), ) # static files (images, css, javascript, etc.) # (serving from django) urlpatterns += patterns('', (r'^media/(?P<path>.*)$', 'django.views.static.serve', { 'document_root': settings.MEDIA_ROOT}))
from django.conf import settings from django.conf.urls import url from django.conf.urls.static import static from django.contrib import admin from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from .models import ObjectSpot, ObjectPoint #from . import views urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data.geojson$', GeoJSONLayerView.as_view( model=ObjectSpot, properties=('title', 'description', 'type', 'picture_url')), name='data'), url(r'^spots.geojson$', GeoJSONLayerView.as_view( model=ObjectSpot, properties=('title', 'description', 'type', 'picture_url')), name='spots'), url(r'^points.geojson$', GeoJSONLayerView.as_view( model=ObjectPoint, properties=('title', 'description', 'type', 'picture_url')), name='points'), #url(r'^location/(?P<pk>[0-9]+)/$', views.location, name='location'), ] + static(settings.MEDIA_URL, document_root=settings.IMAGE_DIR) #] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
from django.views.generic import TemplateView from django.conf.urls import patterns, url from djgeojson.views import GeoJSONLayerView from .models import WeatherStation urlpatterns = patterns('', url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=WeatherStation), name='data') )
import osmapp.views as osmview from multigtfs.models import Feed from multigtfs.models import Stop from osmapp.models import Node from . import views from .views import FeedListView urlpatterns = [ url(r'^$', views.home, name="home"), url('^map/mapview/(?P<pk>\d+)/$', views.showmap, name="showmap"), url('^map/compmapview/(?P<pk>\d+)/$', compview.showmap_with_comp, name="showcompmap"), url(r'^osmnodedata/', GeoJSONLayerView.as_view(model=Node, properties=('id', 'version', 'feed', 'tags', 'purpose')), name="osmnodedata"), url(r'^stopdata/', GeoJSONLayerView.as_view(model=Stop, properties=('stop_id', 'feed', 'name', 'normalized_name', 'zone', 'description', 'code')), name="stopdata"), # url(r'^waydata/', GeoJSONLayerView.as_view(model=Way, # properties=('id','version','visible','incomplete')), name="waydata"), url(r'^route_masters', osmview.get_route_master_relations, name="route_master"), url(r'^feed/', FeedListView.as_view(model=Feed), name='feed_list'), url(r'^feed_form/', views.feed_form, name='feed_form'),
from django.conf.urls import patterns, url from djgeojson.views import GeoJSONLayerView from . import views from .views import DocListView, DocDetailView, OpMapListView, Operation, Sequence, UniteDetailView, MentionDetailView app_name = 'inventaire' urlpatterns = patterns('', url(r'^$', views.index, name='index'), url(r'^document/(?P<pk>[^/]+)', views.DocDetailView.as_view(), name='docDetail'), url(r'^document/$', views.DocListView.as_view(), name='docIndex'), url(r'^operation/data.geojson', GeoJSONLayerView.as_view(model=Operation, properties=('popupContent',)), name='opData'), url(r'^operation/$', views.OpMapListView.as_view(), name='opMapIndex'), url(r'^operation/(?P<slug>[^/]+)', views.OpMapDetailView.as_view(), name='opMapDetail'), url(r'^sequence/$', views.SequenceListView.as_view(), name='sequenceIndex'), url(r'^sequence/(?P<pk>[^/]+)', views.SequenceDetailView.as_view(), name='sequenceDetail'), url(r'^mention/(?P<pk>[^/]+)', views.MentionDetailView.as_view(), name='mentionDetail'), url(r'^unite/(?P<pk>[^/]+)', views.UniteDetailView.as_view(), name='uniteDetail'), # url(r'^unite/$', views.unite, name='unite_table'), )
from django.conf.urls import url from django.conf import settings from django.conf.urls.static import static from cdf import views as cdf_views from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from cdf import models as c_models urlpatterns = [ path('', cdf_views.home, name='home'), path('about/', cdf_views.AboutPage, name='about'), path('contact/', cdf_views.ContactPage, name='contact'), path('projects/', cdf_views.projectsview, name='projects'), url(r'^projectsdata.geojson$', GeoJSONLayerView.as_view( model=c_models.CdfProjects, properties=('project', 'location', 'descrition', 'sectors', 'amount', 'status', 'remarks', 'county_nam')), name='projectsdata'), path(r'^report/', cdf_views.ReportView, name='report'), path(r'details/<int:pk>/', cdf_views.projectdetail, name="details"), path('suggest/', cdf_views.suggestionview, name='suggest'), url(r'^incidents.geojson$', GeoJSONLayerView.as_view(model=c_models.Report, properties=('title', 'description', 'mdate', 'mtime')), name='incidents'), path(r'^incidents/', cdf_views.ReportDisplay, name='incidents'), path(r'incidentdata/', cdf_views.Incidence_json, name='incidentdata'), # path(r'projectsdata/',cdf_views.Projects_json,name='projectsdata'), url(r'^inform/', cdf_views.ContactU, name='inform'), path(r'boundary/', cdf_views.ConstBoundary, name='boundary'),
# -*- coding: utf-8 -*- """ Created on Thu Mar 06 16:56:28 2014 @author: chiayuanchuang @app: mapApp @class: urls """ from django.conf.urls import patterns, url from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from .models import LocationPoint from .models import LocationPolygon from .views import MapLayer urlpatterns = patterns('', # Examples: # url(r'^$', 'test_django_geo.views.home', name='home'), # url(r'^blog/', include('blog.urls')), #url(r'^admin/', include(admin.site.urls)), url(r'^$', TemplateView.as_view(template_name = 'mappage.html'), name='mapHome'), url(r'^testSVG$', TemplateView.as_view(template_name = 'testSVG.html'), name='testSVG'), url(r'^treeView$', TemplateView.as_view(template_name = 'treeview.html'), name='treeView'), url(r'^view3D/$', 'mapApp.views.view3D', name="view3D"), url(r'^data.geojsonPoint$', MapLayer.as_view(model=LocationPoint), name='dataPoint'), url(r'^data.geojsonPolygon$', GeoJSONLayerView.as_view(model=LocationPolygon), name='dataPolygon'), )
"""mushrooms 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 import settings from django.conf.urls import url from django.conf.urls.static import static from django.contrib import admin from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from .models import MushroomSpot urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=MushroomSpot, properties=('title', 'description', 'picture_url')), name='data') ] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
from django.conf.urls import patterns, url from djgeojson.views import GeoJSONLayerView from .views import MediaItemList, LocationList, MediaItemDetail, VideoItemDetail, MapView from geonode.mediastory.models import Location urlpatterns = patterns('', url(r'^$', MapView.as_view(), name='location_list'), url(r'^locations/$', MapView.as_view(), name='location_list_alt'), url(r'^location_media/(\d+)/$', MediaItemList.as_view(), name='mediaitem_list'), url(r'^media/(?P<pk>\d+)/$', MediaItemDetail.as_view(), name='mediaitem_detail'), url(r'^video/(?P<pk>\d+)/$', VideoItemDetail.as_view(), name='videoitem_embed'), url(r'^data.locations$', GeoJSONLayerView.as_view(model=Location, properties=('id', 'name', 'description', 'population', 'media_url')), name='location_geodata'), )
# url(r'^$', views.ProjectIndexView.as_view(), name='index'), # # # Project detail view # # ex. /projects/mlp/ # url(r'^(?P<pcoreapp>\w+)/$', views.ProjectDetailView.as_view(), name='detail'), # # # Individual project public data table view # # ex. /projects/data_table/mlp/ # url(r'^data_table/(?P<pcoreapp>.+)/$', views.projectDataTable, name='data_table'), # # TODO change url formulation to projects/projects/data_table, e.x. projects/mlp/data_table # # url to get a geojson representation of all PaleoCore projects # ex. /projects/projects.geojson url(r'^projects.geojson$', GeoJSONLayerView.as_view(model=ProjectPage, properties=['title', 'slug', 'url_path'], geometry_field=('location')), name='projects_geojson'), # # # ex. /projects/data_json/mlp/ # url(r'^data_json/(?P<pcoreapp>.+)/$', views.ajaxProjectData, name='data_json'), # # TODO get working tests for this view # # # url(r'^data/(?P<pcoreapp>[^/]+)/$', views.ProjectDataView.as_view(), name='data'), # url(r'^(?P<pcoreapp>.+)/(?P<occurrence_id>\d+)/$', views.OccurrenceDetailView.as_view(), # name='occurrence_detail'), # # TODO get working test for this view # # # mlp project url includes # # ex. /projects/mlp/upload/ # url(r'^mlp/', include('mlp.urls', namespace='mlp')),
from django.conf.urls import patterns, url from user_profile import views from djgeojson.views import GeoJSONLayerView from user_profile.models import User_Profile urlpatterns = patterns('', url(r'^data.geojson$', GeoJSONLayerView.as_view(model=User_Profile, geometry_field='geom', simplify=True), name='data'), url(r'^map/$', views.MapView.as_view(), name='map'), url(r'^$', views.CreateUserView.as_view(), name="profile"), )
url(r'^settings/upload_picture/$', 'permit.views.upload_picture', name='upload_picture'), url(r'^settings/save_uploaded_picture/$', 'permit.views.save_uploaded_picture', name='save_uploaded_picture'), url(r'^settings/password/$', 'permit.views.password', name='password'), url(r'^network/$', 'permit.views.network', name='network'), url(r'^$', TemplateView.as_view(template_name='index.html'), name='index'), url(r'^index/$', TemplateView.as_view(template_name='index.html'), name='index'), url(r'^apply/$', 'permit.views.application_portal', name='apply'), url(r'^our_story/$', TemplateView.as_view(template_name='our_story.html'), name='our_story'), url(r'^product/$', TemplateView.as_view(template_name='product.html'), name='product'), url(r'^services/$', TemplateView.as_view(template_name='services.html'), name='services'), url(r'^map/$','permit.views.mapping', name='mapping'), url(r'^map/admin$','permit.views.map_admin', name='admin'), url(r'^map/get_business/$', 'permit.views.get_business', name='get_business'), url(r'^map/business/filter/$','permit.views.business_filter', name='business_filter'), url(r'^business_data/$', GeoJSONLayerView.as_view(model=Business_profile, properties=('business_name', 'business_type','business_class','geom','business_compliance' )), name='data'), url(r'^county_data/$', GeoJSONLayerView.as_view(model=County, properties=('name2','count')), name='county_data'), url(r'^location_data/$', GeoJSONLayerView.as_view(model=Locations, properties=('location_b','subloc_b','division_b' )), name='location_data'), url(r'^parcel_data/$', GeoJSONLayerView.as_view(model=Parcels, properties=('id','parcel_no','blockid','sectcode')), name='parcel_data'), url(r'^impacts/$', TemplateView.as_view(template_name='impacts.html'), name='impacts'), url(r'^contact_us/$', TemplateView.as_view(template_name='contact_us.html'), name='contact_us'), url(r'^info/$', TemplateView.as_view(template_name='info.html'), name='info'), url(r'^analytics/$', TemplateView.as_view(template_name='analytics.html'), name='analytics'), url(r'^dashboard/$', TemplateView.as_view(template_name='dashboard.html'), name='dashboard'), url(r'^customer_portal/$', 'permit.views.customer_portal', name='customer_portal'), url(r'^business_portal/$', 'permit.views.add_business_profile', name='business_portal'), url(r'^permit', 'permit.views.create_permit', name='permit'), url(r'^payment_customer', 'permit.views.payment_customer', name='payment_customer'), url(r'^generate_permit', 'permit.views.generate_permit', name='generate_permit'), )
#url(r'^map/(?P<pk>\d+)/geojsonpo$', mapviews.map_jsonp, name='map_geojsonp'), url(r'^parcel/(?P<pk>\d+)$', DetailProtected.as_view(model=Parcel), name='parcel_detail'), url(r'^parcel/new$', parcviews.ParcelNew.as_view(), name='parcel_new'), url(r'^parcel/$', parcviews.ParcelList.as_view(model=Parcel, paginate_by=10), name='parcel_list'), url(r'^parcel/json/$', parcviews.ParcelJSONList.as_view(), name='parcel_json'), url(r'^parcel/geojson$', GeoJSONLayerView.as_view(model=Parcel, properties=['title'], geometry_field='center'), name='parcel_geojson'), url(r'^block/$', parcviews.BlockList.as_view(model=Block), name='block_list'), url(r'^block/(?P<pk>\d+)$', parcviews.BlockDetail.as_view(), name='block_detail'), url(r'^block/(?P<pk>\d+)/import$', DetailProtected.as_view(model=Block, template_name="parc/block_import.html"), name='block_import'), url(r'^block/(?P<pk>\d+)/edit$', parcviews.BlockEdit.as_view(), name='block_edit'), url(r'^block/new$', ListProtected.as_view(model=Block), name='block_new'), url(r'^block/geojson$', GeoJSONLayerView.as_view(model=Block, geometry_field='center'), name='block_geojson'), url(r'^project/$', views.ProjetListView.as_view(), name='projet_list'), url(r'^project/(?P<pk>\d+)$', views.ProjetDetailView.as_view(), name='projet_detail'), url(r'^project/new$', ListProtected.as_view(model=Projet), name='projet_new'), url(r'^accounts/profile/$', 'sigafo.users.views.profile', name='profile'),
from django.urls import path from django.conf.urls import url from django.conf import settings from djgeojson.views import GeoJSONLayerView from django.conf.urls.static import static from . import views from .models import Sonde urlpatterns = [ path('', views.index, name='index'), url(r'^api/renderData', views.renderData, name='renderData'), url(r'^api/exportCSV', views.exportData, name='exportCSV'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=Sonde), name='data'), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) + static( settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
from django.conf.urls import include, url from django.contrib import admin from django.views.generic.base import TemplateView from djgeojson.views import GeoJSONLayerView from core.models import IndigenousVillage, IndigenousLand from core.views import IndigenousLandsLayerView admin.autodiscover() urlpatterns = [ url(r'^api/indigenous_villages$', GeoJSONLayerView.as_view( model=IndigenousVillage, geometry_field='position', properties=['name', 'other_names', 'ethnic_groups2', 'population', 'guarani_presence', ]), name='villages'), url(r'^api/indigenous_lands$', IndigenousLandsLayerView.as_view( model=IndigenousLand, geometry_field='polygon', properties=['name', 'other_names', 'guarani_exclusive_possession_area_portion', 'others_exclusive_possession_area_portion', 'claim', 'demand', 'source', 'land_tenure', 'land_tenure_status', 'associated_land', ]), name='lands'), url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^admin/', include(admin.site.urls)), url(r'^accounts/', include('allauth.urls')),
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 import settings from django.conf.urls import url from django.conf.urls.static import static from django.contrib import admin from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from panampath.models import PathSegment # from .models import MushroomSpot urlpatterns = [ url(r'^data.geojson$', GeoJSONLayerView.as_view( model=PathSegment, properties=('title', 'description', 'picture_url')), name='data') ] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
__author__ = 'jcranwellward' from django.conf.urls import patterns, url from djgeojson.views import GeoJSONLayerView from locations import views from .models import Governorate, Region, Locality urlpatterns = patterns( '', url(r'^governorates.geojson$', GeoJSONLayerView.as_view( model=Governorate, properties=['name', 'color'] ), name='governorates', ), url(r'^districts.geojson$', GeoJSONLayerView.as_view( model=Region, properties=['name', 'color'] ), name='districts'), url(r'^sub-districts.geojson$', GeoJSONLayerView.as_view( model=Locality, properties=['name', 'color'] ), name='sub-districts'),
from django.conf.urls import patterns, include, url from django.views.generic.base import TemplateView from django.views.generic import DetailView from djgeojson.views import GeoJSONLayerView from .models import Location,EffortInstance from entries import views urlpatterns = patterns('', # ex: /entries/ It returns the Location table as a GeoJSON layer view url(r'^$', GeoJSONLayerView.as_view(model=Location), name='location-json'), url(r'^test_form/',TemplateView.as_view(template_name='entries/test_form.html'),name='test-form'), # ex: /entries/11795/results/ This returns the services that are provided by the specified Effort Instance #arg in views needs to be self and pk url(r'^(?P<pk>\d+)/results/$', views.service_results, name='service-results'), #returns other health facilities that offer the same type of services #example of a get request: http://127.0.0.1:8000/entries/shared_servicetype/?id=11779 url(r'^shared_servicetype/$', 'entries.views.shared_servicetype', name='shared-servicetype'), # A post_request is called internally by the test_form to create a new organization url(r'^post_request/$', views.post_request, name='post-request'), ) ''' There was an issue with the reverse call working for post-request I tried with the url and with the name; it ended up working with the namespace django shell: In [30]: reverse('entries:post-request') Out[30]: '/entries/post_request/' >>> from django.core.urlresolvers import reverse
from django.conf.urls import url from django.contrib import admin from clima import views from djgeojson.views import GeoJSONLayerView from .models import Station, FocoItem urlpatterns = [ url(r'^normais/grafnormais/(?P<station>\d+)/(?P<texto>[\w ]+)/', views.grafnormais ), url(r'^automaticas/grafautomatica/(?P<station>\d+)/(?P<mes>\d+)/(?P<ano>\d+)/(?P<texto>[\w ]+)/$', views.grafAutomatica ), url(r'^getautomaticajson/(?P<station>\d+)/$', views.getautomaticajson), url(r'^automaticas/grafautomaticatotal/(?P<station>\d+)/(?P<texto>[\w ]+)/$', views.grafAutomaticaTotal), url(r'^automaticas/$', views.automaticas ), url(r'^data.geojson/$', GeoJSONLayerView.as_view(model= Station, properties=('id', 'Altitude', 'Codigo', 'Nome','Estado',"tipo",'tipo',)), name='data'), url(r'^fire.geojson/$' , GeoJSONLayerView.as_view ( model=FocoItem ) , name='data' ) , url(r'^fire.geojson/$', GeoJSONLayerView.as_view(model= FocoItem), name='data'), url(r'^mapaestacoes/$', views.mapaestacoes), url(r'^mapafocoincendio/$' , views.mapafocoincendio ) , url(r'^fire.geojson$' , GeoJSONLayerView.as_view ( model=FocoItem ) , name='data' ) , url(r'^normais/$', views.normais), url(r'^focoCalor/(?P<id>\d+)/$', views.focoCalor), url(r'^$', views.clima), ]
from django.views.generic import TemplateView from django.conf.urls import url from djgeojson.views import GeoJSONLayerView from .models import shop from . import views from django.urls import path urlpatterns = ( url(r'^$', TemplateView.as_view(template_name='map.html'), name='home'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=shop), name='data1'), url(r'^$', views.mapleaf) )
from django.conf.urls import include, url # from django.contrib import admin from djgeojson.views import TiledGeoJSONLayerView, GeoJSONLayerView from erm.settings import RootModel from erm.views import base, geo urlpatterns = [ url(r'^karte/', base.show_map), url(r'^tilegeojson/(?P<z>\d+)/(?P<x>\d+)/(?P<y>\d+).geojson$', TiledGeoJSONLayerView.as_view(model=RootModel), name='tilegeojson'), url(r'^map/(?P<min_lon>[0-9.]+)/(?P<min_lat>[0-9.]+)/(?P<max_lon>[0-9.]+)/(?P<max_lat>[0-9.]+)/(?P<zoom>[0-9]+)$', geo.map_cutout), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=RootModel), name='data'), url(r'^(.+)', include('erm.urls')), url(r'^', base.index), ]
from django.views.decorators.cache import cache_page from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from django.conf.urls import include, url from django.contrib import admin from permit_map import models from permit_map import views urlpatterns = [ # This URL maps to / and is the main UI render. Note that we just spit out the contents of the permit_map/index.html template. url(r'^$', TemplateView.as_view(template_name="permit_map/index.html"), name='map'), # Lots of things going on here: # - We're using a open source view to render our permits into geoJSON because our view is quite simple. If we had # more complex view data, we could customize it, but this is more than enough for now. # - We're caching the results of this view for one month. This will also cause the page to be rendered using HTTP # headers that cause it to be cached in the user's browser. See the cache_page docs for more. url(r'^permits/geojson', cache_page(2592000)(GeoJSONLayerView.as_view(model=models.Permit, geometry_field='region', properties=['category', 'id'])), name='geojson'), # Full text search entry point, delegates to views.search (views.py) # Permit lookup point, delegates to views.permitsat (views.py) url(r'^search', views.search, name='search'), url(r'^permitsat', views.permitsat, name='permitsat') ]
from django.conf.urls import patterns, url, include from rest_framework.routers import DefaultRouter from djgeojson.views import GeoJSONLayerView from chomper import views from chomper.models import IntermediatePoint, RouteLine, RestaurantPoint, UserPoint router = DefaultRouter() router.register(r'snippets', views.SnippetView) urlpatterns = patterns('', url(r'^', include(router.urls)), url(r'^register/$', views.register, name='register'), url(r'^login/$', views.user_login, name='login'), url(r'^logout/$', views.user_logout, name='logout'), url(r'^api/$', views.api_examples, name='api'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=RouteLine), name='data'), url(r'^datapoints.geojson$', GeoJSONLayerView.as_view(model=RestaurantPoint, properties=('name','rid','rating','Color','CentColor','RouteColor','popupContent')), name='datapoints'), url(r'^userpoints.geojson$', GeoJSONLayerView.as_view(model=UserPoint, properties=('name')), name='userpoints'), url(r'^popup/$', views.popup), url(r'^googlemaps/$', views.googlemaps, name='googlemaps'), )
from django.conf.urls import patterns, include, url from django.contrib.gis import admin from djgeojson.views import GeoJSONLayerView from gebis.models import Gebaeude, Raeume, Mitarbeiter admin.autodiscover() urlpatterns = patterns( '', url(r'^admin/', include(admin.site.urls)), url(r'^$', 'gebis.views.index'), url(r'^data_gebaeude.geojson$', GeoJSONLayerView.as_view(model=Gebaeude), name='data_gebaeude'), url(r'^data_raeume.geojson$', GeoJSONLayerView.as_view(model=Raeume, properties=('raum_nr', 'nutzung', 'abteilung', 'flaeche', 'etage', 'mitarbeiter_by_room')), name='data_raeume'), )
from django.views.generic import TemplateView from django.conf.urls import url, include from django.contrib import admin from djgeojson.views import GeoJSONLayerView from django.utils.translation import ugettext_lazy as _ from bctv2_map_app.models import BctParcel, BrewsterBorder from baton.autodiscover import admin # from bctv2_map_app.views import MyModal urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data.geojson.parcel$', GeoJSONLayerView.as_view( model=BctParcel, properties=('bct_id', 'parcel_num', 'owner_type', 'street_number', 'street_name', 'acquired', 'grantor', 'upland', 'wetland', 'habitat', 'narrative')), name='parceldata'), url(r'^data.geojson.brewster$', GeoJSONLayerView.as_view(model=BrewsterBorder), name='brewsterdata'), url(r'^tinymce/', include('tinymce.urls')), # url(r'^mymodal/', MyModal.as_view(), name='mymodal'), ] admin.site.site_header = _("Brewster Conservation Trust") admin.site.site_title = _("My Site Admin")
# -*- coding: utf-8 -*- from django.conf.urls import url from django.urls import include, path from . import views from django.views.generic.base import RedirectView from world import apis from world.models import Border from djgeojson.views import GeoJSONLayerView # アプリケーションの名前空間 # https://docs.djangoproject.com/ja/2.0/intro/tutorial03/ app_name = 'data' urlpatterns = [ path('', views.index, name='index'), path('geojson/', apis.GeojsonAPIView.as_view(), name='geojson_view'), path('borders.geojson', GeoJSONLayerView.as_view(model=Border), name='borders'), #url(r'^borders/(?P<z>\d+)/(?P<x>\d+)/(?P<y>\d+).geojson$',apis.BorderTiledLayer.as_view(model=Border), name='tiledborders'), path('borders/<int:z>/<int:x>/<int:y>.geojson', apis.BorderTiledLayer.as_view(model=Border), name='tiledborders'), ]
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 from django.conf import settings from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from greenox.models import GreenSiteWard app_name = 'greenox' urlpatterns = [ path('admin/', admin.site.urls), path('greenox', TemplateView.as_view(template_name='greenox/index.html'), name='home'), path('data.geojson', GeoJSONLayerView.as_view(model=GreenSiteWard, properties=('id', 'function', 'name', 'wardname')), name='data') ]
from django.conf.urls import patterns, include, url from django.contrib.gis import admin from djgeojson.views import GeoJSONLayerView from gebis.models import Gebaeude, Raeume, Mitarbeiter admin.autodiscover() urlpatterns = patterns('', url(r'^admin/', include(admin.site.urls)), url(r'^$', 'gebis.views.index'), url(r'^data_gebaeude.geojson$', GeoJSONLayerView.as_view(model=Gebaeude), name='data_gebaeude'), url(r'^data_raeume.geojson$', GeoJSONLayerView.as_view(model=Raeume, properties=('raum_nr','nutzung','abteilung','flaeche','etage', 'mitarbeiter_by_room')), name='data_raeume'), )
# ex. /projects/ url(r'^$', views.ProjectIndexView.as_view(), name='index'), # Project detail view # ex. /projects/mlp/ url(r'^(?P<pcoreapp>\w+)/$', views.ProjectDetailView.as_view(), name='detail'), # Individual project public data table view # ex. /projects/data_table/mlp/ url(r'^data_table/(?P<pcoreapp>.+)/$', views.projectDataTable, name='data_table'), # TODO change url formulation to projects/projects/data_table, e.x. projects/mlp/data_table # url to get a geojson representation of all PaleoCore projects # ex. /projects/projects.geojson url(r'^projects.geojson$', GeoJSONLayerView.as_view(model=Project, properties=("full_name", "paleocore_appname")), name='projects_geojson'), # ex. /projects/data_json/mlp/ url(r'^data_json/(?P<pcoreapp>.+)/$', views.ajaxProjectData, name='data_json'), # TODO get working tests for this view # url(r'^data/(?P<pcoreapp>[^/]+)/$', views.ProjectDataView.as_view(), name='data'), url(r'^(?P<pcoreapp>.+)/(?P<occurrenceid>\d+)/$', views.OccurrenceDetailView.as_view(), name='occurrence_detail'), # TODO get working test for this view # mlp project url includes # ex. /projects/mlp/upload/ url(r'^mlp/', include('mlp.urls', namespace='mlp')),
from django.conf.urls import include, url from djgeojson.views import GeoJSONLayerView from . import models from . import views urlpatterns = [ url('accounts/', include('django.contrib.auth.urls')), url('home/', views.home, name="home"), url(r'^data/region.geojson$', GeoJSONLayerView.as_view(model=models.Region), name='data_region'), url(r'^data/unit.geojson$', GeoJSONLayerView.as_view(model=models.Unit, properties=('name', )), name='data_unit'), url(r'^data/criteria.geojson$', GeoJSONLayerView.as_view(model=models.Criteria, properties=('create_date', )), name='data_criteria'), ]
2. Import the include() function: from django.conf.urls import url, include 3. Add a URL to urlpatterns: url(r'^blog/', include(blog_urls)) """ from django.conf.urls import url, include from django.contrib import admin from login.views import * from djgeojson.views import GeoJSONLayerView from .models import MushroomSpot from . import views urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^$', 'django.contrib.auth.views.login'), url(r'^home/$', home), url(r'^register/$', register), url(r'^register/success/$', register_success), url(r'^accounts/login/$', 'django.contrib.auth.views.login'), url(r'^logout/$', logout_page), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=MushroomSpot, properties=('title', 'description', 'picture_url')), name='data'), url(r'^home/gettldata$', views.gettrafficdata, name='gettraffic'), url(r'^home/getinterdata$', views.getintersectiondata, name='getintersection'), url(r'^home/puttldata$', views.puttrafficdata, name='puttraffic'), url(r'^home/puttldatadetails$', views.putdatadetails, name='putdetails'), ]
from django.conf.urls import patterns, include, url from django.contrib import admin from django.conf import settings from djgeojson.views import GeoJSONLayerView from reports.models import Entry, Report from home.views import HomePageView, SignUpView, LoginView, LogOutView, PortalView from django.contrib.auth.decorators import login_required, permission_required urlpatterns = patterns( "", # Examples: # url(r'^$', 'mrtagis.views.home', name='home'), # url(r'^blog/', include('blog.urls')), url(r"^$", HomePageView.as_view(), name="home"), url(r"^p/$", login_required(PortalView.as_view()), name="portal"), # url(r'^p/$', PortalView.as_view(),name='portal'), url(r"^accounts/register/$", SignUpView.as_view(), name="signup"), url(r"^accounts/login/$", LoginView.as_view(), name="login"), url(r"^accounts/logout/$", LogOutView.as_view(), name="logout"), # url(r'p/?P<portal>/$', HomePageView.as_view(), name ='portal'), url(r"^admin/", include(admin.site.urls)), url(r"^signups/", include("signups.urls")), url(r"^reports/", include("reports.urls", namespace="reports")), url(r"^media/(?P<path>.*)$", "django.views.static.serve", {"document_root": settings.MEDIA_ROOT}), url(r"^language/(?P<language>[a-zA-Z\-]+)/$", "reports.views.language"), url(r"^data.geojson$", GeoJSONLayerView.as_view(model=Report), name="data"), url(r"^p/save_marker/$", "home.views.save_marker", name="save_marker"), url(r"^p/remove_marker/$", "home.views.remove_marker", name="remove_marker"), )
from django.conf.urls import include, url # from django.contrib import admin from djgeojson.views import TiledGeoJSONLayerView, GeoJSONLayerView from erm.settings import RootModel from erm.views import base, geo urlpatterns = [ url(r'^karte/', base.show_map), url(r'^tilegeojson/(?P<z>\d+)/(?P<x>\d+)/(?P<y>\d+).geojson$', TiledGeoJSONLayerView.as_view(model=RootModel), name='tilegeojson'), url( r'^map/(?P<min_lon>[0-9.]+)/(?P<min_lat>[0-9.]+)/(?P<max_lon>[0-9.]+)/(?P<max_lat>[0-9.]+)/(?P<zoom>[0-9]+)$', geo.map_cutout), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=RootModel), name='data'), url(r'^(.+)', include('erm.urls')), url(r'^', base.index), ]
from django.conf.urls import url,include from django.contrib import admin from osm import views from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from osm.models import Way,Node urlpatterns = [ url('admin/', admin.site.urls), url(r'^$',include('osm.urls')), url(r'^nodedata/', GeoJSONLayerView.as_view(model=Node, properties=('id','version','visible','incomplete')), name="nodedata"), url(r'^waydata/', GeoJSONLayerView.as_view(model=Way, properties=('id','version','visible','incomplete')), name="waydata"), url(r'^stops/',views.get_stops, name="stops"), url(r'^osm/', views.load, name="load"), url(r'^route_masters', views.get_route_master_relations, name="route_master"), ]
r"login/$", auth_views.LoginView.as_view(template_name="server/login.html"), name="login", ), url( r"^logout/$", auth_views.LogoutView.as_view( next_page=reverse_lazy("server:landing")), name="logout", ), url(r"^home", views.Home.as_view(), name="home"), url( r"^data.geojson$", GeoJSONLayerView.as_view( model=models.AileenBox, properties=("name", "box_id", "geom", "average_observables_per_day"), ), name="aileen_box_location", ), url(r"^box/(?P<box_id>[^/]+)", views.box, name="box"), # ------------------------------------------------------------------------------ # API # ------------------------------------------------------------------------------ url( r"^api/average_number_of_observables_seen_by_box", api.average_number_of_observables_seen_by_box, name="average_number_of_observables_seen_by_box", ), url(r"^api/postEvents/(?P<box_id>[^/]+)/", api.post_events,
from djgeojson.views import GeoJSONLayerView from stateInfo.models import State, County # Uncomment the next two lines to enable the admin: from django.contrib import admin admin.autodiscover() urlpatterns = patterns('', url(r'^$', # noqa TemplateView.as_view(template_name='pages/home.html'), name="home"), url(r'^map/$',TemplateView.as_view(template_name='pages/map.html'),name="map"), url(r'^cooperatives/$',TemplateView.as_view(template_name='pages/cooperatives.html'),name="cooperatives"), url(r'^state.geojson$', GeoJSONLayerView.as_view(model=State), name='state'), url(r'^county.geojson$', GeoJSONLayerView.as_view(model=County), name='county'), # Uncomment the next line to enable the admin: url(r'^admin/', include(admin.site.urls)), # User management url(r'^users/', include("users.urls", namespace="users")), url(r'^accounts/', include('allauth.urls')), # Uncomment the next line to enable avatars url(r'^avatar/', include('avatar.urls')), # Your stuff: custom urls go here ) + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
"""mushrooms URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/stable/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 import settings from django.conf.urls import url from django.conf.urls.static import static from django.contrib import admin from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from .models import Lugar urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data.geojson$', GeoJSONLayerView.as_view( model=Lugar, properties=('nombre', 'descripcion', 'foto_url')), name='data') ] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
"""loco URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.8/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. 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.views.generic import ListView from osm.models import Banks from djgeojson.views import GeoJSONLayerView from django.contrib.gis.measure import D bancos_barranquilla = Banks.objects.filter(wkb_geometry__distance_lte=(barranquilla, D(km=20))) urlpatterns = [ url(r'^$', ListView.as_view(queryset=bancos_barranquilla, template_name='osm/banks.html')), url(r'^banks$', GeoJSONLayerView.as_view(model=Banks), name='data'), url(r'^admin/', include(admin.site.urls)), ]
from django.views.generic import TemplateView from django.conf.urls import url from djgeojson.views import GeoJSONLayerView from altonode.world.models import Location urlpatterns = [ url(r'^data.geojson$', GeoJSONLayerView.as_view(model=Location), name='data') ]
from django.conf.urls import include, url from django.contrib import admin from envdata.api import SampleResource, PopulationResource from tastypie.api import Api from www import views as www_views from django.conf import settings from django.conf.urls.static import static from djgeojson.views import GeoJSONLayerView, TiledGeoJSONLayerView from envdata.models import Sample sample_resource = SampleResource() population_resource = PopulationResource() v1_api = Api(api_name='v1') v1_api.register(sample_resource) v1_api.register(population_resource) urlpatterns = [url('^admin/', admin.site.urls), url('^api/', include(v1_api.urls), name="api"), url('^www/', www_views.index), url('^$', www_views.index), url(r'data.geojson$', GeoJSONLayerView.as_view(model=Sample, properties=['name', 'species']), name='data'), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
from django.contrib import admin from django.urls import path, include from Map.views import * from djgeojson.views import GeoJSONLayerView from django.conf.urls.static import static from django.conf import settings urlpatterns = [ path('admin/', admin.site.urls), path('', home_view, name='home'), path('home/', home_view, name='home'), path('webmap/', webmap_view, name='webmap'), path('folium/', folium_view, name='Folium'), path('data/', GeoJSONLayerView.as_view( model=Webmap, properties=('Nom', 'Département', 'Services', 'link', 'Adress', 'Tel', 'Description_si_disop')), name='data'), path('portfolio/', include('Blog_app.urls'), name='portfolio'), path('contact/', contact_view, name='contact'), path('about/', about_view, name='about'), #path('prestations/', prestations_view,name='prestations'), path('<int:prestation_id>/', prestations_view, name='presdetails'), path('ckeditor/', include('ckeditor_uploader.urls')), path('introprestation/', introprestation_view, name='introprestation'), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
from django.contrib import admin from django.conf.urls import url, include from . import views from djgeojson.views import GeoJSONLayerView from multigtfs.models import Stop from osmapp.models import Node from gtfs.models import GTFSForm from django.views.generic import TemplateView from .views import FormView urlpatterns = [ url('admin/', admin.site.urls), url(r'^$', include('gtfs.urls'), name='gtfs'), url(r'^gtfs/', include('gtfs.urls')), url(r'^nodedata/', GeoJSONLayerView.as_view(model=Node, properties=('id')), name="nodedata"), ]
from django.conf.urls import url, include from django.contrib import admin from djgeojson.views import GeoJSONLayerView from django.views.generic import TemplateView from .models import Picture from django.contrib.auth import views as auth_views from . import views urlpatterns = [ url(r'^$', views.startpage, name = 'start'), url(r'^photodata/$', GeoJSONLayerView.as_view(model=Picture), name = 'data'), url(r'^worlddata/$',views.country_data,name = 'worlddata'), url(r'^login/$', auth_views.login, {'template_name': 'login.html'}, name='login'), url(r'^logout/$', auth_views.logout, {'next_page': 'login'}, name='logout'), url(r'^userhome/$', views.userhome, name = 'userhome'), url(r'^signup/$', views.signup, name = 'signup'), url(r'^userhome/edit/$', views.edit_profile, name = 'editprofile') ]
from django.conf.urls import url from geopolls.views import SubmissionCreate, submission_new from djgeojson.views import GeoJSONLayerView from .models import Submission from . import views from django.views.generic import TemplateView from django.conf import settings from django.conf.urls.static import static urlpatterns = [ url(r'^submissions/new/$', views.submission_new, name='submission_new'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=Submission), name='data'), url(r'^submissions/$', TemplateView.as_view(template_name="geopolls/submissions.html"), name='submissions'), # ... # url(r'submission/add/$', SubmissionCreate, name='submission-add'), # url(r'^submission/data/$', GeoJSONLayerView.as_view(model=Submission), name='data') # url(r'author/(?P<pk>[0-9]+)/$', AuthorUpdate.as_view(), name='author-update'), # url(r'author/(?P<pk>[0-9]+)/delete/$', AuthorDelete.as_view(), name='author-delete'), ]
from django.conf.urls import url from djgeojson.views import GeoJSONLayerView from .models import GeofenceLocations, LocationPoints, Obstacles from . import views urlpatterns = [ url(r'^$', views.view_maps, name='view_maps'), # url(r'^locations/$', views.locations_datasets, name='locations'), url(r'^locations/datasets$', GeoJSONLayerView.as_view(model=LocationPoints, properties=( 'name', 'radius', 'ICAO_shortcode', 'IATA_shortcode', )), name='location_datasets'), # url(r'^geofence/datasets$', views.geofence_datasets, name='geofence_datasets'), url(r'^geofence/datasets$', GeoJSONLayerView.as_view(model=GeofenceLocations, properties=('name', )), name='geofence_datasets'), url(r'^geofences/$', views.view_geofences, name='view_geofences'), # url(r'^geofences/view$', views.geofence_datasets, name='geofences'), url(r'^geofences/create/$', views.LocationsCreateView.as_view(),
from django.conf.urls import url from django.contrib import admin from djgeojson.views import GeoJSONLayerView from igam import views from .models import Pontos urlpatterns = [ url(r'mapaigam/pontos.geojson$', GeoJSONLayerView.as_view(model= Pontos, \ properties=('id',) \ ), name='data'), \ url(r'^mapaigam/$', views.mapaigam), url(r'mapaigam/pontoIgam/(?P<id>\d+)/$', views.pontoIgam), ]
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, patterns from django.contrib import admin from rest_framework.routers import DefaultRouter from bel.views import HouseViewSet from django.views.generic import TemplateView from djgeojson.views import GeoJSONLayerView from django.contrib.gis import admin from bel.models import House router = DefaultRouter() router.register(r'houses', HouseViewSet) # from https://github.com/leplatrem/django-leaflet-geojson urlpatterns = [ url(r'^$', TemplateView.as_view(template_name='index.html'), name='home'), url(r'^data.geojson$', GeoJSONLayerView.as_view(model=House), name='data'), url(r'^admin/', include(admin.site.urls)), url(r'^api/', include(router.urls)), ]