Index: openacs-4/packages/evaluation/evaluation.info =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/evaluation.info,v diff -u -r1.9 -r1.10 --- openacs-4/packages/evaluation/evaluation.info 7 Jul 2004 17:26:43 -0000 1.9 +++ openacs-4/packages/evaluation/evaluation.info 14 Jul 2004 17:42:06 -0000 1.10 @@ -17,8 +17,9 @@ - + + @@ -27,8 +28,8 @@ - Index: openacs-4/packages/evaluation/lib/tasks-chunk-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/lib/Attic/tasks-chunk-postgresql.xql,v diff -u -r1.6 -r1.7 --- openacs-4/packages/evaluation/lib/tasks-chunk-postgresql.xql 7 Jul 2004 17:26:44 -0000 1.6 +++ openacs-4/packages/evaluation/lib/tasks-chunk-postgresql.xql 14 Jul 2004 17:42:06 -0000 1.7 @@ -14,7 +14,7 @@ et.requires_grade_p, et.description, et.grade_id, cr.content_length, et.data as task_data, - et.title as task_title, + cr.title as task_title, et.task_id as revision_id, ets.solution_id as solution_id from cr_revisions cr, @@ -39,7 +39,7 @@ et.requires_grade_p, et.description, et.grade_id, - et.title as task_title, + cr.title as task_title, et.data as task_data, et.task_id as revision_id, cr.content_length, Index: openacs-4/packages/evaluation/sql/postgresql/evaluation-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/sql/postgresql/evaluation-create.sql,v diff -u -r1.7 -r1.8 --- openacs-4/packages/evaluation/sql/postgresql/evaluation-create.sql 7 Jul 2004 22:57:02 -0000 1.7 +++ openacs-4/packages/evaluation/sql/postgresql/evaluation-create.sql 14 Jul 2004 17:42:06 -0000 1.8 @@ -234,23 +234,24 @@ 'f' --static_p ); -create function evaluation__new_item (integer,varchar,varchar,integer,integer,varchar,varchar,text,varchar,varchar,text,varchar,varchar,varchar) +create function evaluation__new_item (integer,varchar,varchar,integer,integer,timestamptz,varchar,varchar,text,varchar,varchar,text,varchar,varchar,varchar) returns integer as ' declare p_item_id alias for $1; p_name alias for $2; p_locale alias for $3; p_creation_user alias for $4; p_package_id alias for $5; - p_creation_ip alias for $6; - p_title alias for $7; - p_description alias for $8; - p_mime_type alias for $9; - p_nls_language alias for $10; - p_text alias for $11; - p_storage_type alias for $12; - p_item_subtype alias for $13; - p_content_type alias for $14; + p_creation_date alias for $6; + p_creation_ip alias for $7; + p_title alias for $8; + p_description alias for $9; + p_mime_type alias for $10; + p_nls_language alias for $11; + p_text alias for $12; + p_storage_type alias for $13; + p_item_subtype alias for $14; + p_content_type alias for $15; v_item_id integer; v_parent_id integer; @@ -275,7 +276,7 @@ v_parent_id, -- parent_id v_id, -- item_id p_locale, -- locale - current_timestamp, -- creation_date + p_creation_date, -- creation_date p_creation_user, -- creation_user p_package_id, -- context_id p_creation_ip, -- creation_ip @@ -328,7 +329,7 @@ null, -- data p_item_id, -- item_id p_revision_id, -- revision_id - current_timestamp, -- creation_date + p_creation_date, -- creation_date p_creation_user, -- creation_user p_creation_ip, -- creation_ip null -- content length @@ -432,7 +433,7 @@ null, -- data p_item_id, -- item_id p_revision_id, -- revision_id - current_timestamp, -- creation_date + p_creation_date, -- creation_date p_creation_user, -- creation_user p_creation_ip, -- creation_ip null -- content length @@ -528,7 +529,7 @@ null, -- data p_item_id, -- item_id p_revision_id, -- revision_id - current_timestamp, -- creation_date + p_creation_date, -- creation_date p_creation_user, -- creation_user p_creation_ip, -- creation_ip null -- content length @@ -594,7 +595,7 @@ null, -- data p_item_id, -- item_id p_revision_id, -- revision_id - current_timestamp, -- creation_date + p_creation_date, -- creation_date p_creation_user, -- creation_user p_creation_ip, -- creation_ip null -- content length Index: openacs-4/packages/evaluation/sql/postgresql/evaluation-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/sql/postgresql/evaluation-drop.sql,v diff -u -r1.7 -r1.8 --- openacs-4/packages/evaluation/sql/postgresql/evaluation-drop.sql 7 Jul 2004 22:57:02 -0000 1.7 +++ openacs-4/packages/evaluation/sql/postgresql/evaluation-drop.sql 14 Jul 2004 17:42:06 -0000 1.8 @@ -160,7 +160,7 @@ drop view evaluation_gradesx; drop table evaluation_grades; -drop function evaluation__new_item (integer,varchar,varchar,integer,integer,varchar,varchar,text,varchar,varchar,text,varchar,varchar,varchar); +drop function evaluation__new_item (integer,varchar,varchar,integer,integer,timestamptz,varchar,varchar,text,varchar,varchar,text,varchar,varchar,varchar); --------------------------------------- -- GRADES Index: openacs-4/packages/evaluation/tcl/evaluation-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/tcl/evaluation-procs-postgresql.xql,v diff -u -r1.8 -r1.9 --- openacs-4/packages/evaluation/tcl/evaluation-procs-postgresql.xql 7 Jul 2004 17:26:44 -0000 1.8 +++ openacs-4/packages/evaluation/tcl/evaluation-procs-postgresql.xql 14 Jul 2004 17:42:07 -0000 1.9 @@ -12,6 +12,7 @@ null, :creation_user, :package_id, + current_timestamp, :creation_ip, :name, :description, @@ -94,6 +95,7 @@ null, --locale :creation_user, :to_package_id, + current_timestamp, :creation_ip, :task_name, :description, @@ -158,6 +160,7 @@ null, --locale :creation_user, :package_id, + current_timestamp, :creation_ip, :name, :description, @@ -191,7 +194,7 @@ now(), --creation date :creation_user, :creation_ip, - :item_name, + :title, now(), --publish date null, -- nls_language :mime_type --mime_type @@ -220,6 +223,7 @@ null, --locale :creation_user, :package_id, + current_timestamp, :creation_ip, :title, 'task solution', @@ -245,7 +249,7 @@ now(), --creation date :creation_user, :creation_ip, - :item_name, + :title, now(), --publish date null, -- nls_language :mime_type --mime_type @@ -274,6 +278,7 @@ null, --locale :creation_user, :package_id, + current_timestamp, :creation_ip, :title, 'evaluation answer', @@ -329,6 +334,7 @@ null, --locale :creation_user, :package_id, + current_timestamp, :creation_ip, :title, 'student evaluation', @@ -401,6 +407,7 @@ null, --locale :creation_user, :package_id, + current_timestamp, :creation_ip, :title, 'grades sheet', @@ -579,6 +586,7 @@ null, :creation_user, :package_id, + current_timestamp, :creation_ip, :exams_name, :exams_desc, @@ -634,6 +642,7 @@ null, :creation_user, :package_id, + current_timestamp, :creation_ip, :projects_name, :projects_desc, @@ -690,6 +699,7 @@ null, :creation_user, :package_id, + current_timestamp, :creation_ip, :tasks_name, :tasks_desc, Index: openacs-4/packages/evaluation/tcl/evaluation-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/tcl/evaluation-procs.tcl,v diff -u -r1.9 -r1.10 --- openacs-4/packages/evaluation/tcl/evaluation-procs.tcl 7 Jul 2004 17:26:44 -0000 1.9 +++ openacs-4/packages/evaluation/tcl/evaluation-procs.tcl 14 Jul 2004 17:42:07 -0000 1.10 @@ -67,6 +67,17 @@ return $output } +ad_proc -public evaluation::safe_url_name { + -name:required +} { + returns the filename replacing some characters +} { + + regsub -all {[<>:\"|/@\\\#%&+\\ ,\?]} $name {_} name + return $name + +} + ad_proc -public evaluation::notification::do_notification { -task_id:required -package_id:required Index: openacs-4/packages/evaluation/www/answer-add-edit.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/answer-add-edit.tcl,v diff -u -r1.5 -r1.6 --- openacs-4/packages/evaluation/www/answer-add-edit.tcl 10 Jun 2004 21:08:53 -0000 1.5 +++ openacs-4/packages/evaluation/www/answer-add-edit.tcl 14 Jul 2004 17:42:07 -0000 1.6 @@ -95,6 +95,7 @@ set storage_type text } + set title [evaluation::safe_url_name -name $title] if { [ad_form_new_p -key answer_id] } { set item_id $answer_id } Index: openacs-4/packages/evaluation/www/admin/index.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/index.tcl,v diff -u -r1.6 -r1.7 --- openacs-4/packages/evaluation/www/admin/index.tcl 7 Jul 2004 17:26:44 -0000 1.6 +++ openacs-4/packages/evaluation/www/admin/index.tcl 14 Jul 2004 17:42:07 -0000 1.7 @@ -17,10 +17,10 @@ set page_title "[_ evaluation.Evaluation_Index_]" set context {} -set portal_id [dotlrn_community::get_portal_id -community_id [dotlrn_community::get_community_id]] -set page_id [portal::get_page_id -create -portal_id $portal_id -page_name ""] -set layout_id [portal::get_layout_id -page_id $page_id $portal_id] -set ds_id [portal::get_datasource_id evaluation_assignments_portlet] +#set portal_id [dotlrn_community::get_portal_id -community_id [dotlrn_community::get_community_id]] +#set page_id [portal::get_page_id -create -portal_id $portal_id -page_name ""] +#set layout_id [portal::get_layout_id -page_id $page_id $portal_id] +set ds_id [portal::get_datasource_id evaluation_admin_portlet] set package_id [ad_conn package_id] set user_id [ad_conn user_id] Index: openacs-4/packages/evaluation/www/admin/evaluations/student-list-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/evaluations/student-list-postgresql.xql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/evaluation/www/admin/evaluations/student-list-postgresql.xql 7 Jul 2004 17:26:44 -0000 1.4 +++ openacs-4/packages/evaluation/www/admin/evaluations/student-list-postgresql.xql 14 Jul 2004 17:42:07 -0000 1.5 @@ -7,24 +7,18 @@ select evaluation__party_name(ese.party_id,et.task_id) as party_name, - ea.data as answer_data, - ea.title as answer_title, - ea.revision_id, ese.party_id, ese.grade, - to_char(ea.last_modified, 'YYYY-MM-DD HH24:MI:SS') as submission_date_ansi, - ea.last_modified as submission_date, ese.last_modified as evaluation_date, et.online_p, et.due_date, ese.evaluation_id from evaluation_tasks et, - evaluation_student_evalsi ese left outer join evaluation_answersi ea on (ea.party_id = ese.party_id - and ea.task_id = ese.task_id - and content_revision__is_live(ea.answer_id) = true) + evaluation_student_evalsi ese where et.task_id = :task_id and et.task_id = ese.task_id and content_revision__is_live(ese.evaluation_id) = true + $orderby @@ -37,6 +31,22 @@ + + + + select ea.data as answer_data, + ea.title as answer_title, + ea.revision_id, + to_char(ea.last_modified, 'YYYY-MM-DD HH24:MI:SS') as submission_date_ansi, + ea.last_modified as submission_date + from evaluation_answersi ea + where ea.party_id = :party_id + and ea.task_id = :task_id + and content_revision__is_live(ea.answer_id) = true + + + + @@ -68,11 +78,12 @@ et.due_date, ea.last_modified as submission_date from evaluation_answersi ea, - evaluation_tasks et + evaluation_tasks et, + cr_items cri where ea.task_id = et.task_id and et.task_id = :task_id and ea.data is not null - and content_revision__is_live(ea.answer_id) = true + and cri.live_revision = ea.answer_id $processed_clause Index: openacs-4/packages/evaluation/www/admin/evaluations/student-list.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/evaluations/student-list.adp,v diff -u -r1.6 -r1.7 --- openacs-4/packages/evaluation/www/admin/evaluations/student-list.adp 7 Jul 2004 17:26:44 -0000 1.6 +++ openacs-4/packages/evaluation/www/admin/evaluations/student-list.adp 14 Jul 2004 17:42:07 -0000 1.7 @@ -15,7 +15,7 @@ #evaluation.lt_Is_the_task_submitted# - +

