# Generated by Django 5.2 on 2025-04-23 12:46

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('base', '0003_initial'),
        ('careteams', '0002_initial'),
        ('organizations', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='GoalAddressesReference',
            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)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='GoalSourceReference',
            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)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='GoalSubjectReference',
            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)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='GoalTarget',
            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)),
                ('detail_string', models.CharField(max_length=255, null=True)),
                ('detail_boolean', models.BooleanField(default=False)),
                ('detail_integer', models.IntegerField(null=True)),
                ('due_date', models.DateField(null=True)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='GoalAcceptance',
            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)),
                ('status', models.CharField(choices=[('agree', 'Agree'), ('disagree', 'Disagree'), ('pending', 'Pending')], max_length=255)),
                ('priority', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_acceptance_priority', to='base.codeableconcept')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Goal',
            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)),
                ('lifecycle_status', models.CharField(choices=[('proposed', 'Proposed'), ('planned', 'Planned'), ('accepted', 'Accepted'), ('active', 'Active'), ('on-hold', 'On Hold'), ('completed', 'Completed'), ('cancelled', 'Cancelled'), ('entered-in-error', 'Entered in Error'), ('rejected', 'Rejected')], max_length=255)),
                ('continuous', models.BooleanField(default=False)),
                ('start_date', models.DateField(null=True)),
                ('status_date', models.DateField(null=True)),
                ('achievement_status', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_achievement_status', to='base.codeableconcept')),
                ('category', models.ManyToManyField(blank=True, related_name='goal_category', to='base.codeableconcept')),
                ('description', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_description', to='base.codeableconcept')),
                ('identifier', models.ManyToManyField(blank=True, related_name='goal_identifier', to='base.identifier')),
                ('note', models.ManyToManyField(blank=True, related_name='goal_note', to='base.annotation')),
                ('priority', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_priority', to='base.codeableconcept')),
                ('start_codeable_concept', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_start_code', to='base.codeableconcept')),
                ('status_reason', models.ManyToManyField(blank=True, related_name='goal_status_code', to='base.codeableconcept')),
                ('acceptance', models.ManyToManyField(blank=True, related_name='goal_acceptance', to='goals.goalacceptance')),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='GoalAcceptanceParticipantReference',
            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)),
                ('care_team', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_acceptance_participant_reference_care_team', to='careteams.careteam')),
                ('identifier', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_acceptance_participant_reference_identifier', to='base.identifier')),
                ('organization', models.ForeignKey(null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='goal_acceptance_participant_reference_organization', to='organizations.organization')),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
