mirror of
https://github.com/kristoferssolo/FOSSDB.git
synced 2025-10-21 17:50:35 +00:00
Fix debug mode
This commit is contained in:
parent
012f6fe9c9
commit
b876b0857d
@ -1,4 +1,4 @@
|
||||
# Generated by Django 4.1.7 on 2023-04-09 10:17
|
||||
# Generated by Django 4.2.2 on 2023-06-16 16:30
|
||||
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
@ -32,6 +32,15 @@ class Migration(migrations.Migration):
|
||||
('description', models.TextField(blank=True, default='')),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='OperatingSystem',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=100)),
|
||||
('description', models.TextField(blank=True, default='')),
|
||||
('version', models.CharField(blank=True, max_length=50)),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='ProgrammingLanguage',
|
||||
fields=[
|
||||
@ -58,6 +67,14 @@ class Migration(migrations.Migration):
|
||||
('icon', models.ImageField(blank=True, null=True, upload_to='types/icons/')),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='Star',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='stars', to='fossdb.project')),
|
||||
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
|
||||
],
|
||||
),
|
||||
migrations.CreateModel(
|
||||
name='ProjectProgrammingLanguage',
|
||||
fields=[
|
||||
@ -86,11 +103,21 @@ class Migration(migrations.Migration):
|
||||
name='licenses',
|
||||
field=models.ManyToManyField(to='fossdb.license'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='os',
|
||||
field=models.ManyToManyField(to='fossdb.operatingsystem'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='programming_languages',
|
||||
field=models.ManyToManyField(related_name='projects', through='fossdb.ProjectProgrammingLanguage', to='fossdb.programminglanguage'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='star',
|
||||
field=models.ManyToManyField(related_name='projects_star', to='fossdb.star'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='tag',
|
||||
|
||||
@ -1,27 +0,0 @@
|
||||
# Generated by Django 4.1.7 on 2023-04-09 10:35
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('fossdb', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='OperatingSystem',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=100)),
|
||||
('description', models.TextField(blank=True, default='')),
|
||||
('version', models.CharField(blank=True, max_length=50)),
|
||||
],
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='os',
|
||||
field=models.ManyToManyField(to='fossdb.operatingsystem'),
|
||||
),
|
||||
]
|
||||
@ -1,29 +0,0 @@
|
||||
# Generated by Django 4.1.7 on 2023-04-09 10:51
|
||||
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
('fossdb', '0002_operatingsystem_project_os'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Star',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='stars', to='fossdb.project')),
|
||||
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
|
||||
],
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='star',
|
||||
field=models.ManyToManyField(related_name='projects_star', to='fossdb.star'),
|
||||
),
|
||||
]
|
||||
@ -19,9 +19,6 @@ BASE_PATH = Path(__file__).resolve().parent.parent
|
||||
sys.path.insert(0, str(BASE_PATH.joinpath("FOSSDB", "apps")))
|
||||
|
||||
|
||||
# SECURITY WARNING: don't run with debug turned on in production!
|
||||
DEBUG = BASE_PATH.joinpath("debug").is_file()
|
||||
|
||||
# Quick-start development settings - unsuitable for production
|
||||
# See https://docs.djangoproject.com/en/4.0/howto/deployment/checklist/
|
||||
with open(BASE_PATH.joinpath("config.json"), "r", encoding="UTF-8") as config_file:
|
||||
@ -32,6 +29,8 @@ SECRET_KEY = config["SECRET_KEY"]
|
||||
|
||||
ALLOWED_HOSTS = config["ALLOWED_HOSTS"]
|
||||
|
||||
# SECURITY WARNING: don't run with debug turned on in production!
|
||||
DEBUG = config["DEBUG"]
|
||||
|
||||
# Application definition
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user