# Generated by Django 2.2.6 on 2019-12-19 16:17

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Comments',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('text', models.CharField(max_length=255)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Users',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('login', models.CharField(max_length=30)),
                ('password', models.CharField(max_length=30)),
                ('email', models.EmailField(max_length=50)),
                ('privilige', models.IntegerField(default=1)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Triggers',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('course_values_for_trigger', models.FloatField(default=255)),
                ('date_of_trigger', models.DateTimeField(verbose_name='date of trigger')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Users')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Transactions',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('price', models.FloatField(default=255)),
                ('price_forecast', models.FloatField(default=255)),
                ('currency', models.CharField(max_length=255)),
                ('date_of_transaction', models.DateTimeField(verbose_name='date of transaction')),
                ('course_on_payment', models.FloatField(default=255)),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Users')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Threads',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=30)),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Users')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Subjects',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=30)),
                ('thread', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Threads')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Users')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Ratings',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('value', models.IntegerField()),
                ('comment', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Comments')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Users')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.AddField(
            model_name='comments',
            name='subject',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Subjects'),
        ),
        migrations.AddField(
            model_name='comments',
            name='user',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='generalApp.Users'),
        ),
    ]
