# Generated by Django 4.2.20 on 2025-06-28 18:31

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


class Migration(migrations.Migration):

    dependencies = [
        ("corpuses", "0018_corpus_md_description_corpusdescriptionrevision"),
        ("documents", "0016_documentsummaryrevision"),
    ]

    operations = [
        migrations.AlterModelOptions(
            name="documentsummaryrevision",
            options={"ordering": ("document_id", "corpus_id", "version")},
        ),
        migrations.RemoveIndex(
            model_name="documentsummaryrevision",
            name="documents_d_documen_29cde2_idx",
        ),
        migrations.AlterUniqueTogether(
            name="documentsummaryrevision",
            unique_together=set(),
        ),
        migrations.AddField(
            model_name="documentsummaryrevision",
            name="corpus",
            field=models.ForeignKey(
                default=1,
                on_delete=django.db.models.deletion.CASCADE,
                related_name="document_summary_revisions",
                to="corpuses.corpus",
            ),
            preserve_default=False,
        ),
        migrations.AlterUniqueTogether(
            name="documentsummaryrevision",
            unique_together={("document", "corpus", "version")},
        ),
        migrations.AddIndex(
            model_name="documentsummaryrevision",
            index=models.Index(
                fields=["document", "corpus"], name="documents_d_documen_9662ae_idx"
            ),
        ),
    ]
