-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
cefd519
commit 73344af
Showing
12 changed files
with
312 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,120 @@ | ||
# Generated by Django 5.0.1 on 2024-02-15 05:18 | ||
|
||
import django_extensions.db.fields | ||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
initial = True | ||
|
||
dependencies = [] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name="Profile", | ||
fields=[ | ||
( | ||
"id", | ||
models.BigAutoField( | ||
auto_created=True, | ||
primary_key=True, | ||
serialize=False, | ||
verbose_name="ID", | ||
), | ||
), | ||
( | ||
"slug", | ||
models.SlugField( | ||
blank=True, editable=False, unique=True, verbose_name="Slug" | ||
), | ||
), | ||
( | ||
"first_name", | ||
models.CharField( | ||
blank=True, max_length=150, null=True, verbose_name="First name" | ||
), | ||
), | ||
( | ||
"last_name", | ||
models.CharField( | ||
blank=True, max_length=150, null=True, verbose_name="Last name" | ||
), | ||
), | ||
( | ||
"full_name", | ||
models.CharField( | ||
blank=True, max_length=150, verbose_name="Full name" | ||
), | ||
), | ||
( | ||
"profile_key", | ||
django_extensions.db.fields.RandomCharField( | ||
blank=True, | ||
editable=False, | ||
length=12, | ||
unique=True, | ||
verbose_name="Profile key", | ||
), | ||
), | ||
( | ||
"country", | ||
models.CharField(blank=True, max_length=50, verbose_name="Country"), | ||
), | ||
( | ||
"city", | ||
models.CharField( | ||
blank=True, max_length=50, null=True, verbose_name="City" | ||
), | ||
), | ||
( | ||
"adress", | ||
models.CharField( | ||
blank=True, max_length=50, null=True, verbose_name="Adress" | ||
), | ||
), | ||
( | ||
"additional_information", | ||
models.TextField(blank=True, verbose_name="Additional Information"), | ||
), | ||
( | ||
"is_active", | ||
models.BooleanField(default=False, verbose_name="Is active"), | ||
), | ||
( | ||
"account_type", | ||
models.CharField( | ||
choices=[("ADMIN", "admin"), ("GENERAL", "general")], | ||
default="GENERAL", | ||
max_length=20, | ||
null=True, | ||
verbose_name="Account type", | ||
), | ||
), | ||
( | ||
"status", | ||
models.CharField( | ||
choices=[("ACTIVE", "active"), ("INACTIVE", "inactive")], | ||
default="INACTIVE", | ||
max_length=20, | ||
null=True, | ||
verbose_name="Status", | ||
), | ||
), | ||
( | ||
"gender", | ||
models.CharField( | ||
blank=True, | ||
choices=[("MALE", "male"), ("FEMALE", "female")], | ||
max_length=20, | ||
null=True, | ||
verbose_name="Gender", | ||
), | ||
), | ||
], | ||
options={ | ||
"verbose_name": "Profile", | ||
"verbose_name_plural": "Profiles", | ||
}, | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Generated by Django 5.0.1 on 2024-02-15 05:18 | ||
|
||
import django.db.models.deletion | ||
from django.conf import settings | ||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
initial = True | ||
|
||
dependencies = [ | ||
("user_profile", "0001_initial"), | ||
migrations.swappable_dependency(settings.AUTH_USER_MODEL), | ||
] | ||
|
||
operations = [ | ||
migrations.AddField( | ||
model_name="profile", | ||
name="user", | ||
field=models.OneToOneField( | ||
null=True, | ||
on_delete=django.db.models.deletion.CASCADE, | ||
to=settings.AUTH_USER_MODEL, | ||
verbose_name="User", | ||
), | ||
), | ||
] |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,106 @@ | ||
# Generated by Django 5.0.1 on 2024-02-15 05:29 | ||
|
||
import django.utils.timezone | ||
from django.db import migrations, models | ||
|
||
import config.helpers | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
initial = True | ||
|
||
dependencies = [ | ||
("auth", "0012_alter_user_first_name_max_length"), | ||
] | ||
|
||
operations = [ | ||
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")), | ||
( | ||
"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", | ||
), | ||
), | ||
( | ||
"email", | ||
models.EmailField( | ||
max_length=254, unique=True, verbose_name="Email address" | ||
), | ||
), | ||
( | ||
"wallet_address", | ||
models.CharField( | ||
blank=True, | ||
db_index=True, | ||
max_length=100, | ||
null=True, | ||
unique=True, | ||
validators=[config.helpers.is_valid_wallet_address], | ||
verbose_name="Wallet address", | ||
), | ||
), | ||
( | ||
"is_staff", | ||
models.BooleanField(default=False, verbose_name="Is staff"), | ||
), | ||
( | ||
"is_active", | ||
models.BooleanField(default=True, verbose_name="Is active"), | ||
), | ||
( | ||
"date_joined", | ||
models.DateTimeField( | ||
default=django.utils.timezone.now, verbose_name="Date joined" | ||
), | ||
), | ||
( | ||
"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={ | ||
"verbose_name": "Custom user", | ||
"verbose_name_plural": "Custom users", | ||
"ordering": ["-date_joined"], | ||
}, | ||
), | ||
] |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters