Layout.
[wolnelektury.git] / src / education / migrations / 0001_initial.py
1 # Generated by Django 4.0.8 on 2022-12-20 13:23
2
3 from django.db import migrations, models
4 import django.db.models.deletion
5
6
7 class Migration(migrations.Migration):
8
9     initial = True
10
11     dependencies = [
12     ]
13
14     operations = [
15         migrations.CreateModel(
16             name='Course',
17             fields=[
18                 ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
19                 ('slug', models.SlugField()),
20             ],
21         ),
22         migrations.CreateModel(
23             name='Tag',
24             fields=[
25                 ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
26                 ('name', models.CharField(max_length=255)),
27             ],
28         ),
29         migrations.CreateModel(
30             name='YPlaylist',
31             fields=[
32                 ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
33                 ('youtube_id', models.CharField(blank=True, max_length=255)),
34                 ('course', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='education.course')),
35             ],
36         ),
37         migrations.CreateModel(
38             name='Track',
39             fields=[
40                 ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
41                 ('course', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='education.course')),
42             ],
43         ),
44         migrations.CreateModel(
45             name='Item',
46             fields=[
47                 ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
48                 ('youtube_id', models.CharField(blank=True, max_length=255)),
49                 ('order', models.IntegerField(blank=True, default=0)),
50                 ('course', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='education.course')),
51                 ('tags', models.ManyToManyField(blank=True, to='education.tag')),
52             ],
53         ),
54     ]