# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2019-01-16 05:54
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='diseases',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=150)),
            ],
            options={
                'verbose_name_plural': 'Diseases',
            },
        ),
        migrations.CreateModel(
            name='event',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=100)),
                ('date', models.DateField(null=True)),
                ('body', models.TextField()),
                ('image', models.ImageField(default='blog/images/news-newsletter-newspaper-information-158651_5PJlC13.png', editable=False, upload_to='images/eventpics')),
                ('location', models.CharField(max_length=200)),
            ],
        ),
        migrations.CreateModel(
            name='message',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=50)),
                ('body', models.TextField()),
                ('datesent', models.DateField(null=True)),
                ('read', models.BooleanField(default=0)),
            ],
        ),
        migrations.CreateModel(
            name='notification',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('type', models.CharField(choices=[('msg', 'Message'), ('event', 'Event'), ('other', 'Other')], default='Message', max_length=5)),
                ('datesent', models.DateField(null=True)),
                ('title', models.CharField(max_length=50)),
                ('link', models.CharField(max_length=100)),
                ('message', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='mysite.message')),
            ],
        ),
        migrations.CreateModel(
            name='promisAnswers',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date', models.DateField(null=True)),
                ('title', models.CharField(max_length=50)),
                ('answers', models.CharField(max_length=50)),
                ('score', models.IntegerField()),
                ('user', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='promisquestions',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=100)),
                ('questions', models.TextField()),
                ('nanswers', models.IntegerField()),
                ('order', models.CharField(choices=[('low', 'low'), ('high', 'high')], default='High', max_length=5)),
            ],
        ),
        migrations.CreateModel(
            name='symptoms',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=150)),
                ('type', models.CharField(max_length=150)),
            ],
            options={
                'verbose_name_plural': 'Symptoms',
            },
        ),
        migrations.CreateModel(
            name='treatments',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=150)),
                ('type', models.CharField(max_length=150)),
            ],
            options={
                'verbose_name_plural': 'Treatments',
            },
        ),
        migrations.CreateModel(
            name='userProfile',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('about', models.TextField()),
                ('rating', models.FloatField()),
                ('image', models.ImageField(default='blog/images/news-newsletter-newspaper-information-158651_5PJlC13.png', editable=False, upload_to='images/userprofilepics')),
                ('disease', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='mysite.diseases')),
                ('user', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='userProfileSymptom',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('symptom', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='mysite.symptoms')),
                ('user', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='mysite.userProfile')),
            ],
        ),
        migrations.CreateModel(
            name='userProfileSymptomUpdate',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date', models.DateField(null=True)),
                ('level', models.IntegerField()),
                ('symptom', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='mysite.userProfileSymptom')),
            ],
        ),
        migrations.CreateModel(
            name='userProfileTreatment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('datestarted', models.DateField(null=True)),
                ('dateended', models.DateField(null=True)),
                ('dosage', models.CharField(max_length=10)),
                ('overallsatisfaction', models.IntegerField()),
                ('treatment', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='mysite.treatments')),
                ('user', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='mysite.userProfile')),
            ],
        ),
        migrations.AddField(
            model_name='userprofile',
            name='usersymptoms',
            field=models.ManyToManyField(through='mysite.userProfileSymptom', to='mysite.symptoms'),
        ),
        migrations.AddField(
            model_name='userprofile',
            name='usertreatments',
            field=models.ManyToManyField(through='mysite.userProfileTreatment', to='mysite.treatments'),
        ),
        migrations.AddField(
            model_name='symptoms',
            name='treatments',
            field=models.ManyToManyField(blank=True, to='mysite.treatments'),
        ),
        migrations.AddField(
            model_name='notification',
            name='recieved',
            field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='reciever', to='mysite.userProfile'),
        ),
        migrations.AddField(
            model_name='notification',
            name='sentby',
            field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='sentby', to='mysite.userProfile'),
        ),
        migrations.AddField(
            model_name='message',
            name='recieved',
            field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='userrecieved', to='mysite.userProfile'),
        ),
        migrations.AddField(
            model_name='message',
            name='sent',
            field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='usersent', to='mysite.userProfile'),
        ),
        migrations.AddField(
            model_name='diseases',
            name='symptoms',
            field=models.ManyToManyField(blank=True, to='mysite.symptoms'),
        ),
        migrations.AddField(
            model_name='diseases',
            name='treatments',
            field=models.ManyToManyField(blank=True, to='mysite.treatments'),
        ),
    ]
