aboutsummaryrefslogtreecommitdiff
path: root/GradeBook.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'GradeBook.tcl')
-rwxr-xr-xGradeBook.tcl9
1 files changed, 5 insertions, 4 deletions
diff --git a/GradeBook.tcl b/GradeBook.tcl
index 91e42c3..168902c 100755
--- a/GradeBook.tcl
+++ b/GradeBook.tcl
@@ -62,7 +62,7 @@ proc AddUserNonWeb { first_name last_name user_name password_hash {group_name {g
}
proc CreateGradesTable {db} {
- set err [catch {db eval {CREATE TABLE GradesTable(FirstName text, LastName text, UserName text, PasswordHash text, GroupName text, UserHiddenColums text, UserHiddenGroups text)} } errStat]
+ set err [catch {db eval {CREATE TABLE GradesTable(FirstName text, LastName text, UserName text, PasswordHash text, GroupName text, UserHiddenColums text, UserHiddenGroups text, IdNum text)} } errStat]
if { $err } {
htmlErrorMsg $errStat
dbg "the following error happen: $errStat" 1
@@ -79,7 +79,7 @@ proc CreateGradesTable {db} {
AddUserNonWeb Jon "Jonovich" jon [::md5::md5 -hex qwerty] student
AddUserNonWeb Ins "Instruch I" instructor [::md5::md5 -hex qwerty] instructor
# reasonable defaults for hidden columns
- set instructor_hidden_columns [list UserHiddenColums PasswordHash UserHiddenGroups]
+ set instructor_hidden_columns [list UserHiddenColums PasswordHash UserHiddenGroups IdNum]
UpdateColValue4GroupNameNonWeb UserHiddenColums instructor $instructor_hidden_columns
}
@@ -158,8 +158,8 @@ proc htmlDBout {db permission_list user {sort_col {}}} {
# set hidden column list
switch $permission(GroupName) {
instructor { set hidden_columns {} }
- ta { set hidden_columns [list UserName PasswordHash GroupName UserHiddenColums] }
- student { set hidden_columns [list FirstName LastName UserName PasswordHash GroupName UserHiddenColums] }
+ ta { set hidden_columns [list UserName PasswordHash GroupName UserHiddenColums UserHiddenGroups IdNum] }
+ student { set hidden_columns [list FirstName LastName UserName PasswordHash GroupName UserHiddenColums UserHiddenGroups IdNum] }
guest { set hidden_columns $column_list }
default { set hidden_columns $column_list }
}
@@ -212,6 +212,7 @@ proc htmlDBout {db permission_list user {sort_col {}}} {
PasswordHash { }
UserHiddenColums { }
UserHiddenGroups { }
+ IdNum { }
GroupName { }
default {
lappend action_list changegrades "change grades" deletecolumn delete changecolumn "change column"