# Generated by Django 3.1 on 2020-09-08 15:12

from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import uuid


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Course',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('courseuid', models.UUIDField(default=uuid.uuid4, editable=False)),
                ('coursename', models.CharField(max_length=50)),
            ],
            options={
                'db_table': 'course',
            },
        ),
        migrations.CreateModel(
            name='Teacher',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('firstname', models.CharField(max_length=50)),
                ('lastname', models.CharField(max_length=50)),
                ('username', models.CharField(max_length=50)),
                ('email', models.EmailField(max_length=254)),
                ('password', models.CharField(max_length=100)),
                ('teacheruid', models.UUIDField(default=uuid.uuid4, editable=False)),
                ('image', models.ImageField(default=django.utils.timezone.now, upload_to='uploads/profilepics')),
            ],
            options={
                'db_table': 'teacher',
            },
        ),
        migrations.CreateModel(
            name='Users',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('firstname', models.CharField(max_length=50)),
                ('lastname', models.CharField(max_length=50)),
                ('username', models.CharField(max_length=50)),
                ('email', models.EmailField(max_length=254)),
                ('password', models.CharField(max_length=100)),
                ('useruid', models.UUIDField(default=uuid.uuid4, editable=False)),
                ('usertype', models.CharField(max_length=5)),
                ('image', models.ImageField(default=django.utils.timezone.now, upload_to='uploads/profilepics')),
            ],
            options={
                'db_table': 'users',
            },
        ),
        migrations.CreateModel(
            name='Subscription',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('coursename', models.CharField(max_length=50)),
                ('username', models.CharField(max_length=50)),
                ('courseuid', models.ForeignKey(default=None, on_delete=django.db.models.deletion.CASCADE, to='root.course')),
                ('teacheruid', models.ForeignKey(default=None, on_delete=django.db.models.deletion.CASCADE, to='root.teacher')),
                ('useruid', models.ForeignKey(default=None, on_delete=django.db.models.deletion.CASCADE, to='root.users')),
            ],
            options={
                'db_table': 'subscription',
            },
        ),
        migrations.CreateModel(
            name='Content',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('contentid', models.IntegerField()),
                ('contentheading', models.CharField(max_length=100)),
                ('contentbody', models.TextField()),
                ('contenturl', models.TextField()),
                ('courseuid', models.ForeignKey(default=None, on_delete=django.db.models.deletion.CASCADE, to='root.course')),
            ],
            options={
                'db_table': 'content',
            },
        ),
    ]
