some fixes for models
This commit is contained in:
@@ -9,11 +9,9 @@ from orm.base import Base
|
||||
class Shout(Base):
|
||||
__tablename__ = 'shout'
|
||||
|
||||
id = None
|
||||
|
||||
slug: str = Column(String, primary_key=True)
|
||||
org_id: str = Column(ForeignKey("organization.id"), nullable=False)
|
||||
author_id: str = Column(ForeignKey("user.id"), nullable=False, comment="Author")
|
||||
org_id: int = Column(Integer, ForeignKey("organization.id"), nullable=False, comment="Organization")
|
||||
author_id: int = Column(Integer, ForeignKey("user.id"), nullable = False, comment="Author")
|
||||
body: str = Column(String, nullable=False, comment="Body")
|
||||
createdAt: str = Column(DateTime, nullable=False, default = datetime.now, comment="Created at")
|
||||
updatedAt: str = Column(DateTime, nullable=True, comment="Updated at")
|
||||
|
Reference in New Issue
Block a user