[Erp5-report] r14108 - /erp5/trunk/products/ERP5OOo/Document/OOoDocument.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Wed Apr 18 10:24:03 CEST 2007
Author: ivan
Date: Wed Apr 18 10:23:58 2007
New Revision: 14108
URL: http://svn.erp5.org?rev=14108&view=rev
Log:
Try to return the original filename.
Modified:
erp5/trunk/products/ERP5OOo/Document/OOoDocument.py
Modified: erp5/trunk/products/ERP5OOo/Document/OOoDocument.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5OOo/Document/OOoDocument.py?rev=14108&r1=14107&r2=14108&view=diff
==============================================================================
--- erp5/trunk/products/ERP5OOo/Document/OOoDocument.py (original)
+++ erp5/trunk/products/ERP5OOo/Document/OOoDocument.py Wed Apr 18 10:23:58 2007
@@ -142,6 +142,9 @@
_setCacheHeaders(self, {'format' : format})
# Return the original file by default
if format is None:
+ if self.getSourceReference() is not None:
+ RESPONSE.setHeader('Content-Disposition',
+ 'attachment; filename=%s' %self.getSourceReference())
return File.index_html(self, REQUEST, RESPONSE)
# Make sure file is converted to base format
if not self.hasBaseData():
@@ -378,7 +381,7 @@
return self._base_metadata
security.declareProtected(Permissions.ModifyPortalContent, 'updateBaseMetadata')
- def updateBaseMetadata(self, **kw):
+ def updateBaseMetadata(self, *arg, **kw):
"""
Updates metadata information in the converted OOo document
based on the values provided by the user. This is implemented
More information about the Erp5-report
mailing list