# Generated by Django 2.2.2 on 2019-10-01 10:45

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='drug',
            fields=[
                ('id', models.CharField(max_length=250, primary_key=True, serialize=False)),
                ('drug_name', models.CharField(max_length=250)),
                ('drug_bank_id', models.IntegerField(default=0)),
                ('state', models.CharField(max_length=250)),
                ('indication', models.CharField(default='NA', max_length=50)),
                ('iupac_name', models.CharField(default='NA', max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='pharmacogenes',
            fields=[
                ('id', models.CharField(max_length=250, primary_key=True, serialize=False)),
                ('gene_name', models.CharField(default='NA', max_length=50)),
                ('protein', models.CharField(default='NA', max_length=50)),
                ('function', models.TextField(default='NA', max_length=50)),
                ('chromosome', models.CharField(default='NA', max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='snp',
            fields=[
                ('id', models.AutoField(primary_key=True, serialize=False)),
                ('snp_id', models.CharField(default='NA', max_length=50)),
                ('rs_id', models.CharField(max_length=50)),
                ('allele', models.CharField(max_length=50)),
                ('phenotype', models.TextField()),
                ('p_value', models.CharField(max_length=10)),
                ('source', models.CharField(max_length=50)),
                ('id_in_source', models.CharField(max_length=50)),
                ('chromosome', models.CharField(max_length=50)),
                ('drug', models.ForeignKey(default='DRUG1', on_delete=django.db.models.deletion.CASCADE, to='agmp_app.drug')),
                ('gene', models.ForeignKey(default='PHARGENE19', on_delete=django.db.models.deletion.CASCADE, to='agmp_app.pharmacogenes')),
            ],
        ),
        migrations.CreateModel(
            name='star_allele_ethnicity_country',
            fields=[
                ('id', models.CharField(max_length=250, primary_key=True, serialize=False)),
                ('star_allele', models.CharField(max_length=50)),
                ('region', models.CharField(max_length=50)),
                ('country_of_participants', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='study',
            fields=[
                ('id', models.CharField(max_length=250, primary_key=True, serialize=False)),
                ('title', models.CharField(max_length=250)),
                ('external_id', models.CharField(max_length=50)),
                ('type', models.CharField(max_length=250)),
                ('date', models.DateField(default=django.utils.timezone.now)),
            ],
        ),
        migrations.CreateModel(
            name='star_allele',
            fields=[
                ('id', models.AutoField(primary_key=True, serialize=False)),
                ('star_id', models.CharField(default='NA', max_length=250)),
                ('star_annotation', models.CharField(max_length=50)),
                ('allele', models.CharField(max_length=50)),
                ('phenotype', models.CharField(max_length=50)),
                ('p_value', models.CharField(max_length=10)),
                ('source', models.CharField(max_length=50)),
                ('id_in_source', models.CharField(max_length=50)),
                ('chromosome', models.CharField(max_length=50)),
                ('drug', models.ForeignKey(default='DRUG1', on_delete=django.db.models.deletion.CASCADE, to='agmp_app.drug')),
                ('gene', models.ForeignKey(default='PHARGENE19', on_delete=django.db.models.deletion.CASCADE, to='agmp_app.pharmacogenes')),
                ('reference', models.ForeignKey(default='REF1', on_delete=django.db.models.deletion.CASCADE, to='agmp_app.study')),
            ],
        ),
        migrations.CreateModel(
            name='snp_ethnicity_country',
            fields=[
                ('id', models.CharField(max_length=250, primary_key=True, serialize=False)),
                ('region', models.CharField(max_length=50)),
                ('country_of_participants', models.CharField(max_length=50)),
                ('snp', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='agmp_app.snp')),
            ],
        ),
        migrations.AddField(
            model_name='snp',
            name='reference',
            field=models.ForeignKey(default='REF1', on_delete=django.db.models.deletion.CASCADE, to='agmp_app.study'),
        ),
    ]
