Subversion Repositories VORC

Rev

Rev 89 | Rev 105 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 89 Rev 90
Line 105... Line 105...
105
  }
105
  }
Line 106... Line 106...
106
  
106
  
107
	# Shift Report: select dayofweek, count(RCid) as filled_shifts, count(*) - count(RCid) as open_shifts, count(*) as total_shifts from v_shift group by date order by date
107
	# Shift Report: select dayofweek, count(RCid) as filled_shifts, count(*) - count(RCid) as open_shifts, count(*) as total_shifts from v_shift group by date order by date
Line 108... Line 108...
108
}
108
}
109
 
109
 
110
my @sysadmins;
110
my (@sysadmins, @mvpcounts);
111
if ($LVL >= 5) {
111
if ($LVL >= 5) {
112
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/bulk_upload.pl" }, "Upload a CSV of Department Shifts"));
112
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/bulk_upload.pl" }, "Upload a CSV of Department Shifts"));
113
 	push @sysadmins, $h->li ($h->a ({ href=>"/schedule/shifts.pl" }, "Update department shift schedule"));
113
 	push @sysadmins, $h->li ($h->a ({ href=>"/schedule/shifts.pl" }, "Update department shift schedule"));
114
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/tickets.pl" }, "Manage MVP Ticket Matches"));
114
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/tickets.pl" }, "Manage MVP Ticket Matches"));
115
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/classes.pl" }, "Manage MVP Classes"));
115
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/classes.pl" }, "Manage MVP Classes"));
116
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/games.pl" }, "Manage Games"));
116
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/games.pl" }, "Manage Games"));
117
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/departments.pl" }, "Manage Department Settings"));
117
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/departments.pl" }, "Manage Department Settings"));
-
 
118
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/settings.pl" }, "System Settings"));
-
 
119
 	push @sysadmins, $h->li ($h->a ({ href=>"/schedule/volhours_report.pl?limit=All" }, "YEAR END VOLUNTEER HOURS REPORT"));
Line 118... Line 120...
118
  push @sysadmins, $h->li ($h->a ({ href=>"/schedule/settings.pl" }, "System Settings"));
120
 
119
 	push @sysadmins, $h->li ($h->a ({ href=>"/schedule/volhours_report.pl?limit=All" }, "YEAR END VOLUNTEER HOURS REPORT"));
121
 
120
 	
-
 
121
 	my ($signupcount) = $dbh->selectrow_array ("select sum(count) from v_class where year(date) = year(now())");
-
 
122
 	my ($mvpcount)    = $dbh->selectrow_array ("select count(*) from v_official where isnull(MVPid) = false");
122
 	
-
 
123
 	my ($unclaimed_tix) = $dbh->selectrow_array ("select count(*) from v_ticket where isnull(RCid) = 1");
-
 
124
 	my ($mvpcount)      = $dbh->selectrow_array ("select count(*) from v_ticket where isnull(RCid) = 0");
-
 
125
 	$mvpcount = 1 unless $mvpcount;
-
 
126
 	my $class_limit = getSetting ("MAX_CLASS_SIGNUP");
-
 
127
 	
Line -... Line 128...
-
 
128
  push @mvpcounts, $h->li ($mvpcount." MVP Tickets have been matched in VORC. ($unclaimed_tix remain unmatched.)");
-
 
129
  push @mvpcounts, $h->li ("They could (in theory) sign up for ".$mvpcount*$class_limit." class spots.");
-
 
130
  
-
 
131
 	
-
 
132
 	my ($signupcount, $total_class_count, $available_count) = $dbh->selectrow_array ("select sum(count), sum(capacity), sum(available) from v_class where year(date) = year(now())");
-
 
133
 	
-
 
134
 	push @mvpcounts, $h->li ($total_class_count." Total Class Spots");
123
 	my ($total_class_count)    = $dbh->selectrow_array ("select sum(capacity) from v_class");
135
 	push @mvpcounts, $h->li ($signupcount." Filled Class Spots (".sprintf("%.2f", ($signupcount / $total_class_count) * 100)."\%)");
124
 	
136
 	push @mvpcounts, $h->li ($available_count." Available Class Spots (".sprintf("%.2f", ($available_count / $total_class_count) * 100)."\%)");
Line 125... Line 137...
125
 	$mvpcount = 1 unless $mvpcount;
137
 	
126
 	
138
 	
127
 	push @sysadmins, $h->li ($mvpcount." MVP Passholders have signed up for ".$signupcount." spots (".sprintf("%.2f", ($signupcount / ($mvpcount*getSetting("MAX_CLASS_SIGNUP"))) * 100)."\% of allowable signups).");
139
# 	push @sysadmins, $h->li ($mvpcount." MVP Passholders have signed up for ".$signupcount." spots (".sprintf("%.2f", ($signupcount / ($mvpcount*getSetting("MAX_CLASS_SIGNUP"))) * 100)."\% of allowable signups).");
128
 	push @sysadmins, $h->li (sprintf("%.2f", ($signupcount / $total_class_count) * 100)."\% of total class spaces are filled.");
140
# 	push @sysadmins, $h->li (sprintf("%.2f", ($signupcount / $total_class_count) * 100)."\% of total class spaces are filled.");
Line 164... Line 176...
164
 
176
 
Line 165... Line 177...
165
print $h->div ({ class=>"index" }, [$h->p ({ class=>"heading" }, "Things you can do as a Manager:"), $h->ul ([ @managers ]) ]) if ($LVL > 2);
177
print $h->div ({ class=>"index" }, [$h->p ({ class=>"heading" }, "Things you can do as a Manager:"), $h->ul ([ @managers ]) ]) if ($LVL > 2);
Line -... Line 178...
-
 
178
 
-
 
179
print $h->div ({ class=>"index" }, [$h->p ({ class=>"heading" }, "Things you can do as a SysAdmin:"), $h->ul ([ @sysadmins ]) ]) if ($LVL >= 5);
166
 
180
 
Line 167... Line 181...
167
print $h->div ({ class=>"index" }, [$h->p ({ class=>"heading" }, "Things you can do as a SysAdmin:"), $h->ul ([ @sysadmins ]) ]) if ($LVL >= 5);
181
print $h->div ({ class=>"index" }, [$h->p ({ class=>"heading" }, "MVP Class and Ticket Status:"), $h->ul ([ @mvpcounts ]) ]) if (scalar @mvpcounts);
Line 168... Line 182...
168
 
182