# Generated by Django 3.0 on 2020-08-06 05:09

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Achievement',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('achv_name', models.CharField(max_length=50)),
                ('achv_condition', models.CharField(max_length=50)),
                ('achv_created_at', models.DateTimeField(auto_now_add=True)),
            ],
        ),
        migrations.CreateModel(
            name='Group',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('profile_pic', models.ImageField(blank=True, null=True, upload_to=None)),
                ('display_pic', models.ImageField(blank=True, null=True, upload_to=None)),
                ('name', models.CharField(max_length=50)),
                ('description', models.CharField(max_length=300)),
                ('email', models.EmailField(blank=True, max_length=254, null=True)),
                ('website', models.CharField(max_length=155)),
                ('created_at', models.DateTimeField(auto_now_add=True)),
            ],
        ),
        migrations.CreateModel(
            name='Post',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('post_body', models.CharField(max_length=1000)),
                ('post_image', models.ImageField(blank=True, null=True, upload_to=None)),
                ('post_date', models.DateTimeField(auto_now_add=True)),
                ('post_group', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='posts_in_group', to='werespond.Group')),
            ],
        ),
        migrations.CreateModel(
            name='Profile',
            fields=[
                ('profile_hp', models.IntegerField(primary_key=True, serialize=False, unique=True)),
                ('profile_name', models.CharField(max_length=60)),
                ('profile_gender', models.CharField(choices=[('m', 'Male'), ('f', 'Female')], default='m', max_length=1)),
                ('is_scdf', models.BooleanField(default=False)),
                ('profile_email', models.EmailField(max_length=254)),
                ('profile_created_at', models.DateTimeField(auto_now_add=True, verbose_name='User Created At')),
            ],
        ),
        migrations.CreateModel(
            name='AchievementReward',
            fields=[
                ('rew_achievement', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='werespond.Achievement')),
                ('rew_reward', models.ImageField(blank=True, upload_to=None)),
            ],
        ),
        migrations.CreateModel(
            name='Report',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('report_location', models.CharField(max_length=250)),
                ('report_description', models.CharField(max_length=250)),
                ('report_image', models.ImageField(blank=True, null=True, upload_to=None)),
                ('report_date', models.DateTimeField(auto_now_add=True)),
                ('report_type', models.CharField(choices=[('c', 'Cardiac Arrest'), ('f', 'Fire Report'), ('h', 'Fire Hazard')], max_length=1)),
                ('report_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='reports', to='werespond.Profile')),
            ],
        ),
        migrations.CreateModel(
            name='PostVote',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('vote_post', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user_who_voted', to='werespond.Post')),
                ('vote_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='votes', to='werespond.Profile')),
            ],
        ),
        migrations.CreateModel(
            name='PostSave',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('save_post', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user_who_saved', to='werespond.Post')),
                ('save_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='saves', to='werespond.Profile')),
            ],
        ),
        migrations.AddField(
            model_name='post',
            name='post_user',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='posts', to='werespond.Profile'),
        ),
        migrations.AddField(
            model_name='group',
            name='members',
            field=models.ManyToManyField(blank=True, related_name='groups', to='werespond.Profile'),
        ),
        migrations.CreateModel(
            name='Event',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('slots', models.IntegerField()),
                ('image', models.ImageField(blank=True, null=True, upload_to=None)),
                ('name', models.CharField(max_length=50)),
                ('description', models.CharField(max_length=500)),
                ('date', models.DateField()),
                ('time', models.TimeField()),
                ('venue', models.CharField(max_length=200)),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('users', models.ManyToManyField(blank=True, related_name='events', to='werespond.Profile')),
            ],
        ),
        migrations.CreateModel(
            name='Comment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('comment_content', models.CharField(max_length=300)),
                ('comment_date', models.DateTimeField(auto_now_add=True)),
                ('comment_post', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='user_who_commented', to='werespond.Post')),
                ('comment_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='comments', to='werespond.Profile')),
            ],
        ),
        migrations.CreateModel(
            name='Certificate',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('cert_cert_type', models.CharField(choices=[('c', 'CPR'), ('a', 'AED'), ('b', 'CPR+AED'), ('s', 'Standard First Aid'), ('o', 'Occupational First Aid'), ('p', 'Psychological First Aid'), ('f', 'Fire Safety')], max_length=1)),
                ('cert_image', models.ImageField(blank=True, upload_to=None)),
                ('cert_expiry', models.DateField()),
                ('cert_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='certificates', to='werespond.Profile')),
            ],
        ),
        migrations.CreateModel(
            name='Case',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('location', models.CharField(max_length=600)),
                ('lattitude', models.FloatField()),
                ('longitude', models.FloatField()),
                ('time', models.DateField(auto_now_add=True)),
                ('description', models.CharField(max_length=600)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('case_type', models.CharField(choices=[('c', 'Cardiac Arrest'), ('f', 'Fire Case')], max_length=1, verbose_name='Case Type')),
                ('users', models.ManyToManyField(blank=True, related_name='cases', to='werespond.Profile')),
            ],
        ),
        migrations.CreateModel(
            name='AwardedCertificate',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('awcert_cert_type', models.CharField(choices=[('c', 'CPR'), ('a', 'AED'), ('b', 'CPR+AED'), ('s', 'Standard First Aid'), ('o', 'Occupational First Aid'), ('p', 'Psychological First Aid'), ('f', 'Fire Safety')], max_length=1, verbose_name='User Cert Type')),
                ('awcert_expiry', models.DateField()),
                ('awcert_awarded_at', models.DateTimeField(auto_now_add=True)),
                ('awcert_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='awarded', to='werespond.Profile')),
            ],
        ),
        migrations.AddField(
            model_name='achievement',
            name='achv_users',
            field=models.ManyToManyField(blank=True, related_name='achievements', to='werespond.Profile'),
        ),
    ]
