changes 下载报告
This commit is contained in:
parent
de9c4b68ad
commit
2eea5a2580
|
@ -689,7 +689,7 @@ def func(schemas: ReportSchemas.SearchReportFlowReqBody, db: Session = Depends(g
|
||||||
myfile.write(result)
|
myfile.write(result)
|
||||||
task = BackgroundTask(del_file, file_path)
|
task = BackgroundTask(del_file, file_path)
|
||||||
response = FileResponse(file_path, filename=file,
|
response = FileResponse(file_path, filename=file,
|
||||||
media_type='application/vnd.openxmlformats-officedocument.wordprocessingml.document',
|
media_type='application/octet-stream',
|
||||||
background=task)
|
background=task)
|
||||||
|
|
||||||
return response
|
return response
|
||||||
|
|
Loading…
Reference in New Issue