Setup Mariadb

This commit is contained in:
Johannes Randerath
2024-05-31 22:32:30 +02:00
parent 1b0d8a2ce9
commit a18927bad1
19 changed files with 233 additions and 3 deletions

View File

@@ -0,0 +1,3 @@
from django.contrib import admin
# Register your models here.

View File

@@ -0,0 +1,6 @@
from django.apps import AppConfig
class PtMapConfig(AppConfig):
default_auto_field = 'django.db.models.BigAutoField'
name = 'pt_map'

View File

@@ -0,0 +1,3 @@
from django.db import models

View File

@@ -0,0 +1,3 @@
from django.test import TestCase
# Create your tests here.

View File

@@ -0,0 +1,6 @@
from django.urls import path
from . import views
urlpatterns = [
path("", views.index, name="index"),
]

View File

@@ -0,0 +1,6 @@
from django.shortcuts import render
from django.http import HttpResponse
def index(request):
return HttpResponse("Test")

View File

@@ -75,8 +75,11 @@ WSGI_APPLICATION = 'transport_accessibility.wsgi.application'
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': BASE_DIR / 'db.sqlite3',
'ENGINE': 'django.db.backends.mysql',
'NAME': 'transport_accessibility',
'HOST': 'localhost',
'USER': 'transport_accessibility',
'PASSWORD': 'L8AClYIsC55SEAWTgYopD',
}
}

View File

@@ -15,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 path, include
urlpatterns = [
path('admin/', admin.site.urls),
path('', include("pt_map.urls"))
]