Compare commits

...

2 commits

Author SHA1 Message Date
827508a480 Created api v1 app 2024-02-25 19:16:55 +01:00
b614d8fb39 Added some database setup infos 2024-02-25 18:47:10 +01:00
12 changed files with 31 additions and 0 deletions

7
README.md Normal file
View file

@ -0,0 +1,7 @@
# Mixr API
## Setup
### Install requirements
If there are any issues with `psycopg2` and that it cannot be imported, you might be missing `libpq-dev`. If you are using a virtual environment, install it with `sudo apt-get install libpq-dev`

6
api_v1/admin.py Normal file
View file

@ -0,0 +1,6 @@
from django.contrib import admin
from .user.models import *
admin.site.register(UserInformation)
# Register your models here.

6
api_v1/apps.py Normal file
View file

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

View file

4
api_v1/models.py Normal file
View file

@ -0,0 +1,4 @@
from django.db import models
from .user.models import *
# Create your models here.

3
api_v1/tests.py Normal file
View file

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

View file

@ -0,0 +1 @@
from .user_information import UserInformation

View file

3
api_v1/views.py Normal file
View file

@ -0,0 +1,3 @@
from django.shortcuts import render
# Create your views here.

View file

@ -31,6 +31,7 @@ ALLOWED_HOSTS = []
# Application definition # Application definition
INSTALLED_APPS = [ INSTALLED_APPS = [
'api_v1.apps.ApiV1Config',
'django.contrib.admin', 'django.contrib.admin',
'django.contrib.auth', 'django.contrib.auth',
'django.contrib.contenttypes', 'django.contrib.contenttypes',