From 7a96a61b0239b59dcffc0bd9ab6666f9fdc7a1e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com> Date: Wed, 5 May 2010 15:46:22 +0000 Subject: [PATCH] Be more robust on broken multi item fields in ods style (similar to http://svn.erp5.org/?view=revision&revision=34129 ) git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35014 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../portal_skins/erp5_ods_style/field_ods_macro.xml | 2 +- bt5/erp5_ods_style/bt/revision | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bt5/erp5_ods_style/SkinTemplateItem/portal_skins/erp5_ods_style/field_ods_macro.xml b/bt5/erp5_ods_style/SkinTemplateItem/portal_skins/erp5_ods_style/field_ods_macro.xml index f261659250..ad3d74e6bf 100644 --- a/bt5/erp5_ods_style/SkinTemplateItem/portal_skins/erp5_ods_style/field_ods_macro.xml +++ b/bt5/erp5_ods_style/SkinTemplateItem/portal_skins/erp5_ods_style/field_ods_macro.xml @@ -109,7 +109,7 @@ <tal:block tal:condition="python: same_type(value, []) or same_type(value, ())">\n <tal:block tal:repeat="item value">\n <text:p tal:condition="not:item_list" tal:content="item"></text:p>\n - <text:p tal:condition="item_list" tal:content="python: [i[0] for i in item_list if i[1] == item][0]"></text:p>\n + <text:p tal:condition="item_list" tal:on-error="item" tal:content="python: [i[0] for i in item_list if i[1] == item][0]"></text:p>\n </tal:block>\n </tal:block>\n <tal:block tal:condition="python: (not (same_type(value, []) or same_type(value, ()))) and value is not None">\n diff --git a/bt5/erp5_ods_style/bt/revision b/bt5/erp5_ods_style/bt/revision index f937f7e2b3..df689d8406 100644 --- a/bt5/erp5_ods_style/bt/revision +++ b/bt5/erp5_ods_style/bt/revision @@ -1 +1 @@ -233 \ No newline at end of file +234 \ No newline at end of file -- 2.30.9