#evaluation.Yes#

#evaluation.No#

Index: openacs-4/packages/evaluation/www/admin/evaluations/student-list.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/evaluations/student-list.tcl,v diff -u -r1.7 -r1.8 --- openacs-4/packages/evaluation/www/admin/evaluations/student-list.tcl 7 Jul 2004 17:26:44 -0000 1.7 +++ openacs-4/packages/evaluation/www/admin/evaluations/student-list.tcl 14 Jul 2004 17:42:07 -0000 1.8 @@ -45,6 +45,54 @@ set actions [list "[_ evaluation.Edit_Evaluations_]" [export_vars -base "evaluations-edit" { task_id }]] +set elements [list party_name \ + [list label "[_ evaluation.Name_]" \ + orderby_asc {party_name asc} \ + orderby_desc {party_name desc} \ + link_url_eval {[export_vars -base "one-evaluation-edit" { evaluation_id task_id evaluation_mode }]} \ + link_html { title "[_ evaluation.View_evaluation_]" } \ + ] \ + grade \ + [list label "[_ evaluation.Grade_over_100_]" \ + orderby_asc {grade asc} \ + orderby_desc {grade desc} \ + ] \ + action \ + [list label "" \ + link_url_col action_url \ + ] \ + ] + +if { [string eq $online_p "t"] } { + lappend elements submission_date_pretty \ + [list label "[_ evaluation.Submission_Date_]" \ + orderby_asc {submission_date_ansi asc} \ + orderby_desc {submission_date_ansi desc}] +} + +lappend elements view \ + [list label "" \ + sub_class narrow \ + display_template {} \ + link_url_eval {[export_vars -base "one-evaluation-edit" { evaluation_id task_id evaluation_mode }]} \ + link_html { title "[_ evaluation.View_evaluation_]" } \ + ] +lappend elements edit \ + [list label "" \ + sub_class narrow \ + display_template {} \ + link_url_eval {[export_vars -base "one-evaluation-edit" { evaluation_id task_id }]} \ + link_html { title "[_ evaluation.Edit_evaluation_]" } \ + ] +lappend elements delete \ + [list label {} \ + sub_class narrow \ + display_template {} \ + link_url_eval {[export_vars -base "evaluation-delete" { evaluation_id return_url task_id }]} \ + link_html { title "[_ evaluation.Delete_evaluation_]" } \ + ] + + template::list::create \ -name evaluated_students \ -multirow evaluated_students \ @@ -53,99 +101,54 @@ -pass_properties { return_url task_id evaluation_mode } \ -filters { task_id {} } \ -orderby { default_value party_name } \ - -elements { - party_name { - label "[_ evaluation.Name_]" - orderby_asc {party_name asc} - orderby_desc {party_name desc} - link_url_eval {[export_vars -base "one-evaluation-edit" { evaluation_id task_id evaluation_mode }]} - link_html { title "[_ evaluation.View_evaluation_]" } - } - grade { - label "[_ evaluation.Grade_over_100_]" - orderby_asc {grade asc} - orderby_desc {grade desc} - } - action { - label "" - link_url_col action_url - } - submission_date_pretty { - label "[_ evaluation.Sumission_Date_]" - orderby_asc {submission_date_ansi asc} - orderby_desc {submission_date_ansi desc} - } - view { - label {} - sub_class narrow - display_template { - - } - link_url_eval {[export_vars -base "one-evaluation-edit" { evaluation_id task_id evaluation_mode }]} - link_html { title "[_ evaluation.View_evaluation_]" } - } - edit { - label {} - sub_class narrow - display_template { - - } - link_url_eval {[export_vars -base "one-evaluation-edit" { evaluation_id task_id }]} - link_html { title "[_ evaluation.Edit_evaluation_]" } - } - delete { - label {} - sub_class narrow - display_template { - - } - link_url_eval {[export_vars -base "evaluation-delete" { evaluation_id return_url task_id }]} - link_html { title "[_ evaluation.Delete_evaluation_]" } - } - } + -elements $elements set orderby [template::list::orderby_clause -orderby -name evaluated_students] if {[string equal $orderby ""]} { set orderby " order by party_name asc" } +set total_evaluated 0 db_multirow -extend { action action_url submission_date_pretty } evaluated_students evaluated_students { *SQL* } { + incr total_evaluated lappend done_students $party_id - set submission_date_pretty [lc_time_fmt $submission_date_ansi "%c"] set grade [format %.2f [lc_numeric $grade]] - if { [template::util::date::compare $submission_date $due_date] > 0 } { - set action "[_ evaluation.lt_submission_date_prett]" - } if { [string eq $online_p "t"] } { - # working with answer stuff (if it has a file/url attached) - if { [empty_string_p $answer_data] } { - set action "[_ evaluation.No_response_]" - } elseif { [regexp "http://" $answer_data] } { - set action_url "[export_vars -base "$answer_data" { }]" - set action "[_ evaluation.View_answer_]" + if { [db_0or1row get_answer_info { *SQL* }] } { + # working with answer stuff (if it has a file/url attached) + if { [empty_string_p $answer_data] } { + set action "[_ evaluation.No_response_]" + } elseif { [regexp "http://" $answer_data] } { + set action_url "[export_vars -base "$answer_data" { }]" + set action "[_ evaluation.View_answer_]" + } else { + # we assume it's a file + set action_url "[export_vars -base "../../view/$answer_title" { revision_id }]" + set action "[_ evaluation.View_answer_]" + } + if { [string eq $action "[_ evaluation.View_answer_]"] && ([template::util::date::compare $submission_date $evaluation_date] > 0) } { + set action " [_ evaluation.View_NEW_answer_]" + } + set submission_date_pretty [lc_time_fmt $submission_date_ansi "%c"] + if { [template::util::date::compare $submission_date $due_date] > 0 } { + set submission_date_pretty "[_ evaluation.lt_submission_date_prett]" + } } else { - # we assume it's a file - set action_url "[export_vars -base "../../view/$answer_title" { revision_id }]" - set action "[_ evaluation.View_answer_]" + set action "[_ evaluation.No_response_]" } - if { [string eq $action "[_ evaluation.View_answer_]"] && ([template::util::date::compare $submission_date $evaluation_date] > 0) } { - set action " [_ evaluation.View_NEW_answer_]" - } } } -set total_evaluated [db_string count_evaluated_students { *SQL* }] - if { [llength $done_students] > 0 } { set processed_clause [db_map processed_clause] } else { set processed_clause "" } -set not_evaluated_with_answer [db_string get_not_eval_wa { *SQL* }] +set not_evaluated_with_answer 0 # # working with students that have answered but have not been yet evaluated @@ -204,6 +207,7 @@ db_multirow -extend { party_url answer answer_url submission_date_pretty portrait } not_evaluated_wa get_not_evaluated_wa_students { *SQL* } { + incr not_evaluated_with_answer if { $number_of_members == 1 } { set portrait "[evaluation::get_user_portrait -user_id $party_id { {alt "[_ evaluation.lt_No_portrait_for_party]"} }]" } else { @@ -276,12 +280,10 @@ if { $number_of_members > 1 } { if { [llength $done_students] > 0 } { - set not_evaluated_with_no_answer [db_string get_not_evaluated_na { *SQL* }] set not_in_clause [db_map not_in_clause] } else { set not_in_clause "" } - set not_evaluated_with_no_answer [db_string count_not_eval_na { *SQL* }] set sql_query [db_map sql_query_groups] } else { set community_id [dotlrn_community::get_community_id] @@ -294,17 +296,18 @@ # if this page is called from within a community (dotlrn) we have to show only the students if { [empty_string_p $community_id] } { - set not_evaluated_with_no_answer [db_string get_not_evaluated_left { *SQL* }] set sql_query [db_map sql_query_individual] } else { - set not_evaluated_with_no_answer [db_string get_community_not_evaluated_left { *SQL* }] set sql_query [db_map sql_query_community_individual] } } +set not_evaluated_with_no_answer 0 + db_multirow -extend { party_url portrait } not_evaluated_na get_not_evaluated_na_students { *SQL* } { + incr not_evaluated_with_no_answer if { $number_of_members == 1 } { set portrait "[evaluation::get_user_portrait -user_id $party_id { {alt "[_ evaluation.lt_No_portrait_for_party]"} }]" } else { Index: openacs-4/packages/evaluation/www/admin/evaluations/student-list.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/evaluations/student-list.xql,v diff -u -r1.5 -r1.6 --- openacs-4/packages/evaluation/www/admin/evaluations/student-list.xql 7 Jul 2004 17:26:44 -0000 1.5 +++ openacs-4/packages/evaluation/www/admin/evaluations/student-list.xql 14 Jul 2004 17:42:07 -0000 1.6 @@ -53,7 +53,7 @@ - select count(*) from cc_users p + select count(*) from persons p $not_in_clause @@ -63,7 +63,7 @@ select count(*) - from cc_users p, + from persons p, registered_users ru, dotlrn_member_rels_approved app $not_in_clause @@ -90,7 +90,7 @@ select p.person_id as party_id, p.last_name||', '||p.first_names as party_name - from cc_users p + from persons p $not_in_clause $orderby_na @@ -102,7 +102,7 @@ p.last_name||', '||p.first_names as party_name from registered_users ru, dotlrn_member_rels_approved app, - cc_users p + persons p $not_in_clause and app.community_id = :community_id and app.user_id = ru.user_id Index: openacs-4/packages/evaluation/www/admin/tasks/solution-add-edit.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/tasks/solution-add-edit.tcl,v diff -u -r1.5 -r1.6 --- openacs-4/packages/evaluation/www/admin/tasks/solution-add-edit.tcl 15 Jun 2004 23:20:30 -0000 1.5 +++ openacs-4/packages/evaluation/www/admin/tasks/solution-add-edit.tcl 14 Jul 2004 17:42:07 -0000 1.6 @@ -188,6 +188,7 @@ set storage_type text } + set title [evaluation::safe_url_name -name $title] if { [ad_form_new_p -key solution_id] } { set item_id $solution_id } Index: openacs-4/packages/evaluation/www/admin/tasks/task-add-edit.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/admin/tasks/task-add-edit.tcl,v diff -u -r1.8 -r1.9 --- openacs-4/packages/evaluation/www/admin/tasks/task-add-edit.tcl 7 Jul 2004 17:26:45 -0000 1.8 +++ openacs-4/packages/evaluation/www/admin/tasks/task-add-edit.tcl 14 Jul 2004 17:42:07 -0000 1.9 @@ -310,6 +310,7 @@ set storage_type lob } + set title [evaluation::safe_url_name -name $title] set due_date [db_string set_date { *SQL* }] if { [ad_form_new_p -key task_id] } { Index: openacs-4/packages/evaluation/www/view/index.vuh =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/view/index.vuh,v diff -u -r1.2 -r1.3 --- openacs-4/packages/evaluation/www/view/index.vuh 22 May 2004 01:20:26 -0000 1.2 +++ openacs-4/packages/evaluation/www/view/index.vuh 14 Jul 2004 17:42:07 -0000 1.3 @@ -11,18 +11,18 @@ # Get the paths set the_root [ns_info pageroot] -set the_url [ad_conn path_info] set package_id [ad_conn package_id] # Get the IDs -set content_type [db_string get_content_type { *SQL* }] +db_1row revision_info { *SQL* } +set the_url $name set content_root [db_string get_folder_id { *SQL* }] set template_root "" # Serve the page - +ns_log Notice "url $the_url the_root $content_root !!\n" if { [content::init the_url the_root $content_root $template_root public $revision_id $content_type] } { set file "$the_root/$the_url" rp_internal_redirect -absolute_path $file Index: openacs-4/packages/evaluation/www/view/index.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/evaluation/www/view/index.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/evaluation/www/view/index.xql 7 Jun 2004 16:05:17 -0000 1.1 +++ openacs-4/packages/evaluation/www/view/index.xql 14 Jul 2004 17:42:07 -0000 1.2 @@ -2,9 +2,9 @@ - + - select cri.content_type + select cri.content_type, cri.name from cr_items cri, cr_revisions crr where cri.item_id = crr.item_id and crr.revision_id = :revision_id