diff --git a/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_renderReportSection.xml b/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_renderReportSection.xml index 2d60d71e18c14cc320d8df405039f91ad2a387d2..9f4586f3e469eb275f3c158a86e8e863badb8570 100644 --- a/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_renderReportSection.xml +++ b/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_renderReportSection.xml @@ -76,7 +76,7 @@ if report_section.getFormId():\n form = getattr(context, report_section.getFormId())\n else:\n form = None\n -#context.log(request.text())\n +\n selection_name = request.get(\'prefixed_selection_name\')\n data = context.render_report_section.pt_render(\n extra_context=dict(form=form,\n diff --git a/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_report.xml b/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_report.xml index bf0baf5c4341811075f212d37533dd9c030078a3..6eba421aca17f4868b9082769e1ef50d746d8ab5 100644 --- a/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_report.xml +++ b/bt5/erp5_deferred_style/SkinTemplateItem/portal_skins/erp5_deferred_style_core/Base_report.xml @@ -78,15 +78,15 @@ report_data = context.restrictedTraverse(form_path).report_view.pt_render(\n report_method=dummyReportMethod,\n form=portal.restrictedTraverse(form_path)))\n \n -attachment_name = [x[len(\'filename=\'):] for x in request.RESPONSE.getHeader(\n - \'content-disposition\').split(\';\')\n - if x.startswith(\'filename=\')][0]\n +attachment_name = [x[len(\'filename=\'):] for x in (request.RESPONSE.getHeader(\n + \'content-disposition\') or \'\').split(\';\')\n + if x.startswith(\'filename=\')][0]\n if attachment_name.startswith(\'"\'):\n attachment_name = attachment_name[1:]\n if attachment_name.endswith(\'"\'):\n attachment_name = attachment_name[:-1]\n attachment_list = (\n - {\'mime_type\': request.RESPONSE.getHeader(\'content-type\').split(\';\')[0],\n + {\'mime_type\': (request.RESPONSE.getHeader(\'content-type\') or \'application/octet-stream;\').split(\';\')[0],\n \'content\': \'%s\' % report_data,\n \'name\': attachment_name},)\n \n diff --git a/bt5/erp5_deferred_style/bt/revision b/bt5/erp5_deferred_style/bt/revision index 0aeb5485442b9ed8a2d59d629933a00db4473ebf..a76c74dcec6ab8ba53c5d5b4de054eb43f68fe67 100644 --- a/bt5/erp5_deferred_style/bt/revision +++ b/bt5/erp5_deferred_style/bt/revision @@ -1 +1 @@ -74 \ No newline at end of file +75 \ No newline at end of file