73 lines
3.7 KiB
Python
73 lines
3.7 KiB
Python
|
|
# Generated by Django 5.2.8 on 2025-12-04 11:36
|
||
|
|
|
||
|
|
import django.db.models.deletion
|
||
|
|
from django.conf import settings
|
||
|
|
from django.db import migrations, models
|
||
|
|
|
||
|
|
|
||
|
|
class Migration(migrations.Migration):
|
||
|
|
|
||
|
|
initial = True
|
||
|
|
|
||
|
|
dependencies = [
|
||
|
|
('auth', '0012_alter_user_first_name_max_length'),
|
||
|
|
]
|
||
|
|
|
||
|
|
operations = [
|
||
|
|
migrations.CreateModel(
|
||
|
|
name='ContactMessage',
|
||
|
|
fields=[
|
||
|
|
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||
|
|
('name', models.CharField(max_length=255)),
|
||
|
|
('email', models.EmailField(max_length=254)),
|
||
|
|
('phone', models.CharField(blank=True, max_length=20)),
|
||
|
|
('message', models.TextField()),
|
||
|
|
('created_at', models.DateTimeField(auto_now_add=True)),
|
||
|
|
('is_read', models.BooleanField(default=False)),
|
||
|
|
('is_responded', models.BooleanField(default=False)),
|
||
|
|
],
|
||
|
|
options={
|
||
|
|
'verbose_name': 'Contact Message',
|
||
|
|
'verbose_name_plural': 'Contact Messages',
|
||
|
|
'ordering': ['-created_at'],
|
||
|
|
},
|
||
|
|
),
|
||
|
|
migrations.CreateModel(
|
||
|
|
name='CustomUser',
|
||
|
|
fields=[
|
||
|
|
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||
|
|
('password', models.CharField(max_length=128, verbose_name='password')),
|
||
|
|
('email', models.EmailField(max_length=254, unique=True)),
|
||
|
|
('first_name', models.CharField(max_length=50)),
|
||
|
|
('last_name', models.CharField(max_length=50)),
|
||
|
|
('is_staff', models.BooleanField(default=False)),
|
||
|
|
('is_superuser', models.BooleanField(default=False)),
|
||
|
|
('is_active', models.BooleanField(default=True)),
|
||
|
|
('isVerified', models.BooleanField(default=False)),
|
||
|
|
('verify_otp', models.CharField(blank=True, max_length=6, null=True)),
|
||
|
|
('verify_otp_expiry', models.DateTimeField(blank=True, null=True)),
|
||
|
|
('forgot_password_otp', models.CharField(blank=True, max_length=6, null=True)),
|
||
|
|
('forgot_password_otp_expiry', models.DateTimeField(blank=True, null=True)),
|
||
|
|
('phone_number', models.CharField(blank=True, max_length=20)),
|
||
|
|
('last_login', models.DateTimeField(auto_now=True)),
|
||
|
|
('date_joined', models.DateTimeField(auto_now_add=True)),
|
||
|
|
('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.group', verbose_name='groups')),
|
||
|
|
('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.permission', verbose_name='user permissions')),
|
||
|
|
],
|
||
|
|
options={
|
||
|
|
'abstract': False,
|
||
|
|
},
|
||
|
|
),
|
||
|
|
migrations.CreateModel(
|
||
|
|
name='UserProfile',
|
||
|
|
fields=[
|
||
|
|
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||
|
|
('bio', models.TextField(blank=True, max_length=500)),
|
||
|
|
('timezone', models.CharField(default='UTC', max_length=50)),
|
||
|
|
('created_at', models.DateTimeField(auto_now_add=True)),
|
||
|
|
('updated_at', models.DateTimeField(auto_now=True)),
|
||
|
|
('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='profile', to=settings.AUTH_USER_MODEL)),
|
||
|
|
],
|
||
|
|
),
|
||
|
|
]
|