Spaces:
Running
on
Zero
Running
on
Zero
from sqlalchemy import Column, Integer, String | |
from sqlalchemy.ext.asyncio import AsyncSession | |
from sqlalchemy.orm import relationship | |
from app.models.base import Base | |
class Team(Base): | |
__tablename__ = "teams" | |
id = Column(Integer, primary_key=True) | |
name = Column(String, unique=True) | |
created_at = Column(DateTime, default=datetime.utcnow) | |
def __repr__(self): | |
return f"Team(name={self.name}, created_at={self.created_at})" |