StudE-Backend/stude/subjects/migrations/0001_initial.py

30 lines
1.1 KiB
Python
Raw Normal View History

2023-06-27 18:15:31 +08:00
# Generated by Django 4.2.2 on 2023-06-27 09:44
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
('year_levels', '0001_initial'),
('courses', '0001_initial'),
('semesters', '0001_initial'),
]
operations = [
migrations.CreateModel(
name='Subject',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=64)),
('code', models.CharField(max_length=16)),
('courses', models.ManyToManyField(related_name='SubjectCourse_subject', through='courses.SubjectCourse', to='courses.course')),
('semester', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='semesters.semester')),
('year_level', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='Year_Level_name', to='year_levels.year_level')),
],
),
]