Index: openacs-4/packages/assessment/www/asm-admin/item-add.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/asm-admin/item-add.tcl,v diff -u -r1.13.2.5 -r1.13.2.6 --- openacs-4/packages/assessment/www/asm-admin/item-add.tcl 23 Feb 2007 17:27:49 -0000 1.13.2.5 +++ openacs-4/packages/assessment/www/asm-admin/item-add.tcl 27 Mar 2007 16:56:25 -0000 1.13.2.6 @@ -262,7 +262,7 @@ as::item_rels::new -item_rev_id $as_item_id -target_rev_id $content_rev_id -type as_item_content_rel } # check question type - + set title [string range $question_text 0 999] switch -exact $item_type { mc { as::item_type_mc::add_to_assessment \ @@ -272,7 +272,7 @@ -choices [array get choice] \ -correct_choices [array get correct] \ -after $after \ - -title $question_text\ + -title $title\ -display_type $display_type } oq { @@ -281,23 +281,23 @@ -section_id $section_id \ -as_item_id $as_item_id \ -after $after \ - -title $question_text + -title $title } sa { as::item_type_sa::add_to_assessment \ -assessment_id $assessment_id \ -section_id $section_id \ -as_item_id $as_item_id \ -after $after \ - -title $question_text + -title $title } fu { as::item_type_fu::add_to_assessment \ -assessment_id $assessment_id \ -section_id $section_id \ -as_item_id $as_item_id \ -after $after \ - -title $question_text + -title $title } } } Index: openacs-4/packages/assessment/www/asm-admin/item-edit-general.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/asm-admin/item-edit-general.tcl,v diff -u -r1.15.2.6 -r1.15.2.7 --- openacs-4/packages/assessment/www/asm-admin/item-edit-general.tcl 23 Mar 2007 16:25:11 -0000 1.15.2.6 +++ openacs-4/packages/assessment/www/asm-admin/item-edit-general.tcl 27 Mar 2007 16:56:25 -0000 1.15.2.7 @@ -232,7 +232,7 @@ set $var [regsub -all "\"$site_url" [set $var] {"}] set $var [regsub -all "\"$site_https_url" [set $var] {"}] } - + db_transaction { set old_display_type [string range [db_string get_display_type {}] end-1 end] set new_item_id [as::item::edit \ @@ -290,9 +290,10 @@ -old_section_id $section_id \ -new_section_id $new_section_id \ -new_assessment_rev_id $new_assessment_rev_id + + set title [string range $question_text 0 999] db_dml update_item_in_section {} - switch -- $item_type { mc { set num_answers 0 @@ -309,7 +310,7 @@ } set new_item_type_id [as::item_type_mc::edit \ -as_item_type_id $as_item_type_id \ - -title $question_text \ + -title $title \ -increasing_p f \ -allow_negative_p f \ -num_correct_answers $num_correct_answers \ @@ -350,7 +351,7 @@ "oq" { set new_item_type_id [as::item_type_oq::edit \ -as_item_type_id $as_item_type_id \ - -title $question_text \ + -title $title \ -default_value "" \ -feedback_text "" \ -reference_answer $reference_answer \ @@ -361,13 +362,13 @@ "fu" { set new_item_type_id [as::item_type_fu::edit \ -as_item_type_id $as_item_type_id \ - -title $question_text] + -title $title] db_dml update_item_type {} } "sa" { set new_item_type_id [as::item_type_sa::edit \ -as_item_type_id $as_item_type_id \ - -title $question_text \ + -title $title \ -increasing_p f\ -allow_negative_p f] db_dml update_item_type {}