17 lines
471 B
Python
17 lines
471 B
Python
from django.contrib.auth import get_user_model
|
|
from django.db import models
|
|
|
|
|
|
from app.utils.models import BaseModel
|
|
|
|
|
|
User = get_user_model()
|
|
|
|
|
|
class UserSettings(BaseModel):
|
|
user = models.OneToOneField(User, on_delete=models.PROTECT, related_name="setting")
|
|
|
|
# The private and public key are wrapped with the AES key from the front-end
|
|
public_key = models.TextField(max_length=2048, null=True)
|
|
private_key = models.TextField(max_length=2048, null=True)
|