# Generated by Django 5.1.4 on 2025-01-12 10:59

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='Survey',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('water_usage', models.CharField(choices=[('less_50', 'Less than 50 liters'), ('50_100', '50–100 liters'), ('100_200', '100–200 liters'), ('more_200', 'More than 200 liters')], max_length=20, verbose_name='Daily water usage')),
                ('daily_consumption_awareness', models.CharField(choices=[('yes', 'Yes'), ('no', 'No'), ('not_sure', 'Not sure')], max_length=20, verbose_name='Aware of daily water consumption')),
                ('dripping_tap_wastage', models.CharField(choices=[('less_5', 'Less than 5 liters'), ('5_10', '5–10 liters'), ('10_20', '10–20 liters'), ('more_20', 'More than 20 liters')], max_length=20, verbose_name='Estimated dripping tap wastage')),
                ('brushing_habits', models.CharField(choices=[('always', 'Always'), ('sometimes', 'Sometimes'), ('never', 'Never')], max_length=20, verbose_name='Frequency of turning off tap while brushing')),
                ('fix_leaks', models.CharField(choices=[('yes', 'Yes'), ('no', 'No'), ('not_sure', 'Not sure')], max_length=20, verbose_name='Promptly fix water leaks')),
                ('reuse_water', models.CharField(choices=[('always', 'Always'), ('sometimes', 'Sometimes'), ('never', 'Never')], max_length=20, verbose_name='Frequency of water reuse')),
                ('water_saving_appliances', models.CharField(choices=[('low_flow', 'Low-flow faucets'), ('dual_flush', 'Dual-flush toilets'), ('efficient_machines', 'Water-efficient washing machines'), ('none', 'None')], max_length=50, verbose_name='Water saving appliances used')),
                ('biggest_cause_of_wastage', models.TextField(help_text='Describe what you think is the biggest cause of water wastage', validators=[django.core.validators.MinLengthValidator(10)], verbose_name='Biggest cause of water wastage')),
                ('resources_needed', models.TextField(help_text='What resources would help you conserve water better?', validators=[django.core.validators.MinLengthValidator(10)], verbose_name='Resources needed')),
                ('additional_suggestions', models.TextField(blank=True, help_text='Any additional suggestions for water conservation', verbose_name='Additional suggestions')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='surveys', to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'verbose_name': 'Water Conservation Survey',
                'verbose_name_plural': 'Water Conservation Surveys',
                'ordering': ['-created_at'],
            },
        ),
    ]
