Finally removed "hello_world".

This commit is contained in:
Marcus Scholz 2020-08-12 19:14:06 +02:00
parent a82ddaa44e
commit 87efccf6c9
2 changed files with 0 additions and 5 deletions

View File

@ -1,6 +1,5 @@
from django.urls import path from django.urls import path
from .views import ( from .views import (
hello_world,
HomeView, HomeView,
place_detail_view, place_detail_view,
place_list_view, place_list_view,
@ -11,7 +10,6 @@ from .views import (
) )
urlpatterns = [ urlpatterns = [
path('hello_world/', hello_world), # You know what this is :P
path('', HomeView.as_view(), name='home'), path('', HomeView.as_view(), name='home'),
path('signup/', SignUpView.as_view(), name='signup'), path('signup/', SignUpView.as_view(), name='signup'),
path('place/<int:pk>/', place_detail_view, name='place_detail'), path('place/<int:pk>/', place_detail_view, name='place_detail'),

View File

@ -51,9 +51,6 @@ def place_list_view(request,):
def place_detail_view(request, pk): def place_detail_view(request, pk):
return render(request, 'place/place_detail.html', {'place':Place.objects.get(pk=pk)}) return render(request, 'place/place_detail.html', {'place':Place.objects.get(pk=pk)})
def hello_world(request):
return render(request, 'hello_world.html', {'text':'Hello World!'})
class HomeView(View): class HomeView(View):
def get(self, request, *args, **kwargs): def get(self, request, *args, **kwargs):
place_list = Place.objects.all().order_by('submitted_when')[:10] place_list = Place.objects.all().order_by('submitted_when')[:10]