# Generated by Django 6.0.4 on 2026-06-06 02:55

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('analytics', '0001_initial'),
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.AddField(
            model_name='site',
            name='created_by',
            field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='analytics_sites', to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='hit',
            name='site',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='hits', to='analytics.site'),
        ),
        migrations.AddIndex(
            model_name='hit',
            index=models.Index(fields=['site', 'created_at'], name='analytics_h_site_id_704803_idx'),
        ),
        migrations.AddIndex(
            model_name='hit',
            index=models.Index(fields=['site', 'event_type'], name='analytics_h_site_id_b8c0ad_idx'),
        ),
        migrations.AddIndex(
            model_name='hit',
            index=models.Index(fields=['site', 'path'], name='analytics_h_site_id_9c349e_idx'),
        ),
        migrations.AddIndex(
            model_name='hit',
            index=models.Index(fields=['site', 'session_id'], name='analytics_h_site_id_070f11_idx'),
        ),
    ]
