From 6aefb5811418b7d7afd60213a8a4b0441acdbff0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com> Date: Tue, 27 Mar 2007 15:27:01 +0000 Subject: [PATCH] repair Predicate_getMembershipCriterionCategoryList for destination_region and add support for source_region as well. git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13723 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../Predicate_getMembershipCriterionCategoryList.xml | 9 +++++---- product/ERP5/bootstrap/erp5_core/bt/revision | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Predicate_getMembershipCriterionCategoryList.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Predicate_getMembershipCriterionCategoryList.xml index 17163736ff..62ee639d7e 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Predicate_getMembershipCriterionCategoryList.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Predicate_getMembershipCriterionCategoryList.xml @@ -78,11 +78,11 @@ for item in multimembership_base_list :\n \n category_list = []\n \n -\n for item in mixed_list:\n - if item==\'destination_region\':\n - item = \'region\' # This must be made more generic\n - category_list += [\'destination_region/\' + x for x in context.portal_categories[item].getCategoryChildCompactLogicalPathItemList(base=1)]\n + if item in (\'destination_region\', \'source_region\'):\n + category = \'region\' # This must be made more generic\n + category_list += [(x[0], \'%s/%s\' % (item, x[1])) for x in \n + context.portal_categories[category].getCategoryChildCompactLogicalPathItemList(base=1)]\n else:\n category_list += context.portal_categories[item].getCategoryChildCompactLogicalPathItemList(base=1)\n \n @@ -137,6 +137,7 @@ return category_list\n <string>_getiter_</string> <string>item</string> <string>category_list</string> + <string>category</string> <string>append</string> <string>$append0</string> <string>_getitem_</string> diff --git a/product/ERP5/bootstrap/erp5_core/bt/revision b/product/ERP5/bootstrap/erp5_core/bt/revision index fefb598af8..9e6181a6ed 100644 --- a/product/ERP5/bootstrap/erp5_core/bt/revision +++ b/product/ERP5/bootstrap/erp5_core/bt/revision @@ -1 +1 @@ -284 \ No newline at end of file +285 \ No newline at end of file -- 2.30.9