From 3b56174371effff7ff9e0b884b6f8b3b96188cfd Mon Sep 17 00:00:00 2001 From: Romain Courteaud <romain@nexedi.com> Date: Wed, 19 Mar 2008 17:47:58 +0000 Subject: [PATCH] Display all Task/Task Reports which are not strictly related to the Project/Project Line. git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@20058 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../Base_generateValidatedProjectDomain.xml | 18 ++++++++++++++++-- .../TaskModule_viewTaskList/listbox.xml | 4 ---- .../listbox.xml | 4 ---- bt5/erp5_project/bt/revision | 2 +- 4 files changed, 17 insertions(+), 11 deletions(-) diff --git a/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/Base_generateValidatedProjectDomain.xml b/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/Base_generateValidatedProjectDomain.xml index 69ba0de387..b63bc15301 100644 --- a/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/Base_generateValidatedProjectDomain.xml +++ b/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/Base_generateValidatedProjectDomain.xml @@ -78,12 +78,22 @@ else:\n \n for category in category_list:\n domain = parent.generateTempDomain(id=\'sub%s\' % category.getId())\n + \n + membership_criterion_category = []\n + sub_category_list = [category]\n + while sub_category_list:\n + sub_category = sub_category_list.pop()\n + membership_criterion_category.append(\'source_project/%s\' % sub_category.getRelativeUrl())\n + sub_category_list.extend(sub_category.contentValues(portal_type=\'Project Line\'))\n +\n domain.edit(title = category.getTitle(),\n - membership_criterion_base_category = (\'source_project\', ), \n - membership_criterion_category = (\'source_project/%s\' % category.getRelativeUrl(),),\n + membership_criterion_base_category = (\'source_project\', ),\n + membership_criterion_category = membership_criterion_category,\n domain_generator_method_id = script.id,\n parent_url=category.getRelativeUrl(),\n uid = category.getUid())\n +\n + context.log(str(membership_criterion_category))\n \n domain_list.append(domain)\n \n @@ -151,7 +161,11 @@ return domain_list\n <string>parent_object</string> <string>category</string> <string>domain</string> + <string>membership_criterion_category</string> + <string>sub_category_list</string> + <string>sub_category</string> <string>script</string> + <string>str</string> </tuple> </value> </item> diff --git a/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskModule_viewTaskList/listbox.xml b/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskModule_viewTaskList/listbox.xml index db7486cf5c..64b9e48833 100644 --- a/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskModule_viewTaskList/listbox.xml +++ b/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskModule_viewTaskList/listbox.xml @@ -254,10 +254,6 @@ <string>region</string> <string>Region</string> </tuple> - <tuple> - <string>validated_project_domain</string> - <string>Open Project</string> - </tuple> </list> </value> </item> diff --git a/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskReportModule_viewTaskReportList/listbox.xml b/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskReportModule_viewTaskReportList/listbox.xml index 8b48849202..f52f893a6f 100644 --- a/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskReportModule_viewTaskReportList/listbox.xml +++ b/bt5/erp5_project/SkinTemplateItem/portal_skins/erp5_project/TaskReportModule_viewTaskReportList/listbox.xml @@ -250,10 +250,6 @@ <string>region</string> <string>region</string> </tuple> - <tuple> - <string>validated_project_domain</string> - <string>Open Project</string> - </tuple> </list> </value> </item> diff --git a/bt5/erp5_project/bt/revision b/bt5/erp5_project/bt/revision index 8b120bce8f..2415c06594 100644 --- a/bt5/erp5_project/bt/revision +++ b/bt5/erp5_project/bt/revision @@ -1 +1 @@ -447 \ No newline at end of file +448 \ No newline at end of file -- 2.30.9