Index: openacs-4/contrib/packages/project-manager/www/task-one-postgresql.xql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/project-manager/www/Attic/task-one-postgresql.xql,v
diff -u -r1.4 -r1.5
--- openacs-4/contrib/packages/project-manager/www/task-one-postgresql.xql 4 Aug 2003 22:40:21 -0000 1.4
+++ openacs-4/contrib/packages/project-manager/www/task-one-postgresql.xql 4 Aug 2003 23:44:52 -0000 1.5
@@ -11,6 +11,18 @@
+
+
+ SELECT
+ t.revision_id as task_revision_id
+ FROM
+ pm_tasks_revisionsx t, cr_items i
+ WHERE
+ t.item_id = :task_id and
+ i.live_revision = t.revision_id
+
+
+
SELECT
@@ -19,7 +31,7 @@
pm_tasks_revisionsx t, cr_items i
WHERE
i.item_id = t.item_id and
- t.item_id = :task_id
+ t.revision_id = :task_revision_id
@@ -31,12 +43,14 @@
t.description,
to_char(t.start_date,'MM/DD/YYYY') as start_date,
to_char(t.end_date,'MM/DD/YYYY') as end_date,
- t.percent_complete
+ t.percent_complete,
+ i.live_revision
FROM
pm_tasks_revisionsx t, cr_items i
WHERE
t.item_id = :task_id and
- t.revision_id = i.live_revision
+ t.revision_id = :task_revision_id and
+ t.item_id = i.item_id
@@ -57,7 +71,7 @@
t.item_id = :task_id and
t.item_id = i.item_id
ORDER BY
- t.revision_id
+ t.revision_id desc