from sqlalchemy import create_engine, Column, BigInteger, String, Text, DateTime, CHAR,Integer,Float from database import Base from datetime import datetime class ThreeProofingResponsiblePerson(Base): __tablename__ = 'three_proofing_responsible_person' id = Column(Integer, primary_key=True, autoincrement=True) unit_id = Column(Integer, comment='单位ID') unit_name = Column(String(255), nullable=False, comment='单位名称') name = Column(String(255), nullable=False, comment='联系人') area_code = Column(String(255), nullable=False, comment='区划编码') position = Column(String(255), nullable=True, comment='职务') phone = Column(String(50), nullable=True, comment='手机号码') order_num = Column(Integer, default=100, comment='排序顺序') create_time = Column(DateTime, default=datetime.now, comment='数据创建时间') update_time = Column(DateTime, default=datetime.now, onupdate=datetime.now, comment='数据更新时间') create_dept = Column(BigInteger, default=None, comment='创建部门') create_by = Column(BigInteger, default=None, comment='创建者') update_by = Column(BigInteger, default=None, comment='更新者') del_flag = Column(String(1), default='0', comment='删除标志(0代表存在 2代表删除)') class ThreeProofingResponsibleType(Base): __tablename__ = 'three_proofing_responsible_type' id = Column(Integer, primary_key=True, autoincrement=True) type_parent_id = Column(String(255), comment='责任类型id') type_name = Column(String(255), nullable=False, comment='责任类别') order_num = Column(Integer, default=100, comment='排序顺序') create_time = Column(DateTime, default=datetime.now, comment='数据创建时间') update_time = Column(DateTime, default=datetime.now, onupdate=datetime.now, comment='数据更新时间') create_dept = Column(BigInteger, default=None, comment='创建部门') create_by = Column(BigInteger, default=None, comment='创建者') update_by = Column(BigInteger, default=None, comment='更新者') del_flag = Column(String(1), default='0', comment='删除标志(0代表存在 2代表删除)') class ThreeProofingResponsiblePersonType(Base): __tablename__ = 'three_proofing_responsible_person_type' id = Column(Integer, primary_key=True, autoincrement=True) type_id = Column(String(255), comment='责任类别id') type_parent_id = Column(String(255), nullable=False, comment='责任类型id') person_id = Column(Integer, nullable=False, comment='责任人id') create_time = Column(DateTime, default=datetime.now, comment='数据创建时间') update_time = Column(DateTime, default=datetime.now, onupdate=datetime.now, comment='数据更新时间') create_dept = Column(BigInteger, default=None, comment='创建部门') create_by = Column(BigInteger, default=None, comment='创建者') update_by = Column(BigInteger, default=None, comment='更新者') del_flag = Column(String(1), default='0', comment='删除标志(0代表存在 2代表删除)')