from operator import index from sqlalchemy import Boolean, Column, ForeignKey, Integer, String from app.models.database import BaseModel class JmHomework(BaseModel): __tablename__ = 'jm_homework' id = Column(Integer, primary_key=True, index=True) # 作业名称 name = Column(String) # 作业类型 type = Column(String) # 作业分类 tag = Column(String) # 执行镜像 image_url = Column(String) # DAG_ID dag_uuid = Column(String) # DAG文件地址 dag_url = Column(String) # 脚本文件 script_file = Column(String) # 执行命令 execute_command = Column(String) # 更新时间 update_time = Column(Integer) # 创建时间 create_time = Column(Integer) # 用户ID user_id = Column(String, nullable=False) # 项目ID project_id = Column(String, nullable=False) # 状态(0:已删除,1:未删除) status = Column(Integer, nullable=False)