Browse Source
feat: implement custom user admin interface and update field constraints for bookmark, video, and user models
master
feat: implement custom user admin interface and update field constraints for bookmark, video, and user models
master
5 changed files with 117 additions and 8 deletions
-
42apps/account/admin/user.py
-
23apps/account/migrations/0002_alter_user_email_alter_user_username.py
-
23apps/account/models/user.py
-
18apps/bookmark/migrations/0002_alter_rate_service.py
-
19apps/video/migrations/0002_alter_video_video_file.py
@ -0,0 +1,23 @@ |
|||
# Generated by Django 5.2.12 on 2026-04-11 11:10 |
|||
|
|||
from django.db import migrations, models |
|||
|
|||
|
|||
class Migration(migrations.Migration): |
|||
|
|||
dependencies = [ |
|||
('account', '0001_initial'), |
|||
] |
|||
|
|||
operations = [ |
|||
migrations.AlterField( |
|||
model_name='user', |
|||
name='email', |
|||
field=models.EmailField(blank=True, error_messages={'unique': 'A user with that email already exists.'}, help_text="Enter the user's email address.", max_length=254, null=True, unique=True, verbose_name='Email Address'), |
|||
), |
|||
migrations.AlterField( |
|||
model_name='user', |
|||
name='username', |
|||
field=models.CharField(blank=True, error_messages={'unique': 'A user with that username already exists.'}, max_length=150, null=True, unique=True, verbose_name='Username'), |
|||
), |
|||
] |
|||
@ -0,0 +1,18 @@ |
|||
# Generated by Django 5.2.12 on 2026-04-11 11:10 |
|||
|
|||
from django.db import migrations, models |
|||
|
|||
|
|||
class Migration(migrations.Migration): |
|||
|
|||
dependencies = [ |
|||
('bookmark', '0001_initial'), |
|||
] |
|||
|
|||
operations = [ |
|||
migrations.AlterField( |
|||
model_name='rate', |
|||
name='service', |
|||
field=models.CharField(choices=[('library', 'Library'), ('podcast', 'Podcast'), ('podcast_playlist', 'Podcast Playlist'), ('hadith', 'Hadith'), ('hadith_correction', 'Hadith Correction'), ('video', 'Video'), ('video_playlist', 'Video Playlist'), ('article', 'Article')], max_length=20, verbose_name='Service'), |
|||
), |
|||
] |
|||
@ -0,0 +1,19 @@ |
|||
# Generated by Django 5.2.12 on 2026-04-11 11:10 |
|||
|
|||
import django.core.validators |
|||
from django.db import migrations, models |
|||
|
|||
|
|||
class Migration(migrations.Migration): |
|||
|
|||
dependencies = [ |
|||
('video', '0001_initial'), |
|||
] |
|||
|
|||
operations = [ |
|||
migrations.AlterField( |
|||
model_name='video', |
|||
name='video_file', |
|||
field=models.FileField(blank=True, null=True, upload_to='video/videos/', validators=[django.core.validators.FileExtensionValidator(allowed_extensions=['mp4', 'mov', 'avi', 'mkv', 'webm'])]), |
|||
), |
|||
] |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue