Index: openacs-4/packages/project-manager/lib/project-portlet.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/lib/project-portlet.tcl,v diff -u -r1.3 -r1.4 --- openacs-4/packages/project-manager/lib/project-portlet.tcl 3 Jun 2005 22:13:44 -0000 1.3 +++ openacs-4/packages/project-manager/lib/project-portlet.tcl 5 Jun 2005 22:58:35 -0000 1.4 @@ -29,9 +29,20 @@ set project(latest_finish_date) [lc_time_fmt $project(latest_finish_date) "%x"] set edit_url "[ad_conn package_url]add-edit?[export_url_vars project_item_id]" +# ------------------ +# Dynamic Attributes +# ------------------ + +set form_attributes [list] +foreach element [dtype::form::metadata::widgets_list -object_type pm_project -exclude_static_p 1 -dform $project(dform)] { + lappend form_attributes [lindex $element 3] +} + dtype::get_object -object_id $project_id -object_type pm_project -array dattr -exclude_static multirow create dynamic_attributes name value foreach attr [array names dattr] { - multirow append dynamic_attributes "[_ dynamic-types.pm_project_$attr]" $dattr($attr) + if {[lsearch -exact $form_attributes $attr] > -1} { + multirow append dynamic_attributes "[_ acs-translations.pm_project_$attr]" $dattr($attr) + } } Index: openacs-4/packages/project-manager/lib/project-portlet.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/lib/project-portlet.xql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/project-manager/lib/project-portlet.xql 3 Jun 2005 22:13:44 -0000 1.2 +++ openacs-4/packages/project-manager/lib/project-portlet.xql 5 Jun 2005 22:58:35 -0000 1.3 @@ -27,6 +27,7 @@ p.actual_hours_completed, p.estimated_hours_total, p.parent_id, + p.dform, s.status_type, acs_permission__permission_p (:project_id,:user_id,'write') as write_p, acs_permission__permission_p (:project_id,:user_id,'create') as create_p Index: openacs-4/packages/project-manager/www/task-add-edit-one.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/www/task-add-edit-one.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/project-manager/www/task-add-edit-one.tcl 5 Jun 2005 00:11:05 -0000 1.4 +++ openacs-4/packages/project-manager/www/task-add-edit-one.tcl 5 Jun 2005 22:58:35 -0000 1.5 @@ -72,6 +72,7 @@ } else { set project_options [pm::project::get_list_of_open] } + db_1row get_dynamic_form {} } else { set edit_p f } Index: openacs-4/packages/project-manager/www/task-add-edit-one.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/www/task-add-edit-one.xql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/project-manager/www/task-add-edit-one.xql 5 Jun 2005 00:11:05 -0000 1.2 +++ openacs-4/packages/project-manager/www/task-add-edit-one.xql 5 Jun 2005 22:58:35 -0000 1.3 @@ -10,12 +10,20 @@ + + + select dform + from pm_tasks_revisions + where task_revision_id = :task_id + + + select title as task_title, description, mime_type as description_mime_type, percent_complete, to_char(end_date,'YYYY-MM-DD') as task_end_date, estimated_hours_work, estimated_hours_work_min, - estimated_hours_work_max, priority, dform + estimated_hours_work_max, priority from pm_tasks_revisionsi where object_id = :task_id Index: openacs-4/packages/project-manager/www/task-one-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/www/task-one-oracle.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/project-manager/www/task-one-oracle.xql 29 Apr 2005 17:43:38 -0000 1.1 +++ openacs-4/packages/project-manager/www/task-one-oracle.xql 5 Jun 2005 22:58:35 -0000 1.2 @@ -21,6 +21,8 @@ t.estimated_hours_work_min, t.estimated_hours_work_max, t.percent_complete, + t.priority, + t.dform, i.live_revision, p.first_names || ' ' || p.last_name as creation_user, proj_rev.title as project_name Index: openacs-4/packages/project-manager/www/task-one-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/www/task-one-postgresql.xql,v diff -u -r1.3 -r1.4 --- openacs-4/packages/project-manager/www/task-one-postgresql.xql 3 Jun 2005 22:13:44 -0000 1.3 +++ openacs-4/packages/project-manager/www/task-one-postgresql.xql 5 Jun 2005 22:58:35 -0000 1.4 @@ -23,6 +23,7 @@ t.estimated_hours_work_max, t.percent_complete, t.priority, + t.dform, i.live_revision, p.first_names || ' ' || p.last_name as creation_user, proj_rev.title as project_name, Index: openacs-4/packages/project-manager/www/task-one.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/project-manager/www/task-one.tcl,v diff -u -r1.5 -r1.6 --- openacs-4/packages/project-manager/www/task-one.tcl 3 Jun 2005 22:13:44 -0000 1.5 +++ openacs-4/packages/project-manager/www/task-one.tcl 5 Jun 2005 22:58:35 -0000 1.6 @@ -241,11 +241,18 @@ # Dynamic Attributes # ------------------ +set form_attributes [list] +foreach element [dtype::form::metadata::widgets_list -object_type pm_task -exclude_static_p 1 -dform $task_info(dform)] { + lappend form_attributes [lindex $element 3] +} + dtype::get_object -object_id $task_revision_id -object_type pm_task -array dattr -exclude_static multirow create dynamic_attributes name value foreach attr [array names dattr] { - multirow append dynamic_attributes "[_ dynamic-types.pm_task_$attr]" $dattr($attr) + if {[lsearch -exact $form_attributes $attr] > -1} { + multirow append dynamic_attributes "[_ acs-translations.pm_task_$attr]" $dattr($attr) + } }