xowf::test_item::Answer_manager method set_exam_results (public)

 <instance of xowf::test_item::Answer_manager[i]> set_exam_results \
    [ -obj obj ] property value

Defined in packages/xowf/tcl/test-item-procs.tcl

ns_log notice "SES '$property' bytes [string length $value]"

Switches:
-obj
(optional)
Parameters:
property
value

Partial Call Graph (max 5 caller/called nodes):
%3 test_create_test_items create_test_items (test xowf) xowf::test_item::Answer_manager instproc set_exam_results xowf::test_item::Answer_manager instproc set_exam_results test_create_test_items->xowf::test_item::Answer_manager instproc set_exam_results

Testcases:
create_test_items
Source code:
set p [$obj childpage -name en:result -form inclass-exam-statistics.wf]
set instance_attributes [$p instance_attributes]
dict set instance_attributes $property $value
$p update_attribute_from_slot [$p find_slot instance_attributes] ${instance_attributes}
#
# cleanup of legacy values
#
set instance_attributes [$obj instance_attributes]
foreach property_name [list $property __$property] {
  if {[dict exists $instance_attributes $property_name]} {
    ns_log notice "SES set_exam_results:"  "clearing values from earlier releases for '$property_name'"  "was <[dict get $instance_attributes $property_name]>"
    dict unset instance_attributes $property_name
    $obj set instance_attributes $instance_attributes
    #ns_log notice "FINAL IA <$instance_attributes> for item_id [$obj item_id]"  "revision_id [$obj revision_id]"
    $obj update_attribute_from_slot [$obj find_slot instance_attributes] $instance_attributes
    ::xo::xotcl_object_cache flush [$obj item_id]
    ::xo::xotcl_object_cache flush [$obj revision_id]
  }
}
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: