Index: openacs-4/packages/tasks/catalog/tasks.de_DE.ISO-8859-1.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/catalog/tasks.de_DE.ISO-8859-1.xml,v diff -u -r1.6 -r1.7 --- openacs-4/packages/tasks/catalog/tasks.de_DE.ISO-8859-1.xml 16 Feb 2006 07:21:32 -0000 1.6 +++ openacs-4/packages/tasks/catalog/tasks.de_DE.ISO-8859-1.xml 21 Feb 2006 12:16:46 -0000 1.7 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="ISO-8859-1"?> -<message_catalog package_key="tasks" package_version="0.1d7" locale="de_DE" charset="ISO-8859-1"> +<message_catalog package_key="tasks" package_version="0.1d8" locale="de_DE" charset="ISO-8859-1"> <msg key="a_Task">eine Aufgabe</msg> <msg key="Add_a_task_to_the">Eine Aufgabe f�r die ausgew�hlten Kontakte hinzuf�gen</msg> @@ -79,6 +79,7 @@ <msg key="Update">Aktualisierung</msg> <msg key="Very_Important">Normal</msg> <msg key="View_next">Die n�chsten</msg> + <msg key="View_previous">Die vergangenen</msg> <msg key="Yes">Ja</msg> <msg key="You_can_either_use">Sie k�nnen entwedern eine Standardaufgabe ausw�hlen oder eine eigene definieren, aber nicht beides.</msg> </message_catalog> Index: openacs-4/packages/tasks/catalog/tasks.en_US.ISO-8859-1.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/catalog/tasks.en_US.ISO-8859-1.xml,v diff -u -r1.10 -r1.11 --- openacs-4/packages/tasks/catalog/tasks.en_US.ISO-8859-1.xml 15 Dec 2005 22:55:42 -0000 1.10 +++ openacs-4/packages/tasks/catalog/tasks.en_US.ISO-8859-1.xml 21 Feb 2006 12:16:46 -0000 1.11 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="ISO-8859-1"?> -<message_catalog package_key="tasks" package_version="0.1d7" locale="en_US" charset="ISO-8859-1"> +<message_catalog package_key="tasks" package_version="0.1d8" locale="en_US" charset="ISO-8859-1"> <msg key="a_Task">a Task</msg> <msg key="Add_a_task_to_the">Add a task to the selected contacts</msg> @@ -86,6 +86,7 @@ <msg key="Update">Update</msg> <msg key="Very_Important">Very Important</msg> <msg key="View_next">View next</msg> + <msg key="View_previous">View previous</msg> <msg key="Yes">Yes</msg> <msg key="You_can_either_use">You can either use a standard task or a custom task, but not both</msg> </message_catalog> Index: openacs-4/packages/tasks/lib/tasks-portlet.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/lib/tasks-portlet.adp,v diff -u -r1.3 -r1.4 --- openacs-4/packages/tasks/lib/tasks-portlet.adp 14 Oct 2005 18:01:17 -0000 1.3 +++ openacs-4/packages/tasks/lib/tasks-portlet.adp 21 Feb 2006 12:16:46 -0000 1.4 @@ -11,7 +11,8 @@ party_id=@party_id@ query="@query@" search_id="@search_id@" - tasks_interval="@tasks_interval@" + tasks_previous="@tasks_previous@" + tasks_future="@tasks_future@" tasks_orderby="@tasks_orderby@" page="@page@" page_size="@page_size@" Index: openacs-4/packages/tasks/lib/tasks-portlet.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/lib/tasks-portlet.tcl,v diff -u -r1.3 -r1.4 --- openacs-4/packages/tasks/lib/tasks-portlet.tcl 16 Oct 2005 11:11:12 -0000 1.3 +++ openacs-4/packages/tasks/lib/tasks-portlet.tcl 21 Feb 2006 12:16:46 -0000 1.4 @@ -1,4 +1,4 @@ -foreach optional_param {party_id query search_id tasks_interval page page_size page_flush_p} { +foreach optional_param {party_id query search_id tasks_previous tasks_future page page_size page_flush_p} { if {![info exists $optional_param]} { set $optional_param {} } Index: openacs-4/packages/tasks/lib/tasks-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/lib/tasks-postgresql.xql,v diff -u -r1.10 -r1.11 --- openacs-4/packages/tasks/lib/tasks-postgresql.xql 7 Nov 2005 17:44:03 -0000 1.10 +++ openacs-4/packages/tasks/lib/tasks-postgresql.xql 21 Feb 2006 12:16:46 -0000 1.11 @@ -35,7 +35,7 @@ and ao.object_id = t.task_id and ao.package_id = :package_id and t.start_date < now() - and t.due_date < ( now() + '$tasks_interval days'::interval ) + and t.due_date between ( now() - '$tasks_previous days'::interval ) and ( now() + '$tasks_future days'::interval ) and t.assignee_id = :user_id and t.party_id in ( select parties.party_id from parties @@ -60,7 +60,7 @@ and ao.object_id = t.task_id and ao.package_id = :package_id and t.start_date < now() - and t.due_date < ( now() + '$tasks_interval days'::interval ) + and t.due_date between ( now() - '$tasks_previous days'::interval ) and ( now() + '$tasks_future days'::interval ) and t.assignee_id = :user_id and t.party_id in ( select parties.party_id from parties Index: openacs-4/packages/tasks/lib/tasks.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/lib/tasks.tcl,v diff -u -r1.21 -r1.22 --- openacs-4/packages/tasks/lib/tasks.tcl 16 Feb 2006 07:21:32 -0000 1.21 +++ openacs-4/packages/tasks/lib/tasks.tcl 21 Feb 2006 12:16:46 -0000 1.22 @@ -6,6 +6,8 @@ # hide_form_p="t" # page="@page@" # tasks_orderby="@tasks_orderby@" +# tasks_previous="@tasks_previous@" +# tasks_future="@tasks_future@" # page_flush_p="0" # page_size="15" # format="@format@" @@ -20,8 +22,10 @@ # emp_f Filter to specify if you are going to show the tasks of the organizations only (1) or # or also the employess tasks (2), default to 2. # show_filters_p Boolean to specify if you want to show the filters menu or not. Default to 0 +# tasks_previous Filter for tasks in the past in days +# tasks_future Filter for tasks in the future in days -foreach optional_param {party_id query search_id tasks_interval page page_size page_flush_p elements} { +foreach optional_param {party_id query search_id tasks_previous tasks_future page page_size page_flush_p elements} { if {![info exists $optional_param]} { set $optional_param {} } @@ -74,9 +78,12 @@ set package_id [apm_package_id_from_key tasks] -if { ![exists_and_not_null tasks_interval] } { - set tasks_interval 7 +if { ![exists_and_not_null tasks_previous] } { + set tasks_previous 0 } +if { ![exists_and_not_null tasks_future] } { + set tasks_future 7 +} if { ![exists_and_not_null orderby] } { set orderby "priority,desc" } @@ -97,7 +104,8 @@ search_id {} \ query {} \ page_size {} \ - tasks_interval {} \ + tasks_previous {} \ + tasks_future {} \ party_id {} \ process_instance {}] Index: openacs-4/packages/tasks/www/index.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/www/index.adp,v diff -u -r1.9 -r1.10 --- openacs-4/packages/tasks/www/index.adp 23 Oct 2005 12:58:50 -0000 1.9 +++ openacs-4/packages/tasks/www/index.adp 21 Feb 2006 12:16:47 -0000 1.10 @@ -9,7 +9,8 @@ user_id=@user_id@ query="@query@" search_id="@search_id@" - tasks_interval="@tasks_interval@" + tasks_future="@tasks_future@" + tasks_previous="@tasks_previous@" tasks_orderby="@tasks_orderby@" page="@page@" page_size="@page_size@" Index: openacs-4/packages/tasks/www/index.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/tasks/www/index.tcl,v diff -u -r1.7 -r1.8 --- openacs-4/packages/tasks/www/index.tcl 14 Oct 2005 18:02:01 -0000 1.7 +++ openacs-4/packages/tasks/www/index.tcl 21 Feb 2006 12:16:47 -0000 1.8 @@ -11,7 +11,8 @@ {query ""} {page:optional "1"} {page_size:integer "25"} - {tasks_interval:integer "7"} + {tasks_future:integer "7"} + {tasks_previous:integer "0"} {page_flush_p "0"} } @@ -21,7 +22,7 @@ set package_id [ad_conn package_id] set url [ad_conn url] -set return_url [export_vars -base $url -url {orderby format search_id query page page_size tasks_interval {page_flush_p t}}] +set return_url [export_vars -base $url -url {orderby format search_id query page page_size tasks_future tasks_previous {page_flush_p t}}] set package_id [site_node::get_element -url "/contacts" -element object_id] @@ -40,7 +41,8 @@ {search_id:integer(select),optional {label ""} {options $search_options} {html {onChange "javascript:acs_FormRefresh('search')"}}} {query:text(text),optional {label ""} {html {size 20 maxlength 255}}} {save:text(submit) {label {[_ contacts.Search]}} {value "go"}} - {tasks_interval:integer(text),optional {label " <span style=\"font-size: smaller;\">[_ tasks.View_next]</span>"} {after_html "<span style=\"font-size: smaller;\">days"} {html {size 2 maxlength 3 onChange "javascript:acs_FormRefresh('search')"}}} + {tasks_previous:integer(text),optional {label " <span style=\"font-size: smaller;\">[_ tasks.View_previous]</span>"} {after_html "<span style=\"font-size: smaller;\">days"} {html {size 2 maxlength 3 onChange "javascript:acs_FormRefresh('search')"}}} + {tasks_future:integer(text),optional {label " <span style=\"font-size: smaller;\">[_ tasks.View_next]</span>"} {after_html "<span style=\"font-size: smaller;\">days"} {html {size 2 maxlength 3 onChange "javascript:acs_FormRefresh('search')"}}} } if { [parameter::get -boolean -parameter "ForceSearchBeforeAdd" -default "0"] } {