init commit
This commit is contained in:
17
.history/backend/customization/models_20250506101457.py
Normal file
17
.history/backend/customization/models_20250506101457.py
Normal file
@@ -0,0 +1,17 @@
|
||||
from django.db import models
|
||||
from django.conf import settings
|
||||
|
||||
class DesignSettings(models.Model):
|
||||
user = models.OneToOneField(
|
||||
settings.AUTH_USER_MODEL,
|
||||
on_delete=models.CASCADE,
|
||||
related_name='design'
|
||||
)
|
||||
theme_color = models.CharField(max_length=7, default='#ffffff')
|
||||
background_image = models.ImageField(upload_to='backgrounds/', null=True, blank=True)
|
||||
font_family = models.CharField(max_length=100, default='sans-serif')
|
||||
custom_css = models.TextField(blank=True)
|
||||
updated_at = models.DateTimeField(auto_now=True)
|
||||
|
||||
def __str__(self):
|
||||
return f"Design for {self.user.username}"
|
||||
Reference in New Issue
Block a user