- accounts/models.py: add district_changed_at DateTimeField + VALID_DISTRICTS constant (14 Kerala districts) - migration 0013_user_district_changed_at: nullable DateTimeField, no backfill - WebRegisterForm: accept optional district during signup, stamp district_changed_at - UpdateProfileView: enforce 183-day cooldown with human-readable error - LoginView/WebRegisterView/StatusView: include district_changed_at in responses Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
17 lines
357 B
Python
17 lines
357 B
Python
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
('accounts', '0012_user_eventify_id'),
|
|
]
|
|
|
|
operations = [
|
|
migrations.AddField(
|
|
model_name='user',
|
|
name='district_changed_at',
|
|
field=models.DateTimeField(blank=True, null=True),
|
|
),
|
|
]
|