就业模块修改
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from sqlalchemy import Column, DateTime, ForeignKey, Integer, String, func
|
||||
from sqlalchemy import Column, DateTime, ForeignKey, Integer, String
|
||||
from sqlalchemy.orm import relationship
|
||||
|
||||
from database import Base
|
||||
@@ -9,8 +9,8 @@ class Emp(Base):
|
||||
|
||||
# 学号做主键,同时做外键指向学生表,长度跟 Student.stu_no 保持一致
|
||||
stu_no = Column(String(20), ForeignKey('wl_student.stu_no'), primary_key=True)
|
||||
emp_open_time = Column(DateTime, default="2026-11-30 18:18:18")
|
||||
offer_time = Column(DateTime, default=func.now())
|
||||
emp_open_time = Column(DateTime)
|
||||
offer_time = Column(DateTime)
|
||||
company_name = Column(String(100), nullable=False)
|
||||
salary = Column(Integer, nullable=False, default=15000)
|
||||
|
||||
@@ -21,3 +21,4 @@ class Emp(Base):
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Emp(stu_no={self.stu_no}, company='{self.company_name}')>"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user