# Generated by Django 5.2.9 on 2026-02-10 08:27

from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('wbportfolio', '0097_alter_product_options_and_more'),
    ]

    operations = [
        migrations.AddField(
            model_name='claim',
            name='created',
            field=models.DateTimeField(auto_now_add=True, blank=True, null=True, verbose_name='Created'),
            preserve_default=False,
        ),
        migrations.AddField(
            model_name='claim',
            name='updated',
            field=models.DateTimeField(blank=True, null=True, verbose_name='Updated'),
        ),
        migrations.RunSQL(sql="SET CONSTRAINTS ALL IMMEDIATE;"),
        migrations.RunSQL(
            """
            UPDATE wbportfolio_claim SET created = "date" AT TIME ZONE 'UTC';
            """
        ),
        migrations.RunSQL(
            """
            UPDATE wbportfolio_claim
            SET updated = "date" AT TIME ZONE 'UTC';
            """
        ),
        migrations.RunSQL(sql="SET CONSTRAINTS ALL DEFERRED;"),
        migrations.AlterField(
            model_name='claim',
            name='created',
            field=models.DateTimeField(auto_now_add=True),
            preserve_default=False,
        ),
        migrations.AlterField(
            model_name='claim',
            name='updated',
            field=models.DateTimeField(auto_now=True),
            preserve_default=False,
        ),
        migrations.AddIndex(
            model_name='claim',
            index=models.Index(fields=['account', 'product', 'date'], name='wbportfolio_account_104cdc_idx'),
        ),
    ]
