# Generated by Django 5.1.1 on 2024-09-26 23:43

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


class Migration(migrations.Migration):
    dependencies = [
        ("bloomerp", "0020_alter_documenttemplate_template_and_more"),
    ]

    operations = [
        migrations.CreateModel(
            name="UserDashboardView",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("datetime_created", models.DateTimeField(auto_now_add=True)),
                ("datetime_updated", models.DateTimeField(auto_now=True)),
                (
                    "name",
                    models.CharField(
                        help_text="The name of the dashboard", max_length=255
                    ),
                ),
                ("kpis", models.ManyToManyField(to="bloomerp.kpi")),
                (
                    "user",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="dashboard_view",
                        to=settings.AUTH_USER_MODEL,
                    ),
                ),
            ],
            options={
                "db_table": "bloomerp_user_dashboard_view",
                "managed": True,
            },
        ),
        migrations.DeleteModel(
            name="UserKpiListViewPreference",
        ),
    ]
