Index: openacs-4/packages/assessment/tcl/as-qti-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-qti-procs.tcl,v diff -u -r1.6 -r1.7 --- openacs-4/packages/assessment/tcl/as-qti-procs.tcl 28 Oct 2004 14:27:16 -0000 1.6 +++ openacs-4/packages/assessment/tcl/as-qti-procs.tcl 4 Nov 2004 13:16:18 -0000 1.7 @@ -30,6 +30,7 @@ set as_assessments__name [$assessment getAttribute {ident}] set nodesList [$assessment childNodes] set as_assessments__definition "" + set as_assessments__instructions "" foreach node $nodesList { set nodeName [$node nodeName] if {$nodeName == "qticomment"} { @@ -44,10 +45,16 @@ set definition [lindex $definitionNodes 0] set as_assessments__definition [$definition nodeValue] } + } elseif {$nodeName == "rubric"} { + set instructionNodes [$assessment selectNodes {rubric/material/mattext/text()}] + if {[llength $instructionNodes] != 0} { + set instruction [lindex $instructionNodes 0] + set as_assessments__instructions [$instruction nodeValue] + } } } # Insert assessment in the CR (and as_assessments table) getting the revision_id (assessment_id) - set as_assessments__assessment_id [as::assessment::new -name $as_assessments__name -title $as_assessments__title -description $as_assessments__definition] + set as_assessments__assessment_id [as::assessment::new -name $as_assessments__name -title $as_assessments__title -description $as_assessments__definition -instructions $as_assessments__instructions] # Section set sectionNodes [$assessment selectNodes {section}] @@ -65,7 +72,13 @@ set definition [lindex $definitionNodes 0] set as_sections__definition [$definition nodeValue] } - } + } elseif {$nodeName == "objectives"} { + set definitionNodes [$section selectNodes {objectives/material/mattext/text()}] + if {[llength $definitionNodes] != 0} { + set definition [lindex $definitionNodes 0] + set as_sections__definition [$definition nodeValue] + } + } } # Insert section in the CR (the and the as_sections table) getting the revision_id (section_id) set as_sections__section_id [as::section::new -name $as_sections__name -title $as_sections__title -description $as_sections__definition] Index: openacs-4/packages/assessment/www/assessment.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/assessment.adp,v diff -u -r1.8 -r1.9 --- openacs-4/packages/assessment/www/assessment.adp 3 Nov 2004 14:51:52 -0000 1.8 +++ openacs-4/packages/assessment/www/assessment.adp 4 Nov 2004 13:16:19 -0000 1.9 @@ -4,6 +4,7 @@ + Index: openacs-4/packages/assessment/www/assessment.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/Attic/assessment.tcl,v diff -u -r1.9 -r1.10 --- openacs-4/packages/assessment/www/assessment.tcl 14 Oct 2004 11:48:36 -0000 1.9 +++ openacs-4/packages/assessment/www/assessment.tcl 4 Nov 2004 13:16:19 -0000 1.10 @@ -18,6 +18,13 @@ WHERE assessment_id = :assessment_id }] +set assessment_instruction [db_string assessment_instruction { + SELECT instructions + FROM as_assessmentsx + WHERE assessment_id = :assessment_id +}] + + db_dml session_start { UPDATE as_sessions SET creation_datetime = NOW() Index: openacs-4/packages/assessment/www/session.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/session.adp,v diff -u -r1.10 -r1.11 --- openacs-4/packages/assessment/www/session.adp 3 Nov 2004 14:51:52 -0000 1.10 +++ openacs-4/packages/assessment/www/session.adp 4 Nov 2004 13:16:19 -0000 1.11 @@ -19,7 +19,7 @@
@assessment_name@
@assessment_instruction@

- +
@items.section_title@
#assessment.section#: @items.section_title@
@items.section_description@