This commit is contained in:
2026-09-22 15:36:24 +08:00
parent 5a191c291e
commit b829e4063f
2 changed files with 2 additions and 3 deletions
+2
View File
@@ -27,6 +27,8 @@ def get_emp_info3(stu_id:int = Path(description='学生编号')
, company_name=company_name
, min_salary=min_salary
, max_salary=max_salary)
if not l1:
raise HTTPException(status_code=404,detail='该学生就业信息不存在!')
return l1
@emp_api.post('/employment/students/{stu_id}',response_model=EmploymentResponse,summary='新增学生就业信息')
-3
View File
@@ -31,12 +31,9 @@ def get_emp_dao(db,stu_id=None,class_id=None,company_name=None,min_salary=None,m
q = q.filter(Employment_info.salary <= max_salary)
r = q.all()
if not r:
raise HTTPException(status_code=500,detail='查询异常,没有结果!')
return r
def add_emp_dao(o,db):
try:
stu = db.query(Student_Model).filter(Student_Model.stu_id == o['stu_id']