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 55e9ca6b57f4ff0eed8676cd68e41ca8362a1f32..0c5ca81982a16157e00da4ffa576db6548db504e 100644 --- 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 @@ -54,8 +54,7 @@ ><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 -</tal:block> + listbox python:form[\'listbox\'];" ><tal:block tal:content="python: listbox.Listbox_exportCsv(export_only=request.get(\'export_only\', 1))" /></tal:block></tal:block></tal:block> ]]></string> </value> </item> 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 c1981a3e4a99862c4f3ef20d0345bfc99a6ca29e..374a63e0534f82c957d39b8075f9e860b9d29416 100644 --- 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 @@ -62,7 +62,7 @@ ><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 + listbox python:form[\'listbox\'];" ><tal:block tal:content="python: listbox.Listbox_exportCsv(export_only=request.get(\'export_only\', 1))" /></tal:block></tal:block>\n </tal:block> ]]></string> </value> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFile.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFile.xml index a9d536864c18b814ce7c444c6349ac209e1a6846..28b85d43b6859f598991688aff5b513fced93ef2 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFile.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFile.xml @@ -68,7 +68,12 @@ <key> <string>_body</string> </key> <value> <string>request = context.REQUEST\n \n -redirect_url = \'%s?%s\' % ( context.absolute_url()+\'/\'+form_id, \'portal_skin=CSV\')\n +from ZTUtils import make_query\n +kw = { \'portal_skin\' : \'CSV\',\n + \'export_only\' : export_only }\n +\n +redirect_url = \'%s?%s\' % ( context.absolute_url()+\'/\'+form_id, \n + make_query(kw) )\n \n return request[ \'RESPONSE\' ].redirect( redirect_url )\n </string> </value> @@ -85,7 +90,7 @@ return request[ \'RESPONSE\' ].redirect( redirect_url )\n </item> <item> <key> <string>_params</string> </key> - <value> <string>form_id=\'\'</string> </value> + <value> <string>form_id=\'\', export_only=1</string> </value> </item> <item> <key> <string>errors</string> </key> @@ -105,16 +110,20 @@ return request[ \'RESPONSE\' ].redirect( redirect_url )\n <dictionary> <item> <key> <string>co_argcount</string> </key> - <value> <int>1</int> </value> + <value> <int>2</int> </value> </item> <item> <key> <string>co_varnames</string> </key> <value> <tuple> <string>form_id</string> + <string>export_only</string> <string>_getattr_</string> <string>context</string> <string>request</string> + <string>ZTUtils</string> + <string>make_query</string> + <string>kw</string> <string>redirect_url</string> <string>_getitem_</string> </tuple> @@ -130,6 +139,7 @@ return request[ \'RESPONSE\' ].redirect( redirect_url )\n <value> <tuple> <string></string> + <int>1</int> </tuple> </value> </item> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm.xml index 1460974c8879b4bcca343267ac32a4b72be550a1..672abed640946c009d8a94608a1be6a894776526 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm.xml @@ -73,7 +73,9 @@ <item> <key> <string>Default</string> </key> <value> - <list/> + <list> + <string>your_export_only</string> + </list> </value> </item> <item> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm/your_export_only.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm/your_export_only.xml new file mode 100644 index 0000000000000000000000000000000000000000..736fe5ce1d726c624c58f0a5eae77899f8a67f1e --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_exportCsvFileForm/your_export_only.xml @@ -0,0 +1,285 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <tuple> + <string>Products.Formulator.StandardFields</string> + <string>IntegerField</string> + </tuple> + <none/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>_owner</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>your_export_only</string> </value> + </item> + <item> + <key> <string>message_values</string> </key> + <value> + <dictionary> + <item> + <key> <string>external_validator_failed</string> </key> + <value> <string>The input failed the external validator.</string> </value> + </item> + <item> + <key> <string>integer_out_of_range</string> </key> + <value> <string>The integer you entered was out of range.</string> </value> + </item> + <item> + <key> <string>not_integer</string> </key> + <value> <string>You did not enter an integer.</string> </value> + </item> + <item> + <key> <string>required_not_found</string> </key> + <value> <string>Input is required but no input given.</string> </value> + </item> + </dictionary> + </value> + </item> + <item> + <key> <string>overrides</string> </key> + <value> + <dictionary> + <item> + <key> <string>alternate_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>css_class</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>default</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>display_maxwidth</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>display_width</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>editable</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>enabled</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>end</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>external_validator</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>extra</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>required</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>start</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>whitespace_preserve</string> </key> + <value> <string></string> </value> + </item> + </dictionary> + </value> + </item> + <item> + <key> <string>tales</string> </key> + <value> + <dictionary> + <item> + <key> <string>alternate_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>css_class</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>default</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>display_maxwidth</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>display_width</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>editable</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>enabled</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>end</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>external_validator</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>extra</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>required</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>start</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent> + </value> + </item> + <item> + <key> <string>whitespace_preserve</string> </key> + <value> <string></string> </value> + </item> + </dictionary> + </value> + </item> + <item> + <key> <string>values</string> </key> + <value> + <dictionary> + <item> + <key> <string>alternate_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>css_class</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>default</string> </key> + <value> <string>0</string> </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>display_maxwidth</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>display_width</string> </key> + <value> <int>20</int> </value> + </item> + <item> + <key> <string>editable</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>enabled</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>end</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>external_validator</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>extra</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>required</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>start</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string>your_export_only</string> </value> + </item> + <item> + <key> <string>whitespace_preserve</string> </key> + <value> <int>0</int> </value> + </item> + </dictionary> + </value> + </item> + </dictionary> + </pickle> + </record> + <record id="2" aka="AAAAAAAAAAI="> + <pickle> + <tuple> + <tuple> + <string>Products.Formulator.TALESField</string> + <string>TALESMethod</string> + </tuple> + <none/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>_text</string> </key> + <value> <string>string:</string> </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_importCsvLine.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_importCsvLine.xml index fcbeab3b8083df3bb2ba3d5ab14e20e9c484841f..e5d4b167e0c8ba9f90f1a102f6fba72f7be39efb 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_importCsvLine.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_importCsvLine.xml @@ -71,11 +71,10 @@ if object == None:\n object = context.newContent()\n \n - # activity doesn t support security rights yet...\n - for key in [\'uid\',\'id\']:\n - if object_property_dict.has_key(key):\n - object_property_dict.pop(key)\n -\n +# activity doesn\'t support security rights yet...\n +for key in [\'uid\',\'id\']:\n + if object_property_dict.has_key(key):\n + object_property_dict.pop(key)\n \n object.edit(**object_property_dict)\n </string> </value>