# Generated by Django 5.1.1 on 2024-11-10 14:03

from django.db import migrations, models


class Migration(migrations.Migration):
    dependencies = [
        ("bloomerp", "0043_applicationfield_db_column"),
    ]

    operations = [
        migrations.CreateModel(
            name="Workspace",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "name",
                    models.CharField(
                        help_text="The name of the workspace", max_length=255
                    ),
                ),
                (
                    "content",
                    models.JSONField(
                        default={
                            "content": [
                                {
                                    "data": {"text": "Welcome to your workspace"},
                                    "size": 12,
                                    "type": "header",
                                },
                                {
                                    "data": {
                                        "text": "This is your workspace. You can add widgets, links, and other content here."
                                    },
                                    "size": 12,
                                    "type": "text",
                                },
                                {
                                    "data": {"text": "Example of widget"},
                                    "size": 12,
                                    "type": "header",
                                },
                                {
                                    "data": {"widget_id": 5},
                                    "size": 12,
                                    "type": "widget",
                                },
                                {
                                    "data": {"text": "Example of link"},
                                    "size": 12,
                                    "type": "header",
                                },
                                {"data": {"link_id": 1}, "size": 12, "type": "link"},
                                {
                                    "data": {"text": "Example of link"},
                                    "size": 12,
                                    "type": "header",
                                },
                                {"data": {"id": 2}, "size": 12, "type": "link"},
                                {
                                    "data": {"text": "Example of link list"},
                                    "size": 12,
                                    "type": "header",
                                },
                                {
                                    "data": {"links": [1, 2]},
                                    "size": 12,
                                    "type": "link_list",
                                },
                            ]
                        },
                        help_text="The content of the workspace",
                    ),
                ),
            ],
            options={
                "db_table": "bloomerp_workspace",
                "managed": True,
            },
        ),
    ]
