Index: openacs-4/packages/assessment/tcl/as-item-display-tb-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-item-display-tb-procs.tcl,v diff -u -r1.8.2.1 -r1.8.2.2 --- openacs-4/packages/assessment/tcl/as-item-display-tb-procs.tcl 31 May 2005 23:13:00 -0000 1.8.2.1 +++ openacs-4/packages/assessment/tcl/as-item-display-tb-procs.tcl 9 Aug 2005 00:31:14 -0000 1.8.2.2 @@ -10,13 +10,16 @@ {-html_display_options ""} {-abs_size ""} {-item_answer_alignment ""} + {-package_id ""} } { @author Natalia Perez (nperper@it.uc3m.es) @creation-date 2004-09-29 New Item Display TextBox Type to the database } { - set package_id [ad_conn package_id] + if { ![exists_and_not_null package_id] } { + set package_id [ad_conn package_id] + } set folder_id [as::assessment::folder_id -package_id $package_id] # Insert as_item_display_tb in the CR (and as_item_display_tb table) getting the revision_id (as_item_display_id) Index: openacs-4/packages/assessment/tcl/as-item-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-item-procs.tcl,v diff -u -r1.14.2.1 -r1.14.2.2 --- openacs-4/packages/assessment/tcl/as-item-procs.tcl 31 May 2005 23:13:00 -0000 1.14.2.1 +++ openacs-4/packages/assessment/tcl/as-item-procs.tcl 9 Aug 2005 00:31:14 -0000 1.14.2.2 @@ -19,13 +19,16 @@ {-feedback_right ""} {-feedback_wrong ""} {-points ""} + {-package_id ""} } { @author Eduardo Perez (eperez@it.uc3m.es) @creation-date 2004-07-26 New item to the database } { - set package_id [ad_conn package_id] + if { ![exists_and_not_null package_id] } { + set package_id [ad_conn package_id] + } set folder_id [as::assessment::folder_id -package_id $package_id] # Insert as_item in the CR (and as_items table) getting the revision_id (as_item_id) Index: openacs-4/packages/assessment/tcl/as-item-type-sa-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-item-type-sa-procs.tcl,v diff -u -r1.13.2.1 -r1.13.2.2 --- openacs-4/packages/assessment/tcl/as-item-type-sa-procs.tcl 31 May 2005 23:13:01 -0000 1.13.2.1 +++ openacs-4/packages/assessment/tcl/as-item-type-sa-procs.tcl 9 Aug 2005 00:31:14 -0000 1.13.2.2 @@ -9,14 +9,17 @@ ad_proc -public as::item_type_sa::new { {-title ""} {-increasing_p ""} - {-allow_negative_p ""} + {-allow_negative_p ""} + {-package_id ""} } { @author Natalia Perez (nperper@it.uc3m.es) @creation-date 2004-09-29 New Short Answer Answers item to the data database } { - set package_id [ad_conn package_id] + if { ![exists_and_not_null package_id] } { + set package_id [ad_conn package_id] + } set folder_id [as::assessment::folder_id -package_id $package_id] # Insert as_item_type_sa in the CR (and as_item_type_sa table) getting the revision_id (as_item_type_id)