2025-06-01 10:05:16 +00:00

15 lines
528 B
Python

from sqlalchemy import Boolean, Column, Integer, String
from app.models.base import Base
class User(Base):
"""
User model for authentication and authorization.
"""
id = Column(Integer, primary_key=True, index=True)
email = Column(String, unique=True, index=True, nullable=False)
full_name = Column(String, nullable=True)
hashed_password = Column(String, nullable=False)
is_active = Column(Boolean, default=True, nullable=False)
is_superuser = Column(Boolean, default=False, nullable=False)