- Response submitted Correcly!
+ Response submitted Correctly!
+ #assessment.View_results#
Index: openacs-4/packages/assessment/www/process-response.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/Attic/process-response.tcl,v
diff -u -r1.2 -r1.3
--- openacs-4/packages/assessment/www/process-response.tcl 21 Sep 2004 15:07:12 -0000 1.2
+++ openacs-4/packages/assessment/www/process-response.tcl 22 Sep 2004 15:27:08 -0000 1.3
@@ -7,19 +7,23 @@
@author eperez@it.uc3m.es
@date 2004-09-12
} {
- assessment_id:integer
+ as_session_id:integer,notnull
response_to_item:array,optional,multiple,html
}
set context_bar [list]
-set as_session_id [as_session__get_session_id_from_user_assessment -subject_id [ad_conn user_id] -assessment_id $assessment_id]
+# FIXME Check staff_id or subject_id against user_id
+db_dml session_finished {UPDATE as_sessions SET last_mod_datetime = NOW(), completed_datetime = NOW() WHERE session_id = :as_session_id}
+
foreach response_to_item_id [array names response_to_item] {
- db_foreach session_responses_to_item {SELECT as_item_datax.item_id FROM (as_item_datax INNER JOIN as_sessionsx ON as_item_datax.session_id = as_sessionsx.session_id) INNER JOIN as_itemsx ON as_item_datax.as_item_id=as_itemsx.as_item_id WHERE as_itemsx.as_item_id=:response_to_item_id AND as_sessionsx.session_id=:as_session_id} {
+ db_foreach session_responses_to_item {SELECT as_item_datax.item_id FROM as_item_datax WHERE as_item_datax.as_item_id=:response_to_item_id AND as_sessionsx.session_id=:as_session_id} {
content::item::delete -item_id $item_id
}
foreach response $response_to_item($response_to_item_id) {
as_item_data_new -session_id $as_session_id -as_item_id $response_to_item_id -choice_id_answer $response
}
}
+
+ad_return_template
Index: openacs-4/packages/assessment/www/admin/unzip-file.adp
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/admin/Attic/unzip-file.adp,v
diff -u -r1.1 -r1.2
--- openacs-4/packages/assessment/www/admin/unzip-file.adp 21 Sep 2004 17:35:40 -0000 1.1
+++ openacs-4/packages/assessment/www/admin/unzip-file.adp 22 Sep 2004 15:27:09 -0000 1.2
@@ -4,5 +4,5 @@