-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12 from nansencenter/issue10-wrong-url
Issue10 wrong url
- Loading branch information
Showing
5 changed files
with
20 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
from django.urls import path | ||
from geospaas_adas_viewer.views import AdasIndexView | ||
from geospaas.base_viewer.views import get_geometry_geojson | ||
|
||
app_name = 'geospaas_adas_viewer' | ||
urlpatterns = [ | ||
path('', AdasIndexView.as_view(), name='adasindex'), | ||
path('geometry/<int:pk>', get_geometry_geojson, name='geometry_geojson') | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,5 @@ | ||
from django.conf.urls import include | ||
from django.conf import settings | ||
"""geospaas_project URL Configuration | ||
The `urlpatterns` list routes URLs to views. For more information please see: | ||
https://docs.djangoproject.com/en/1.11/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.urls import url | ||
from django.contrib import admin | ||
from django.urls import include, path | ||
|
||
urlpatterns = [ | ||
|
||
#url(r'^', include('geospaas.urls')), | ||
url('', include('geospaas_adas_viewer.urls')), | ||
|
||
path('', include('geospaas_adas_viewer.urls')), | ||
] | ||
if settings.DEBUG: | ||
from django.conf.urls.static import static | ||
from django.contrib.staticfiles.urls import staticfiles_urlpatterns | ||
from django.views.generic import TemplateView | ||
# Serve static and media files from development server | ||
urlpatterns += staticfiles_urlpatterns() | ||
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) |