# Generated by Django 4.0.8 on 2023-05-18 19:27

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


class Migration(migrations.Migration):
    dependencies = [
        ("lti_tool", "0004_lticontext_can_access_results_and_more"),
    ]

    operations = [
        migrations.CreateModel(
            name="LtiLineItem",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("url", models.URLField(unique=True, verbose_name="URL on platform")),
                ("maximum_score", models.FloatField(verbose_name="maximum score")),
                ("label", models.CharField(max_length=255, verbose_name="label")),
                (
                    "tag",
                    models.CharField(blank=True, max_length=255, verbose_name="tag"),
                ),
                (
                    "resource_id",
                    models.CharField(
                        blank=True, max_length=255, verbose_name="resource ID"
                    ),
                ),
                (
                    "start_datetime",
                    models.DateTimeField(null=True, verbose_name="start date/time"),
                ),
                (
                    "end_datetime",
                    models.DateTimeField(null=True, verbose_name="end date/time"),
                ),
                (
                    "context",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="line_items",
                        to="lti_tool.lticontext",
                        verbose_name="context",
                    ),
                ),
                (
                    "resource_link",
                    models.ForeignKey(
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        to="lti_tool.ltiresourcelink",
                    ),
                ),
            ],
        ),
    ]
