From d32c2c22deac670ae1c0486e6efdb210491145a4 Mon Sep 17 00:00:00 2001 From: wuaho Date: Wed, 28 Jul 2021 17:13:21 +0800 Subject: [PATCH] 1 --- api/api_v1/endpoints/report.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/api_v1/endpoints/report.py b/api/api_v1/endpoints/report.py index bf7a912..80c74de 100644 --- a/api/api_v1/endpoints/report.py +++ b/api/api_v1/endpoints/report.py @@ -85,7 +85,7 @@ async def delete( ) -> schemas.Msg: """删除报表""" # 删除Report 自己创建的 - del_report = await crud.report.delete(db, _id=data_in.id, user_id=current_user.id) + del_report = await crud.report.delete(db, {'_id': data_in.id, 'user_id': current_user.id}) if del_report.deleted_count == 0: return schemas.Msg(code=-1, msg='error', data='删除失败')