# Generated by Django 5.0.8 on 2024-10-22 12:10

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


class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name="Category",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                ("updated_at", models.DateTimeField(auto_now=True)),
                ("name", models.CharField(max_length=255, verbose_name="Nomi")),
            ],
            options={
                "verbose_name": "Kategoriya",
                "verbose_name_plural": "Kategoriyalar",
            },
        ),
        migrations.CreateModel(
            name="Photo",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                ("updated_at", models.DateTimeField(auto_now=True)),
                (
                    "name",
                    models.CharField(
                        blank=True, max_length=255, null=True, verbose_name="Nomi"
                    ),
                ),
                (
                    "description",
                    models.TextField(blank=True, null=True, verbose_name="Tavsif"),
                ),
                ("image", models.FileField(upload_to="media/", verbose_name="Fayl")),
                (
                    "type",
                    models.CharField(
                        blank=True, max_length=255, null=True, verbose_name="Fayl turi"
                    ),
                ),
                (
                    "size",
                    models.BigIntegerField(
                        blank=True, default=0, null=True, verbose_name="Hajmi"
                    ),
                ),
            ],
            options={
                "verbose_name": "Foto",
                "verbose_name_plural": "Fotolar",
            },
        ),
        migrations.CreateModel(
            name="Geology",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                ("updated_at", models.DateTimeField(auto_now=True)),
                ("name", models.CharField(max_length=255, verbose_name="Nomi")),
                ("title", models.CharField(max_length=255, verbose_name="Sarlavha")),
                ("body1", models.TextField(verbose_name="Tavsif1")),
                ("body2", models.TextField(verbose_name="Tavsif2")),
                ("body3", models.TextField(verbose_name="Tavsif3")),
                (
                    "banner",
                    models.ImageField(
                        blank=True,
                        null=True,
                        upload_to="banners/",
                        verbose_name="Banner",
                    ),
                ),
                ("address", models.CharField(max_length=255, verbose_name="Manzil")),
                ("longitude", models.FloatField(verbose_name="Boylam")),
                ("latitude", models.FloatField(verbose_name="Kenglik")),
                ("composition", models.TextField(verbose_name="Tarkib")),
                ("isp", models.TextField(verbose_name="ISP")),
                ("analysis", models.TextField(verbose_name="Analiz")),
                (
                    "category",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="cultures",
                        to="geology.category",
                        verbose_name="Kategoriya",
                    ),
                ),
                (
                    "photos1",
                    models.ManyToManyField(
                        related_name="geology_photos1",
                        to="geology.photo",
                        verbose_name="Fotolavhalar",
                    ),
                ),
                (
                    "photos2",
                    models.ManyToManyField(
                        related_name="geology_photos2",
                        to="geology.photo",
                        verbose_name="Fotolavhalar",
                    ),
                ),
            ],
            options={
                "verbose_name": "Madan",
                "verbose_name_plural": "Madanlar",
            },
        ),
    ]
