| |
322 |
322 |
-as_item_id $as_item_id \ |
| |
323 |
323 |
-after $after \ |
| |
324 |
324 |
-title $title |
| |
325 |
325 |
} |
| |
326 |
326 |
fu { |
| |
327 |
327 |
as::item_type_fu::add_to_assessment \ |
| |
328 |
328 |
-assessment_id $assessment_id \ |
| |
329 |
329 |
-section_id $section_id \ |
| |
330 |
330 |
-as_item_id $as_item_id \ |
| |
331 |
331 |
-after $after \ |
| |
332 |
332 |
-title $title |
| |
333 |
333 |
} |
| |
334 |
334 |
} |
| |
335 |
335 |
} |
| |
336 |
336 |
} |
| |
337 |
337 |
} -after_submit { |
| |
338 |
338 |
if {(![info exists formbutton_add_another_question] || $formbutton_add_another_question eq "") \ |
| |
339 |
339 |
&& (![info exists formbutton_add_another_choice] || $formbutton_add_another_choice eq "")} { |
| |
340 |
340 |
set return_url "[export_vars -base questions {assessment_id}]\&#Q$as_item_id" |
| |
341 |
341 |
} elseif {([info exists formbutton_add_another_question] && $formbutton_add_another_question ne "")} { |
| |
342 |
|
set after [expr {$after + 1}] |
| |
|
342 |
incr after |
| |
343 |
343 |
set return_url "[export_vars -base item-add {after assessment_id section_id}]\#Q$as_item_id" |
| |
344 |
344 |
} |
| |
345 |
345 |
if {[info exists return_url] && $return_url ne ""} { |
| |
346 |
346 |
if {[info exists save_answer_set] && $save_answer_set eq "on" && (![info exists add_existing_mc_id] || $add_existing_mc_id eq "")} { |
| |
347 |
347 |
set return_url [export_vars -base save-answer-set {assessment_id as_item_id return_url {mc_id $new_mc_id}}] |
| |
348 |
348 |
} |
| |
349 |
349 |
ad_returnredirect $return_url |
| |
350 |
350 |
ad_script_abort |
| |
351 |
351 |
} |
| |
352 |
352 |
} |
| |
353 |
353 |
|
| |
354 |
354 |
|
| |
355 |
355 |
ad_return_template |
| |
356 |
356 |
|
| |
357 |
357 |
# Local variables: |
| |
358 |
358 |
# mode: tcl |
| |
359 |
359 |
# tcl-indent-level: 4 |
| |
360 |
360 |
# indent-tabs-mode: nil |
| |
361 |
361 |
# End: |