# Generated by Django 6.0.3 on 2026-03-26 12:04

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


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.CreateModel(
            name='TenantApplication',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('full_name', models.CharField(max_length=255)),
                ('id_number', models.CharField(max_length=50)),
                ('id_image', models.ImageField(upload_to='ids/')),
                ('emergency_contact', models.CharField(max_length=15)),
                ('mpesa_number', models.CharField(max_length=15)),
                ('occupants', models.IntegerField(default=1)),
                ('inspection_notes', models.TextField(blank=True)),
                ('inspection_images', models.ImageField(blank=True, null=True, upload_to='inspections/')),
                ('status', models.CharField(choices=[('pending', 'Pending'), ('approved', 'Approved'), ('rejected', 'Rejected')], default='pending', max_length=20)),
                ('submitted_at', models.DateTimeField(auto_now_add=True)),
                ('unit', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='properties.unit')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='TenantProfile',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('id_number', models.CharField(max_length=50)),
                ('id_image', models.ImageField(upload_to='ids/')),
                ('emergency_contact', models.CharField(max_length=15)),
                ('mpesa_number', models.CharField(max_length=15)),
                ('occupants', models.IntegerField(default=1)),
                ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
    ]
