# Generated by Django 2.2.12 on 2020-10-27 14:36

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


class Migration(migrations.Migration):

    dependencies = [
        ("shortcourses", "0017_add_help_text"),
    ]

    operations = [
        migrations.AlterField(
            model_name="shortcoursepage",
            name="application_form_url",
            field=models.URLField(
                blank=True,
                help_text="Adding an application form URL will override the booking link to Access Planit",
            ),
        ),
        migrations.CreateModel(
            name="ShortCourse",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "sort_order",
                    models.IntegerField(blank=True, editable=False, null=True),
                ),
                ("start_date", models.DateField(blank=True, null=True)),
                ("end_date", models.DateField(blank=True, null=True)),
                ("booking_link", models.URLField(blank=True)),
                ("register_interest_link", models.URLField(blank=True)),
                ("cost", models.PositiveIntegerField(blank=True)),
                (
                    "source_page",
                    modelcluster.fields.ParentalKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="manual_bookings",
                        to="shortcourses.ShortCoursePage",
                    ),
                ),
            ],
            options={
                "ordering": ["sort_order"],
                "abstract": False,
            },
        ),
    ]
