Commit 18487d34 authored by Romain Courteaud's avatar Romain Courteaud

Sort project lines by int index.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31374 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 8a2f838b
...@@ -64,14 +64,14 @@ here = context.REQUEST[\'here\']\n ...@@ -64,14 +64,14 @@ here = context.REQUEST[\'here\']\n
\n \n
\n \n
if depth == 0:\n if depth == 0:\n
category_list = here.contentValues(portal_type=project_line_portal_type)\n category_list = here.searchFolder(portal_type=project_line_portal_type, sort_on=((\'int_index\', \'ASC\')))\n
\n \n
else:\n else:\n
category_list = []\n category_list = []\n
parent_category_list = parent.getMembershipCriterionCategoryList()\n parent_category_list = parent.getMembershipCriterionCategoryList()\n
for parent_category in parent_category_list:\n for parent_category in parent_category_list:\n
parent_category = \'/\'.join(parent_category.split(\'/\')[1:])\n parent_category = \'/\'.join(parent_category.split(\'/\')[1:])\n
category_list.extend(context.restrictedTraverse(parent_category).contentValues(portal_type=project_line_portal_type))\n category_list.extend([x for x in context.restrictedTraverse(parent_category).searchFolder(portal_type=project_line_portal_type, sort_on=((\'int_index\', \'ASC\')))])\n
\n \n
i = 0\n i = 0\n
for category in category_list:\n for category in category_list:\n
...@@ -136,6 +136,9 @@ return domain_list\n ...@@ -136,6 +136,9 @@ return domain_list\n
<string>parent_category_list</string> <string>parent_category_list</string>
<string>_getiter_</string> <string>_getiter_</string>
<string>parent_category</string> <string>parent_category</string>
<string>append</string>
<string>$append0</string>
<string>x</string>
<string>i</string> <string>i</string>
<string>category</string> <string>category</string>
<string>domain</string> <string>domain</string>
......
721 722
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment