summaryrefslogtreecommitdiffstats
path: root/api
diff options
context:
space:
mode:
Diffstat (limited to 'api')
-rw-r--r--api/api/analytics/__init__.py0
-rw-r--r--api/api/analytics/__pycache__/__init__.cpython-310.pycbin0 -> 151 bytes
-rw-r--r--api/api/analytics/__pycache__/admin.cpython-310.pycbin0 -> 192 bytes
-rw-r--r--api/api/analytics/__pycache__/apps.cpython-310.pycbin0 -> 436 bytes
-rw-r--r--api/api/analytics/__pycache__/models.cpython-310.pycbin0 -> 189 bytes
-rw-r--r--api/api/analytics/admin.py3
-rw-r--r--api/api/analytics/apps.py6
-rw-r--r--api/api/analytics/migrations/__init__.py0
-rw-r--r--api/api/analytics/models.py3
-rw-r--r--api/api/analytics/tests.py3
-rw-r--r--api/api/analytics/views.py3
-rw-r--r--api/api/api/__pycache__/__init__.cpython-310.pycbin0 -> 145 bytes
-rw-r--r--api/api/api/__pycache__/settings.cpython-310.pycbin0 -> 2305 bytes
-rw-r--r--api/api/api/settings.py2
-rw-r--r--api/api/api/urls.py4
-rw-r--r--api/api/blogs/__init__.py0
-rw-r--r--api/api/blogs/admin.py3
-rw-r--r--api/api/blogs/apps.py6
-rw-r--r--api/api/blogs/migrations/__init__.py0
-rw-r--r--api/api/blogs/models.py4
-rw-r--r--api/api/blogs/tests.py3
-rw-r--r--api/api/blogs/urls.py6
-rw-r--r--api/api/blogs/views.py7
-rw-r--r--api/requirements.txt5
24 files changed, 57 insertions, 1 deletions
diff --git a/api/api/analytics/__init__.py b/api/api/analytics/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/api/api/analytics/__init__.py
diff --git a/api/api/analytics/__pycache__/__init__.cpython-310.pyc b/api/api/analytics/__pycache__/__init__.cpython-310.pyc
new file mode 100644
index 0000000..8701c3b
--- /dev/null
+++ b/api/api/analytics/__pycache__/__init__.cpython-310.pyc
Binary files differ
diff --git a/api/api/analytics/__pycache__/admin.cpython-310.pyc b/api/api/analytics/__pycache__/admin.cpython-310.pyc
new file mode 100644
index 0000000..860bf6d
--- /dev/null
+++ b/api/api/analytics/__pycache__/admin.cpython-310.pyc
Binary files differ
diff --git a/api/api/analytics/__pycache__/apps.cpython-310.pyc b/api/api/analytics/__pycache__/apps.cpython-310.pyc
new file mode 100644
index 0000000..89945e4
--- /dev/null
+++ b/api/api/analytics/__pycache__/apps.cpython-310.pyc
Binary files differ
diff --git a/api/api/analytics/__pycache__/models.cpython-310.pyc b/api/api/analytics/__pycache__/models.cpython-310.pyc
new file mode 100644
index 0000000..2af4eb3
--- /dev/null
+++ b/api/api/analytics/__pycache__/models.cpython-310.pyc
Binary files differ
diff --git a/api/api/analytics/admin.py b/api/api/analytics/admin.py
new file mode 100644
index 0000000..8c38f3f
--- /dev/null
+++ b/api/api/analytics/admin.py
@@ -0,0 +1,3 @@
+from django.contrib import admin
+
+# Register your models here.
diff --git a/api/api/analytics/apps.py b/api/api/analytics/apps.py
new file mode 100644
index 0000000..258d4dd
--- /dev/null
+++ b/api/api/analytics/apps.py
@@ -0,0 +1,6 @@
+from django.apps import AppConfig
+
+
+class AnalyticsConfig(AppConfig):
+ default_auto_field = 'django.db.models.BigAutoField'
+ name = 'analytics'
diff --git a/api/api/analytics/migrations/__init__.py b/api/api/analytics/migrations/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/api/api/analytics/migrations/__init__.py
diff --git a/api/api/analytics/models.py b/api/api/analytics/models.py
new file mode 100644
index 0000000..71a8362
--- /dev/null
+++ b/api/api/analytics/models.py
@@ -0,0 +1,3 @@
+from django.db import models
+
+# Create your models here.
diff --git a/api/api/analytics/tests.py b/api/api/analytics/tests.py
new file mode 100644
index 0000000..7ce503c
--- /dev/null
+++ b/api/api/analytics/tests.py
@@ -0,0 +1,3 @@
+from django.test import TestCase
+
+# Create your tests here.
diff --git a/api/api/analytics/views.py b/api/api/analytics/views.py
new file mode 100644
index 0000000..91ea44a
--- /dev/null
+++ b/api/api/analytics/views.py
@@ -0,0 +1,3 @@
+from django.shortcuts import render
+
+# Create your views here.
diff --git a/api/api/api/__pycache__/__init__.cpython-310.pyc b/api/api/api/__pycache__/__init__.cpython-310.pyc
new file mode 100644
index 0000000..d885b74
--- /dev/null
+++ b/api/api/api/__pycache__/__init__.cpython-310.pyc
Binary files differ
diff --git a/api/api/api/__pycache__/settings.cpython-310.pyc b/api/api/api/__pycache__/settings.cpython-310.pyc
new file mode 100644
index 0000000..850cf57
--- /dev/null
+++ b/api/api/api/__pycache__/settings.cpython-310.pyc
Binary files differ
diff --git a/api/api/api/settings.py b/api/api/api/settings.py
index de415b0..1d155a0 100644
--- a/api/api/api/settings.py
+++ b/api/api/api/settings.py
@@ -31,6 +31,8 @@ ALLOWED_HOSTS = []
# Application definition
INSTALLED_APPS = [
+ 'rest_framework',
+ 'analytics.apps.AnalyticsConfig',
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
diff --git a/api/api/api/urls.py b/api/api/api/urls.py
index 984d718..f23b858 100644
--- a/api/api/api/urls.py
+++ b/api/api/api/urls.py
@@ -1,3 +1,4 @@
+
"""api URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
@@ -14,8 +15,9 @@ Including another URLconf
2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
"""
from django.contrib import admin
-from django.urls import path
+from django.urls import include, path
urlpatterns = [
+ path('blogs/', include('blogs.urls')),
path('admin/', admin.site.urls),
]
diff --git a/api/api/blogs/__init__.py b/api/api/blogs/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/api/api/blogs/__init__.py
diff --git a/api/api/blogs/admin.py b/api/api/blogs/admin.py
new file mode 100644
index 0000000..8c38f3f
--- /dev/null
+++ b/api/api/blogs/admin.py
@@ -0,0 +1,3 @@
+from django.contrib import admin
+
+# Register your models here.
diff --git a/api/api/blogs/apps.py b/api/api/blogs/apps.py
new file mode 100644
index 0000000..03962d1
--- /dev/null
+++ b/api/api/blogs/apps.py
@@ -0,0 +1,6 @@
+from django.apps import AppConfig
+
+
+class BlogsConfig(AppConfig):
+ default_auto_field = 'django.db.models.BigAutoField'
+ name = 'blogs'
diff --git a/api/api/blogs/migrations/__init__.py b/api/api/blogs/migrations/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/api/api/blogs/migrations/__init__.py
diff --git a/api/api/blogs/models.py b/api/api/blogs/models.py
new file mode 100644
index 0000000..b096caa
--- /dev/null
+++ b/api/api/blogs/models.py
@@ -0,0 +1,4 @@
+from django.db import models
+
+# Create your models here.
+
diff --git a/api/api/blogs/tests.py b/api/api/blogs/tests.py
new file mode 100644
index 0000000..7ce503c
--- /dev/null
+++ b/api/api/blogs/tests.py
@@ -0,0 +1,3 @@
+from django.test import TestCase
+
+# Create your tests here.
diff --git a/api/api/blogs/urls.py b/api/api/blogs/urls.py
new file mode 100644
index 0000000..306c8bc
--- /dev/null
+++ b/api/api/blogs/urls.py
@@ -0,0 +1,6 @@
+from django.urls import path
+from . import views
+
+urlpatterns = [
+ path('', views.index, name='index')
+] \ No newline at end of file
diff --git a/api/api/blogs/views.py b/api/api/blogs/views.py
new file mode 100644
index 0000000..69a6f29
--- /dev/null
+++ b/api/api/blogs/views.py
@@ -0,0 +1,7 @@
+from django.shortcuts import render
+from django.http import HttpResponse
+
+def index(request):
+ return HttpResponse("You're at the Blogs index")
+
+# Create your views here.
diff --git a/api/requirements.txt b/api/requirements.txt
new file mode 100644
index 0000000..b481e66
--- /dev/null
+++ b/api/requirements.txt
@@ -0,0 +1,5 @@
+asgiref==3.4.1
+Django==4.0
+djangorestframework==3.13.1
+pytz==2021.3
+sqlparse==0.4.2