Add List model

This commit is contained in:
Backend IM Bot 2025-03-29 12:50:17 -05:00
parent 5d1ac634ac
commit 9c90381a89

12
models/list.py Normal file
View File

@ -0,0 +1,12 @@
from sqlalchemy import Column, String, DateTime, func
from sqlalchemy.dialects.postgresql import UUID
from core.database import Base
class List(Base):
__tablename__ = "lists"
id = Column(UUID(as_uuid=True), primary_key=True, default=uuid.uuid4)
name = Column(String, nullable=False)
description = Column(String)
created_at = Column(DateTime, default=func.now())
updated_at = Column(DateTime, default=func.now(), onupdate=func.now())