aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugeniy Mikhailov <evgmik@gmail.com>2014-05-08 10:16:39 -0400
committerEugeniy Mikhailov <evgmik@gmail.com>2014-05-08 10:16:39 -0400
commit78245ae9df68520b91846ff7a7ab605fc4969813 (patch)
treefc11af1c618946ada0eea4755bff20b76bb551fa
parentf95094659adaad56feb09678d363afaa51013863 (diff)
downloadGradeBook-78245ae9df68520b91846ff7a7ab605fc4969813.tar.gz
GradeBook-78245ae9df68520b91846ff7a7ab605fc4969813.zip
stddev treated differently in GrandTotal, i.e. no letter grade
-rwxr-xr-xGradeBook_lib.tcl13
1 files changed, 8 insertions, 5 deletions
diff --git a/GradeBook_lib.tcl b/GradeBook_lib.tcl
index 7be159f..e6199ef 100755
--- a/GradeBook_lib.tcl
+++ b/GradeBook_lib.tcl
@@ -1149,7 +1149,7 @@ proc htmlFormatTheStatsForGradeRaw { stats_needed sql_column_str hidden_columns
}
}
}
- set html_str [join [list $html_str "\n" [htmlFormatColVal $col_value $columnname _The_Highest_Grade_ _The_Highest_Grade_ {} {b}] ] {}]
+ set html_str [join [list $html_str "\n" [htmlFormatColVal $col_value $columnname $sql_user_name $sql_user_name {} {b}] ] {}]
}
set html_str [join [list $html_str "\n" "</tr>"]]
return $html_str
@@ -1166,19 +1166,22 @@ proc htmlFormatColVal { col_value columnname user user_shown permission_list {fo
}
set category [SelectColValue4User $columnname _Col_Category_]
set max_points [SelectColValue4User $columnname _Max_Points_]
- set special_user_names [list _Max_Points_ _The_Highest_Grade_ _The_Lowest_Grade_ _The_Mean_Grade_ _The_Median_Grade_]
+ set special_user_names [list _Max_Points_ _The_Highest_Grade_ _The_Lowest_Grade_ _The_Mean_Grade_ _The_Median_Grade_ _The_StDev_Grade_ ]
if { (([SelectColValue4User GroupName $user_shown] ne "inforow") || ($user in $special_user_names)) && ($category eq "weighted_column") && ($max_points != 0) } {
if { $col_value eq "" } {
set col_value 0
}
# calculate letter grade to Grand Total
- if { $columnname eq "Grand Total" } {
+ if { ($columnname eq "Grand Total") && ($user ne "_The_StDev_Grade_") } {
set col_value_letter_grade [number2letter_grade $col_value]
+ } else {
+ # leave intact for stdev
+ set col_value_letter_grade $col_value
}
# promote to percent format
- set col_value [format "%04.2f%%" [expr {100.* $col_value} ] ]
+ set col_value [format "%04.2f%%" [expr {100.* $col_value} ] ]
# add letter grade to Grand Total
- if { $columnname eq "Grand Total" } {
+ if { ($columnname eq "Grand Total") && ($user ne "_The_StDev_Grade_") } {
set col_value [ concat $col_value "=" <b> $col_value_letter_grade </b>]
}
}