changes 删除bug
This commit is contained in:
parent
1aa3c63b04
commit
53006ec586
|
@ -29,6 +29,11 @@ def delete_scorecard(db: Session, mongodb: MongoHelper, _id: str):
|
|||
return True
|
||||
except IntegrityError:
|
||||
return False
|
||||
except AttributeError:
|
||||
db.query(Model.ScoreCard).filter_by(id=_id).delete()
|
||||
db.commit()
|
||||
return True
|
||||
|
||||
|
||||
|
||||
def update_scorecard(db: Session, _id: str, schema: Schema.EditScoreCardReqBody):
|
||||
|
|
Loading…
Reference in New Issue