mirror of
https://github.com/lemeow125/StudE-Backend.git
synced 2025-06-29 00:35:45 +08:00
Added relationship between user and subjects
This commit is contained in:
parent
dc21bb8c32
commit
e02d81f6fd
6 changed files with 67 additions and 3 deletions
19
stude/accounts/migrations/0003_customuser_subjects.py
Normal file
19
stude/accounts/migrations/0003_customuser_subjects.py
Normal file
|
@ -0,0 +1,19 @@
|
|||
# Generated by Django 4.2.2 on 2023-06-28 03:09
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('subjects', '0002_subjectstudent_subject_students'),
|
||||
('accounts', '0002_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='customuser',
|
||||
name='subjects',
|
||||
field=models.ManyToManyField(related_name='SubjectStudent_user', through='subjects.SubjectStudent', to='subjects.subject'),
|
||||
),
|
||||
]
|
Loading…
Add table
Add a link
Reference in a new issue