From d10a99c9e0eda8714e28b7cc0b491e2730654398 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com>
Date: Tue, 14 Mar 2006 13:20:42 +0000
Subject: [PATCH] Don't display empty lines at start, it is incompatible with
 many spreadsheets applications

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@6091 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../portal_skins/erp5_csv_style/form_list.xml          |  9 ++++-----
 .../portal_skins/erp5_csv_style/form_view.xml          | 10 ++++------
 bt5/erp5_csv_style/bt/change_log                       |  3 +++
 bt5/erp5_csv_style/bt/copyright_list                   |  1 +
 bt5/erp5_csv_style/bt/description                      |  2 +-
 bt5/erp5_csv_style/bt/license                          |  1 +
 6 files changed, 14 insertions(+), 12 deletions(-)

diff --git a/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_list.xml b/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_list.xml
index 527d18131b..55e9ca6b57 100755
--- a/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_list.xml
+++ b/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_list.xml
@@ -48,11 +48,10 @@
             <key> <string>_text</string> </key>
             <value> <string encoding="cdata"><![CDATA[
 
-<tal:block tal:define=\'amp python:"\\""\'> \n
-<tal:block tal:define="dummy python:request.RESPONSE.setHeader(\'Content-Type\', \'text/x-comma-separated-values;; charset=utf-8\');\n
-                       dummy2 python: request.RESPONSE.setHeader(\'Content-disposition\',\'attachment;; filename=%s%s.csv%s\' % (amp,form.title_or_id(),amp) ); ">\n
-\n
-<tal:block tal:define="groups python: form.get_groups(include_empty=1);\n
+<tal:block tal:define=\'amp python:"\\""\'\n
+><tal:block tal:define="dummy python:request.RESPONSE.setHeader(\'Content-Type\', \'text/x-comma-separated-values;; charset=utf-8\');\n
+                       dummy2 python: request.RESPONSE.setHeader(\'Content-disposition\',\'attachment;; filename=%s%s.csv%s\' % (amp,form.title_or_id(),amp) ); "\n
+><tal:block tal:define="groups python: form.get_groups(include_empty=1);\n
                  field_errors python: request.get(\'field_errors\',{});\n
                  dummy python: request.set(\'here\',here);\n
                  listbox python:form[\'listbox\'];" ><tal:block tal:content="python: listbox.Listbox_exportCsv()" /></tal:block></tal:block>\n
diff --git a/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_view.xml b/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_view.xml
index e3b75be6d1..c1981a3e4a 100755
--- a/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_view.xml
+++ b/bt5/erp5_csv_style/SkinTemplateItem/portal_skins/erp5_csv_style/form_view.xml
@@ -56,12 +56,10 @@
 
 <tal:block tal:replace="nothing" >\n
   form_view is a quick hack to display only the listbox called "listbox"\n
-</tal:block>\n
-<tal:block tal:define=\'amp python:"\\""\'> \n
-<tal:block tal:define="dummy python:request.RESPONSE.setHeader(\'Content-Type\', \'text/x-comma-separated-values;; charset=utf-8\');\n
-                       dummy2 python: request.RESPONSE.setHeader(\'Content-disposition\',\'attachment;; filename=%s%s.csv%s\' % (amp,form.title_or_id(),amp) ); ">\n
-\n
-<tal:block tal:define="groups python: form.get_groups(include_empty=1);\n
+</tal:block><tal:block tal:define=\'amp python:"\\""\'\n
+><tal:block tal:define="dummy python:request.RESPONSE.setHeader(\'Content-Type\', \'text/x-comma-separated-values;; charset=utf-8\');\n
+                       dummy2 python: request.RESPONSE.setHeader(\'Content-disposition\',\'attachment;; filename=%s%s.csv%s\' % (amp,form.title_or_id(),amp) ); "\n
+><tal:block tal:define="groups python: form.get_groups(include_empty=1);\n
                  field_errors python: request.get(\'field_errors\',{});\n
                  dummy python: request.set(\'here\',here);\n
                  listbox python:form[\'listbox\'];" ><tal:block tal:content="python: listbox.Listbox_exportCsv()" /></tal:block></tal:block>\n
diff --git a/bt5/erp5_csv_style/bt/change_log b/bt5/erp5_csv_style/bt/change_log
index c10b0a9f26..fbc1ba1a76 100755
--- a/bt5/erp5_csv_style/bt/change_log
+++ b/bt5/erp5_csv_style/bt/change_log
@@ -1,2 +1,5 @@
+2006-03-14 jerome
+* Don't display empty lines
+
 2006-02-24 Seb
 * Created this business template in order to split erp5_core
\ No newline at end of file
diff --git a/bt5/erp5_csv_style/bt/copyright_list b/bt5/erp5_csv_style/bt/copyright_list
index e69de29bb2..22de975f93 100755
--- a/bt5/erp5_csv_style/bt/copyright_list
+++ b/bt5/erp5_csv_style/bt/copyright_list
@@ -0,0 +1 @@
+Copyright (c) 2001-2006 Nexedi SARL
\ No newline at end of file
diff --git a/bt5/erp5_csv_style/bt/description b/bt5/erp5_csv_style/bt/description
index 9585176379..75244656df 100755
--- a/bt5/erp5_csv_style/bt/description
+++ b/bt5/erp5_csv_style/bt/description
@@ -1 +1 @@
-The ERP5 Html style used in order to export data into OpenOffice.org
\ No newline at end of file
+The ERP5 CSV style is used in order to export data into OpenOffice.org
\ No newline at end of file
diff --git a/bt5/erp5_csv_style/bt/license b/bt5/erp5_csv_style/bt/license
index e69de29bb2..3a3e12bcad 100755
--- a/bt5/erp5_csv_style/bt/license
+++ b/bt5/erp5_csv_style/bt/license
@@ -0,0 +1 @@
+GPL
\ No newline at end of file
-- 
2.30.9