2021-06-28 09:08:09 +00:00
|
|
|
from typing import List
|
|
|
|
from datetime import datetime
|
|
|
|
from sqlalchemy import Column, Integer, String, ForeignKey, Datetime
|
|
|
|
|
|
|
|
from orm import Permission
|
|
|
|
from orm.base import Base
|
|
|
|
|
|
|
|
|
|
|
|
class Proposal(Base):
|
|
|
|
__tablename__ = 'proposal'
|
|
|
|
|
2021-08-19 15:33:39 +00:00
|
|
|
author_id: int = Column(Integer, ForeignKey("user.id"), nullable=False, comment="Author")
|
2021-08-25 21:20:53 +00:00
|
|
|
shout_id: int = Column(Integer, ForeignKey("shout.id"), nullable=False, comment="Shout")
|
2021-06-28 09:08:09 +00:00
|
|
|
body: str = Column(String, nullable=False, comment="Body")
|
|
|
|
createdAt: str = Column(datetime, nullable=False, comment="Created at")
|
|
|
|
range: str = Column(String, nullable=True, comment="Range in format <start index>:<end>")
|
|
|
|
|
|
|
|
# TODO: debug, logix
|