Download working well with content-dispoition and filename.
This commit is contained in:
parent
e4f5ae123a
commit
e1576aba18
1 changed files with 1 additions and 0 deletions
|
|
@ -60,5 +60,6 @@ class DocumentCustomerPortal(CustomerPortal):
|
|||
headers = [
|
||||
('content-type', attachment.mimetype),
|
||||
('content-length', attachment.file_size),
|
||||
('content-disposition', f'attachment; filename="{document.name}"')
|
||||
]
|
||||
return request.make_response(attachment.raw, headers)
|
||||
|
|
|
|||
Loading…
Reference in a new issue