# Generated by Django 5.2.7 on 2025-11-27 23:32

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


class Migration(migrations.Migration):

    dependencies = [
        ('core', '0002_create_groups'),
    ]

    operations = [
        migrations.CreateModel(
            name='Property',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('address', models.CharField(max_length=255)),
                ('city', models.CharField(max_length=255)),
                ('state', models.CharField(max_length=2)),
                ('zip_code', models.CharField(max_length=10)),
                ('property_type', models.CharField(choices=[('SINGLE_FAMILY', 'Single Family'), ('MULTI_FAMILY', 'Multi-Family'), ('COMMERCIAL', 'Commercial')], max_length=20)),
                ('square_footage', models.PositiveIntegerField()),
                ('bedrooms', models.PositiveIntegerField()),
                ('bathrooms', models.DecimalField(decimal_places=1, max_digits=3)),
                ('year_built', models.PositiveIntegerField()),
                ('description', models.TextField()),
                ('status', models.CharField(choices=[('FOR_SALE', 'For Sale'), ('FOR_RENT', 'For Rent'), ('SOLD', 'Sold')], max_length=20)),
                ('organization', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='properties', to='core.organization')),
            ],
        ),
        migrations.CreateModel(
            name='PropertyPhoto',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('image', models.ImageField(upload_to='property_photos/')),
                ('caption', models.CharField(blank=True, max_length=255)),
                ('property', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='photos', to='core.property')),
            ],
        ),
    ]
