# Generated by Django 4.2.17 on 2025-01-04 16:46

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


class Migration(migrations.Migration):
    dependencies = [("club", "0012_club_board_group_club_members_group")]

    operations = [
        migrations.AlterField(
            model_name="club",
            name="board_group",
            field=models.OneToOneField(
                on_delete=django.db.models.deletion.PROTECT,
                related_name="club_board",
                to="core.group",
            ),
        ),
        migrations.AlterField(
            model_name="club",
            name="members_group",
            field=models.OneToOneField(
                on_delete=django.db.models.deletion.PROTECT,
                related_name="club",
                to="core.group",
            ),
        ),
        migrations.AddConstraint(
            model_name="membership",
            constraint=models.CheckConstraint(
                condition=models.Q(("end_date__gte", models.F("start_date"))),
                name="end_after_start",
            ),
        ),
    ]
