上传文件至「model」

This commit is contained in:
2026-09-22 21:36:21 +08:00
parent 05def16ec4
commit 01c289c102
5 changed files with 146 additions and 0 deletions
+40
View File
@@ -0,0 +1,40 @@
from sqlalchemy import *
from datetime import datetime
from database import *
class Scores(Base):
__tablename__ = 's_scores'
id=Column( Integer
, primary_key=True
,autoincrement=True
,comment='成绩编号'
)
stu_id=Column(String(50)
, ForeignKey('s_student.stu_id')
,comment='学生编号'
, nullable=False
)
exam_seq=Column(Integer
, nullable=True
,comment='考试序次'
)
score=Column(Float
,comment='分数'
)
create_date=Column(DATETIME
, default=datetime.now
,comment='创建时间'
)
update_date=Column(DATETIME
, default=datetime.now
,onupdate=datetime.now
,comment='更新时间'
)
deleted=Column(Integer
,default=1
, comment='软删除'
)