diff --git a/codelion/django/blogproject/blogapp/__pycache__/__init__.cpython-39.pyc b/codelion/django/blogproject/blogapp/__pycache__/__init__.cpython-39.pyc new file mode 100644 index 0000000..4ba649d Binary files /dev/null and b/codelion/django/blogproject/blogapp/__pycache__/__init__.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogapp/__pycache__/admin.cpython-39.pyc b/codelion/django/blogproject/blogapp/__pycache__/admin.cpython-39.pyc new file mode 100644 index 0000000..79d01c7 Binary files /dev/null and b/codelion/django/blogproject/blogapp/__pycache__/admin.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogapp/__pycache__/apps.cpython-39.pyc b/codelion/django/blogproject/blogapp/__pycache__/apps.cpython-39.pyc new file mode 100644 index 0000000..fef4667 Binary files /dev/null and b/codelion/django/blogproject/blogapp/__pycache__/apps.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogapp/__pycache__/models.cpython-39.pyc b/codelion/django/blogproject/blogapp/__pycache__/models.cpython-39.pyc new file mode 100644 index 0000000..57f7943 Binary files /dev/null and b/codelion/django/blogproject/blogapp/__pycache__/models.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogapp/__pycache__/views.cpython-39.pyc b/codelion/django/blogproject/blogapp/__pycache__/views.cpython-39.pyc new file mode 100644 index 0000000..80d6892 Binary files /dev/null and b/codelion/django/blogproject/blogapp/__pycache__/views.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogapp/migrations/__pycache__/__init__.cpython-39.pyc b/codelion/django/blogproject/blogapp/migrations/__pycache__/__init__.cpython-39.pyc new file mode 100644 index 0000000..cdfb7df Binary files /dev/null and b/codelion/django/blogproject/blogapp/migrations/__pycache__/__init__.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogapp/templates/blogapp/index.html b/codelion/django/blogproject/blogapp/templates/blogapp/index.html new file mode 100644 index 0000000..d048180 --- /dev/null +++ b/codelion/django/blogproject/blogapp/templates/blogapp/index.html @@ -0,0 +1 @@ +

안녕하세요.

\ No newline at end of file diff --git a/codelion/django/blogproject/blogapp/views.py b/codelion/django/blogproject/blogapp/views.py index 91ea44a..e12448c 100644 --- a/codelion/django/blogproject/blogapp/views.py +++ b/codelion/django/blogproject/blogapp/views.py @@ -1,3 +1,5 @@ from django.shortcuts import render # Create your views here. +def home(request): + return render(request, 'blogapp/index.html') \ No newline at end of file diff --git a/codelion/django/blogproject/blogproject/__pycache__/settings.cpython-39.pyc b/codelion/django/blogproject/blogproject/__pycache__/settings.cpython-39.pyc index 816781b..32da53f 100644 Binary files a/codelion/django/blogproject/blogproject/__pycache__/settings.cpython-39.pyc and b/codelion/django/blogproject/blogproject/__pycache__/settings.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogproject/__pycache__/urls.cpython-39.pyc b/codelion/django/blogproject/blogproject/__pycache__/urls.cpython-39.pyc index 35e90c2..4fff2e6 100644 Binary files a/codelion/django/blogproject/blogproject/__pycache__/urls.cpython-39.pyc and b/codelion/django/blogproject/blogproject/__pycache__/urls.cpython-39.pyc differ diff --git a/codelion/django/blogproject/blogproject/settings.py b/codelion/django/blogproject/blogproject/settings.py index 5d109a7..7cf2ab0 100644 --- a/codelion/django/blogproject/blogproject/settings.py +++ b/codelion/django/blogproject/blogproject/settings.py @@ -37,6 +37,7 @@ 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', + 'blogapp' ] MIDDLEWARE = [ diff --git a/codelion/django/blogproject/blogproject/urls.py b/codelion/django/blogproject/blogproject/urls.py index 5283dd5..bf151cf 100644 --- a/codelion/django/blogproject/blogproject/urls.py +++ b/codelion/django/blogproject/blogproject/urls.py @@ -1,21 +1,8 @@ -"""blogproject URL Configuration - -The `urlpatterns` list routes URLs to views. For more information please see: - https://docs.djangoproject.com/en/4.0/topics/http/urls/ -Examples: -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 blogapp import views urlpatterns = [ path('admin/', admin.site.urls), + path('', views.home, name='home'), ] diff --git a/codelion/django/blogproject/db.sqlite3 b/codelion/django/blogproject/db.sqlite3 index e69de29..4428d12 100644 Binary files a/codelion/django/blogproject/db.sqlite3 and b/codelion/django/blogproject/db.sqlite3 differ