# Generated by Django 3.2.4 on 2021-08-05 14:20

import aleksis.core.managers
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('resint', '0006_livedocument'),
        ('reversion', '0001_squashed_0004_auto_20160611_1202'),
        ('chronos', '0008_unique_constraints'),
    ]

    operations = [
        migrations.CreateModel(
            name='AutomaticPlan',
            fields=[
                ('livedocument_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='resint.livedocument')),
                ('number_of_days', models.PositiveIntegerField(default=1, validators=[django.core.validators.MinValueValidator(1)], verbose_name='Number of days shown in the plan')),
                ('show_header_box', models.BooleanField(default=True, help_text='The header box shows affected teachers/groups.', verbose_name='Show header box')),
                ('last_substitutions_revision', models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.SET_NULL, to='reversion.revision', verbose_name='Revision which triggered the last update')),
            ],
            options={
                'verbose_name': 'Automatic plan',
                'verbose_name_plural': 'Automatic plans',
            },
            bases=('resint.livedocument',),
            managers=[
                ('objects', aleksis.core.managers.PolymorphicCurrentSiteManager()),
            ],
        ),
    ]
