Index: openacs-4/packages/assessment/sql/postgresql/assessment-section-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/sql/postgresql/assessment-section-create.sql,v diff -u -r1.8 -r1.9 --- openacs-4/packages/assessment/sql/postgresql/assessment-section-create.sql 17 Nov 2004 17:16:07 -0000 1.8 +++ openacs-4/packages/assessment/sql/postgresql/assessment-section-create.sql 22 Nov 2004 11:40:37 -0000 1.9 @@ -126,7 +126,11 @@ -- how shall the navigation happen (default path, randomized, rule-based branching) section_navigation varchar(50) default 'default path' constraint as_assessments_section_navigation_ck - check (section_navigation in ('default path', 'randomized', 'rule-based branching')) + check (section_navigation in ('default path', 'randomized', 'rule-based branching')), + -- differenciate between an assessment and a survey + survey_p char(1) default 'f' + constraint as_assessments_survey_p_ck + check (survey_p in ('t', 'f')) ); -- Style Options 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.3 -r1.4 --- openacs-4/packages/assessment/tcl/as-assessment-procs.tcl 15 Nov 2004 17:17:15 -0000 1.3 +++ openacs-4/packages/assessment/tcl/as-assessment-procs.tcl 22 Nov 2004 11:40:42 -0000 1.4 @@ -28,6 +28,7 @@ {-time_for_response ""} {-show_feedback ""} {-section_navigation ""} + {-survey_p ""} } { @author Eduardo Perez (eperez@it.uc3m.es) @creation-date 2004-07-26 @@ -64,7 +65,8 @@ [list wait_between_tries $wait_between_tries] \ [list time_for_response $time_for_response] \ [list show_feedback $show_feedback] \ - [list section_navigation $section_navigation] ] ] + [list section_navigation $section_navigation] \ + [list survey_p $survey_p]] ] } return $as_assessment_id Index: openacs-4/packages/assessment/tcl/as-install-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/tcl/as-install-procs.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/assessment/tcl/as-install-procs.tcl 17 Nov 2004 17:16:07 -0000 1.4 +++ openacs-4/packages/assessment/tcl/as-install-procs.tcl 22 Nov 2004 11:40:42 -0000 1.5 @@ -139,6 +139,7 @@ content::type::create_attribute -content_type {as_assessments} -attribute_name {time_for_response} -datatype {number} -pretty_name {Assessment Time for Response} -column_spec {integer} content::type::create_attribute -content_type {as_assessments} -attribute_name {show_feedback} -datatype {string} -pretty_name {Assessment Show comments to the user} -column_spec {varchar(50)} content::type::create_attribute -content_type {as_assessments} -attribute_name {section_navigation} -datatype {string} -pretty_name {Assessment Navigation of sections} -column_spec {varchar(50)} +content::type::create_attribute -content_type {as_assessments} -attribute_name {survey_p} -datatype {string} -pretty_name {Assessment or Survey} -column_spec {char(1)} # Sessions content::type::create_attribute -content_type {as_sessions} -attribute_name {assessment_id} -datatype {number} -pretty_name {Assessment ID} -column_spec {integer} 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.10 -r1.11 --- openacs-4/packages/assessment/tcl/as-qti-procs.tcl 17 Nov 2004 17:16:07 -0000 1.10 +++ openacs-4/packages/assessment/tcl/as-qti-procs.tcl 22 Nov 2004 11:40:42 -0000 1.11 @@ -62,8 +62,13 @@ } } } + set resprocessNodes [$root selectNodes {/questestinterop/assessment/section/item/resprocessing}] + set as_assessments__survey_p {f} + if { [llength $resprocessNodes] == 0 } { + set as_assessments__survey_p {t} + } # Insert assessment in the CR (and as_assessments table) getting the revision_id (assessment_id) - set as_assessments__assessment_id [as::assessment::new -title $as_assessments__title -description $as_assessments__definition -instructions $as_assessments__instructions] + set as_assessments__assessment_id [as::assessment::new -title $as_assessments__title -description $as_assessments__definition -instructions $as_assessments__instructions -survey_p $as_assessments__survey_p] # Section set sectionNodes [$assessment selectNodes {section}] Index: openacs-4/packages/assessment/www/session.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/session.adp,v diff -u -r1.11 -r1.12 --- openacs-4/packages/assessment/www/session.adp 4 Nov 2004 13:16:19 -0000 1.11 +++ openacs-4/packages/assessment/www/session.adp 22 Nov 2004 11:40:42 -0000 1.12 @@ -7,7 +7,7 @@
#assessment.Question# @items.rownum@ (@items.maxscore@ #assessment.points#) | |
#assessment.Question# @items.rownum@ | |
| |
@items.choice_html;noquote@ | |
#assessment.This_question_will_be_corrected_by_the_teacher#. | |
#assessment.Score# | @items.score@ / @items.maxscore@
|
#assessment.Feedback#: | |