add created_at to user model

This commit is contained in:
Timur
2025-03-02 12:51:27 +03:00
parent 70728250c9
commit a4aba80e34
4 changed files with 23 additions and 1 deletions
+2
View File
@@ -14,6 +14,8 @@ class User(BaseModel):
username = models.SlugField(unique=True, verbose_name="юзернейм")
password = models.TextField(verbose_name="пароль")
created_at = models.DateTimeField(auto_now=True)
@staticmethod
def make_password(password: str):
return make_password(password)