# Generated by Django 4.2.14 on 2025-01-10 11:55

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('base', '0003_communication'),
    ]

    operations = [
        migrations.CreateModel(
            name='Condition',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('body_site', models.ManyToManyField(blank=True, related_name='condition_body_site', to='base.codeableconcept')),
                ('category', models.ManyToManyField(blank=True, related_name='condition_category', to='base.codeableconcept')),
                ('clinical_status', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_clinical_status', to='base.codeableconcept')),
                ('code', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_code', to='base.codeableconcept')),
                ('identifier', models.ManyToManyField(blank=True, related_name='condition_identifier', to='base.identifier')),
                ('severity', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_severity', to='base.codeableconcept')),
                ('verification_status', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_verification_status', to='base.codeableconcept')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='ConditionReference',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('reference', models.CharField(max_length=255, null=True)),
                ('type', models.CharField(max_length=255, null=True)),
                ('display', models.CharField(max_length=255, null=True)),
                ('condition', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_reference', to='conditions.condition')),
                ('identifier', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_reference_identifier', to='base.identifier')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='ConditionCodeableReference',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('concept', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_concept', to='base.codeableconcept')),
                ('reference', models.ForeignKey(on_delete=django.db.models.deletion.DO_NOTHING, related_name='condition_codeable_reference', to='conditions.conditionreference')),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
