Commit 9f1ce640 authored by Jean-Paul Smets's avatar Jean-Paul Smets

Added explicit  searchable_property_list. Removed 'Content-Disposition'...

Added explicit  searchable_property_list. Removed 'Content-Disposition' because this is the task of UI scripts.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@14399 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 09b9effe
......@@ -69,6 +69,10 @@ class PDFDocument(Image, ConversionCacheMixin):
, PropertySheet.Periodicity
)
searchable_property_list = ('asText', 'title', 'description', 'id', 'reference',
'version', 'short_title',
'subject', 'source_reference', 'source_project_title',)
security.declareProtected(Permissions.View, 'index_html')
def index_html(self, REQUEST, RESPONSE, display=None, format='', quality=75, resolution=None):
"""
......@@ -76,9 +80,6 @@ class PDFDocument(Image, ConversionCacheMixin):
it is always a zip because multi-page pdfs are converted into a zip
file of many images
"""
if self.getSourceReference() is not None:
RESPONSE.setHeader('Content-Disposition',
'attachment; filename=%s' %self.getSourceReference())
if format is None:
RESPONSE.setHeader('Content-Type', 'application/pdf')
return _unpackData(self.data)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment