Add Glory model
This commit is contained in:
parent
a5fdedce46
commit
a92196324d
@ -9,7 +9,7 @@ class Glory(Base):
|
||||
__tablename__ = "glory"
|
||||
|
||||
id = Column(String, primary_key=True, default=lambda: str(uuid.uuid4()))
|
||||
team_name = Column(String, nullable=False, index=True)
|
||||
team_name = Column(String, unique=True, nullable=False, index=True)
|
||||
league = Column(String, nullable=False)
|
||||
points = Column(Integer, default=0)
|
||||
matches_played = Column(Integer, default=0)
|
||||
@ -22,7 +22,6 @@ class Glory(Base):
|
||||
position = Column(Integer)
|
||||
is_active = Column(Boolean, default=True)
|
||||
season = Column(String, nullable=False)
|
||||
coach = Column(String)
|
||||
home_stadium = Column(String)
|
||||
|
||||
created_at = Column(DateTime, default=func.now())
|
||||
updated_at = Column(DateTime, default=func.now(), onupdate=func.now())
|
Loading…
x
Reference in New Issue
Block a user