Index: openacs-4/packages/assessment/tcl/as-assessment-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-assessment-procs-postgresql.xql,v diff -u -r1.8 -r1.8.2.1 --- openacs-4/packages/assessment/tcl/as-assessment-procs-postgresql.xql 15 Apr 2005 17:26:45 -0000 1.8 +++ openacs-4/packages/assessment/tcl/as-assessment-procs-postgresql.xql 18 Jul 2005 16:56:37 -0000 1.8.2.1 @@ -10,7 +10,7 @@ a.anonymous_p, a.secure_access_p, a.reuse_responses_p, a.ip_mask, a.password, a.show_item_name_p, a.entry_page, a.exit_page, a.consent_page, a.return_url, a.start_time, a.end_time, a.number_tries, a.wait_between_tries, a.random_p, - a.time_for_response, a.show_feedback, a.section_navigation, a.creator_id, a.survey_p + a.time_for_response, a.show_feedback, a.section_navigation, a.creator_id, a.survey_p, a.type, cr.title as html_title from as_assessments a, cr_revisions cr, cr_items ci, acs_objects o where ci.item_id = :assessment_id and cr.revision_id = ci.latest_revision Index: openacs-4/packages/assessment/tcl/as-assessment-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-assessment-procs.tcl,v diff -u -r1.26.2.1 -r1.26.2.2 --- openacs-4/packages/assessment/tcl/as-assessment-procs.tcl 10 Jun 2005 18:53:30 -0000 1.26.2.1 +++ openacs-4/packages/assessment/tcl/as-assessment-procs.tcl 18 Jul 2005 16:56:37 -0000 1.26.2.2 @@ -32,6 +32,7 @@ {-show_feedback ""} {-section_navigation ""} {-survey_p ""} + {-type ""} } { @author Eduardo Perez (eperez@it.uc3m.es) @creation-date 2004-07-26 @@ -80,7 +81,9 @@ [list password $password] \ [list show_feedback $show_feedback] \ [list section_navigation $section_navigation] \ - [list survey_p $survey_p]] ] + [list survey_p $survey_p] \ + [list type $type]]] + } return $as_assessment_id @@ -111,6 +114,7 @@ {-password ""} {-show_feedback ""} {-section_navigation ""} + {-type ""} } { @author Timo Hentschel (timo@timohentschel.de) @creation-date 2004-10-26 @@ -146,7 +150,8 @@ [list ip_mask $ip_mask] \ [list password $password] \ [list show_feedback $show_feedback] \ - [list section_navigation $section_navigation] ] ] + [list section_navigation $section_navigation] \ + [list type $type]] ] copy_sections -assessment_id $assessment_rev_id -new_assessment_id $new_rev_id } @@ -178,8 +183,9 @@ # own way return } - + set assessment_data(creator_name) [person::name -person_id $assessment_data(creation_user)] + set assessment_data(title) [as::assessment::title -title $assessment_data(title)] } ad_proc -public as::assessment::new_revision { @@ -219,7 +225,8 @@ [list ip_mask $a(ip_mask)] \ [list password $a(password)] \ [list show_feedback $a(show_feedback)] \ - [list section_navigation $a(section_navigation)] ] ] + [list section_navigation $a(section_navigation)] \ + [list type $a(type)]]] copy_sections -assessment_id $a(assessment_rev_id) -new_assessment_id $new_rev_id copy_categories -from_id $a(assessment_rev_id) -to_id $new_rev_id @@ -279,7 +286,8 @@ [list ip_mask $a(ip_mask)] \ [list password $a(password)] \ [list show_feedback $a(show_feedback)] \ - [list section_navigation $a(section_navigation)] ] ] + [list section_navigation $a(section_navigation)] \ + [list type $a(type)]] ] copy_sections -assessment_id $a(assessment_rev_id) -new_assessment_id $new_rev_id copy_categories -from_id $a(assessment_rev_id) -to_id $new_rev_id @@ -555,4 +563,18 @@ } +ad_proc -private as::assessment::title { + -title +} { + @annyflores@viaro.net + Remove html tags from assessment title +} { + + regsub -all {\<[a-zA-Z]*\>} $title "" title + regsub -all {} $title "" title + regsub -all {} $title "" title + + return $title + +}