base setup

This commit is contained in:
2026-01-07 12:09:20 +05:30
commit 0c275efea1
278 changed files with 11228 additions and 0 deletions

View File

@@ -0,0 +1,50 @@
# Generated by Django 5.2.6 on 2025-12-29 05:20
import at_django_boilerplate.accounts.models
import at_django_boilerplate.utils.custom_fields
import django.utils.timezone
import uuid
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='CustomUser',
fields=[
('password', models.CharField(max_length=128, verbose_name='password')),
('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')),
('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')),
('id', models.UUIDField(default=uuid.uuid4, editable=False, primary_key=True, serialize=False)),
('first_name', at_django_boilerplate.utils.custom_fields.EncryptedTextField()),
('last_name', at_django_boilerplate.utils.custom_fields.EncryptedTextField()),
('email', at_django_boilerplate.utils.custom_fields.EncryptedSearchableTextField()),
('dob', models.DateField(blank=True, null=True, verbose_name='Date Of Birth')),
('contact_number', at_django_boilerplate.utils.custom_fields.EncryptedSearchableTextField(blank=True, null=True)),
('profile_photo', models.ImageField(blank=True, default='assets/default_profile.png', null=True, upload_to=at_django_boilerplate.accounts.models.user_directory_path)),
('is_staff', models.BooleanField(default=False)),
('is_active', models.BooleanField(default=True)),
('date_joined', models.DateTimeField(default=django.utils.timezone.now)),
('terms_accepted', models.BooleanField(default=False, verbose_name='Terms & Conditions')),
('terms_accepted_time', models.DateTimeField(default=django.utils.timezone.now)),
('source', models.CharField(default='manual', max_length=10)),
('last_active', models.DateTimeField(blank=True, null=True)),
('is_technician', models.BooleanField(default=False)),
('is_manager', models.BooleanField(default=False)),
('email_hash', models.CharField(blank=True, editable=False, max_length=64, null=True)),
('contact_number_hash', models.CharField(blank=True, editable=False, max_length=64, null=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,
},
),
]

View File

@@ -0,0 +1,19 @@
# Generated by Django 5.2.6 on 2025-12-30 09:23
import at_django_boilerplate.utils.custom_fields
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('accounts', '0001_initial'),
]
operations = [
migrations.AlterField(
model_name='customuser',
name='email',
field=at_django_boilerplate.utils.custom_fields.EncryptedSearchableTextField(blank=True, null=True),
),
]