# 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'),
        ('biologicallyderivedproducts', '0001_initial'),
        ('devices', '0001_initial'),
        ('inventoryitems', '0001_initial'),
        ('medications', '0001_initial'),
        ('nutritionproducts', '0001_initial'),
        ('organizations', '0001_initial'),
        ('patients', '0001_initial'),
    ]

    operations = [
        migrations.AddField(
            model_name='inventoryiteminstance',
            name='subject',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_instances_subjects', to='patients.patientorganizationreference'),
        ),
        migrations.AddField(
            model_name='inventoryitem',
            name='instance',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_items_insurances', to='inventoryitems.inventoryiteminstance'),
        ),
        migrations.AddField(
            model_name='inventoryitem',
            name='name',
            field=models.ManyToManyField(blank=True, related_name='inventory_items_names', to='inventoryitems.inventoryitemname'),
        ),
        migrations.AddField(
            model_name='inventoryitemproductreference',
            name='biologically_derived_product',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_product_references_biologicallyderived_product', to='biologicallyderivedproducts.biologicallyderivedproduct'),
        ),
        migrations.AddField(
            model_name='inventoryitemproductreference',
            name='device',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_product_reference_devices', to='devices.device'),
        ),
        migrations.AddField(
            model_name='inventoryitemproductreference',
            name='identifier',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_product_reference_identifiers', to='base.identifier'),
        ),
        migrations.AddField(
            model_name='inventoryitemproductreference',
            name='medication',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_product_reference_medications', to='medications.medication'),
        ),
        migrations.AddField(
            model_name='inventoryitemproductreference',
            name='nutrition_product',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_product_references_nutrition_product', to='nutritionproducts.nutritionproduct'),
        ),
        migrations.AddField(
            model_name='inventoryitem',
            name='product_reference',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_items_product_references', to='inventoryitems.inventoryitemproductreference'),
        ),
        migrations.AddField(
            model_name='inventoryitemreference',
            name='identifier',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_references_identifiers', to='base.identifier'),
        ),
        migrations.AddField(
            model_name='inventoryitemreference',
            name='inventory_item',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_references_inventory_items', to='inventoryitems.inventoryitem'),
        ),
        migrations.AddField(
            model_name='inventoryitemresponsibleorganization',
            name='code',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='inventory_item_responsible_organization_codes', to='base.codeableconcept'),
        ),
        migrations.AddField(
            model_name='inventoryitemresponsibleorganization',
            name='organization',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='inventory_item_responsible_organization_organizations', to='organizations.organization'),
        ),
        migrations.AddField(
            model_name='inventoryitem',
            name='responsible_organization',
            field=models.ManyToManyField(blank=True, related_name='inventory_items_responsible_organizations', to='inventoryitems.inventoryitemresponsibleorganization'),
        ),
    ]
