# Generated by Django 5.2 on 2025-06-01 05:49

import django.db.models.deletion
import lamindb.base.fields
from django.db import migrations


class Migration(migrations.Migration):
    dependencies = [
        ("clinicore", "0013_alter_biosample_artifacts"),
        ("lamindb", "0103_remove_writelog_migration_state_and_more"),
    ]

    operations = [
        migrations.AlterModelOptions(
            name="artifactbiosample",
            options={"base_manager_name": "objects"},
        ),
        migrations.AlterModelOptions(
            name="artifactclinicaltrial",
            options={"base_manager_name": "objects"},
        ),
        migrations.AlterModelOptions(
            name="artifactmedication",
            options={"base_manager_name": "objects"},
        ),
        migrations.AlterModelOptions(
            name="artifactpatient",
            options={"base_manager_name": "objects"},
        ),
        migrations.AlterModelOptions(
            name="artifacttreatment",
            options={"base_manager_name": "objects"},
        ),
        migrations.RenameField(
            model_name="biosample",
            old_name="_branch_code",
            new_name="branch",
        ),
        migrations.RenameField(
            model_name="clinicaltrial",
            old_name="_branch_code",
            new_name="branch",
        ),
        migrations.RenameField(
            model_name="medication",
            old_name="_branch_code",
            new_name="branch",
        ),
        migrations.RenameField(
            model_name="patient",
            old_name="_branch_code",
            new_name="branch",
        ),
        migrations.RenameField(
            model_name="treatment",
            old_name="_branch_code",
            new_name="branch",
        ),
        migrations.AlterField(
            model_name="biosample",
            name="branch",
            field=lamindb.base.fields.ForeignKey(
                blank=True,
                db_column="_branch_code",
                db_default=1,
                default=1,
                on_delete=django.db.models.deletion.PROTECT,
                to="lamindb.branch",
            ),
        ),
        migrations.AlterField(
            model_name="clinicaltrial",
            name="branch",
            field=lamindb.base.fields.ForeignKey(
                blank=True,
                db_column="_branch_code",
                db_default=1,
                default=1,
                on_delete=django.db.models.deletion.PROTECT,
                to="lamindb.branch",
            ),
        ),
        migrations.AlterField(
            model_name="medication",
            name="branch",
            field=lamindb.base.fields.ForeignKey(
                blank=True,
                db_column="_branch_code",
                db_default=1,
                default=1,
                on_delete=django.db.models.deletion.PROTECT,
                to="lamindb.branch",
            ),
        ),
        migrations.AlterField(
            model_name="patient",
            name="branch",
            field=lamindb.base.fields.ForeignKey(
                blank=True,
                db_column="_branch_code",
                db_default=1,
                default=1,
                on_delete=django.db.models.deletion.PROTECT,
                to="lamindb.branch",
            ),
        ),
        migrations.AlterField(
            model_name="treatment",
            name="branch",
            field=lamindb.base.fields.ForeignKey(
                blank=True,
                db_column="_branch_code",
                db_default=1,
                default=1,
                on_delete=django.db.models.deletion.PROTECT,
                to="lamindb.branch",
            ),
        ),
    ]
