2023-08-02 10:18:36 +08:00
|
|
|
from sqlalchemy.orm import relationship
|
2023-08-02 14:24:28 +08:00
|
|
|
from context.common import common_db
|
2023-08-02 10:18:36 +08:00
|
|
|
from sqlalchemy import Column, Integer, String, ForeignKey, Text, DateTime, func, Date, Double
|
|
|
|
|
|
|
|
|
|
|
|
class CompanySubmit(common_db.Base):
|
|
|
|
"""
|
|
|
|
公司提交数据表
|
|
|
|
"""
|
|
|
|
__tablename__ = "company_submit"
|
|
|
|
|
|
|
|
id = Column(Integer, primary_key=True, comment="id")
|
|
|
|
company_name = Column(String(255), comment="公司名称")
|
|
|
|
file_md = Column(String(255), comment="文件路径")
|
|
|
|
create_time = Column(DateTime, comment="创建时间", server_default=func.now())
|
|
|
|
|
|
|
|
def to_dict(self):
|
|
|
|
data = {c.name: getattr(self, c.name) for c in self.__table__.columns}
|
|
|
|
return data
|