diff options
-rwxr-xr-x | GradeBook_lib.tcl | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/GradeBook_lib.tcl b/GradeBook_lib.tcl index 8c2f14d..7d89afe 100755 --- a/GradeBook_lib.tcl +++ b/GradeBook_lib.tcl @@ -1949,11 +1949,23 @@ proc htmlEditUserGradeValue {permission_list user } { set FirstName [SelectColValue4User FirstName $modified_user] set LastName [SelectColValue4User LastName $modified_user] set old_value [SelectColValue4User $modified_column $modified_user] + set column_category [SelectColValue4User $modified_column _Col_Category_] puts "<div class=edit_user_grade_request>" puts "Change grade for student <b>$FirstName $LastName</b> with user name $modified_user" puts "<form name=\"input\" action=\"$script_name\" method=\"post\" >" - puts "<b>$modified_column</b> old value: \{$old_value\}," - puts "new value: <input name=\"newcolumnvalue\" value=\"$old_value\" ><br>" + set needs_textarea false + switch $column_category { + Note {set needs_textarea true} + Info {set needs_textarea true} + default { } + } + if { !$needs_textarea } { + puts "<b>$modified_column</b> old value: \{$old_value\}," + puts "new value: <input name=\"newcolumnvalue\" value=\"$old_value\" ><br>" + } else { + puts "<b>$modified_column</b>:" + puts "<br><textarea rows=\"10\" cols=\"80\" name=\"newcolumnvalue\" value=\"$old_value\">$old_value</textarea><br>" + } puts {<input type="hidden" name="action" value="edit_user_grade">} puts [join [ list {<input type="hidden" name="user2modify" value="} $modified_user {">} ] ""] puts [join [ list {<input type="hidden" name="column2modify" value="} $modified_column {">} ] "" ] |