Commit 0a9bf83d authored by Romain Courteaud's avatar Romain Courteaud

Project_viewTaskList and Project_viewTaskReportList listbox's columns are not...

Project_viewTaskList and Project_viewTaskReportList listbox's columns are not sortable (because the list method do not handle it currently).
Sort result of Project_getSourceProjectRelatedTaskList to make it consistent with Project_getSourceProjectRelatedTaskReportList.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31365 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ead43699
......@@ -81,6 +81,14 @@ task_line_list = []\n
for task in task_list:\n
task_line_list.extend(task.contentValues(portal_type=\'Task Line\'))\n
\n
def sortTaskLine(a, b):\n
result = cmp(a.getStartDate(), b.getStartDate())\n
if result == 0:\n
result = cmp(a.getTitle(), b.getTitle())\n
return result\n
\n
task_line_list.sort(sortTaskLine)\n
\n
return task_line_list\n
......@@ -142,6 +150,7 @@ return task_line_list\n
<string>task_list</string>
<string>task_line_list</string>
<string>task</string>
<string>sortTaskLine</string>
</tuple>
</value>
</item>
......
......@@ -13,16 +13,17 @@
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>title</string>
<string>columns</string>
<string>all_columns</string>
<string>columns</string>
<string>editable_columns</string>
<string>list_method</string>
<string>stat_method</string>
<string>selection_name</string>
<string>portal_types</string>
<string>editable_columns</string>
<string>report_tree</string>
<string>report_root_list</string>
<string>report_tree</string>
<string>selection_name</string>
<string>sort_columns</string>
<string>stat_method</string>
<string>title</string>
</list>
</value>
</item>
......@@ -238,6 +239,17 @@
<key> <string>separate_tree_data</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>sort_columns</string> </key>
<value>
<list>
<tuple>
<string>id</string>
<string>ID</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>stat_method</string> </key>
<value>
......
......@@ -13,16 +13,17 @@
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>title</string>
<string>columns</string>
<string>all_columns</string>
<string>columns</string>
<string>editable_columns</string>
<string>list_method</string>
<string>stat_method</string>
<string>selection_name</string>
<string>portal_types</string>
<string>editable_columns</string>
<string>report_tree</string>
<string>report_root_list</string>
<string>report_tree</string>
<string>selection_name</string>
<string>sort_columns</string>
<string>stat_method</string>
<string>title</string>
</list>
</value>
</item>
......@@ -230,6 +231,17 @@
<key> <string>separate_tree_data</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>sort_columns</string> </key>
<value>
<list>
<tuple>
<string>id</string>
<string>ID</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>stat_method</string> </key>
<value>
......
717
\ No newline at end of file
721
\ 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