Subversion Repositories VORC

Rev

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

Rev 283 Rev 284
Line 47... Line 47...
47
}
47
}
Line 48... Line 48...
48
 
48
 
49
my ($announcement) = $dbh->selectrow_array ("select value from setting where setting.key = ?", undef, "ANNOUNCEMENT");
49
my ($announcement) = $dbh->selectrow_array ("select value from setting where setting.key = ?", undef, "ANNOUNCEMENT");
Line 50... Line 50...
50
push @announcements, $h->li ({ style => "padding-bottom:10px;" }, $announcement) if $announcement;
50
push @announcements, $h->li ({ style => "padding-bottom:10px;" }, $announcement) if $announcement;
51
 
51
 
52
#if ($user->{department}->{OFF} > 0) {
52
if ($user->{department}->{OFF} > 0) {
53
#  my @days = ("Thursday", "Friday", "Saturday");
53
  my @days = ("Thursday", "Friday", "Saturday");
54
#  my @dayschecked;
54
  my @dayschecked;
55
#	foreach my $day (@{$dbh->selectall_arrayref ("select dayofweek from v_shift where year(date) = year(now()) and RCid = ? and role = 'Officiating Huddle'", undef, $user->{RCid})}) {
55
	foreach my $day (@{$dbh->selectall_arrayref ("select dayofweek from v_shift where year(date) = year(now()) and RCid = ? and role = 'Officiating Huddle'", undef, $user->{RCid})}) {
56
#	  push @dayschecked, @{$day};
56
	  push @dayschecked, @{$day};
57
#	}
57
	}
58
#  
58
  
59
#  use tableViewer qw/inArray/;
59
  use tableViewer qw/inArray/;
60
#  push @announcements, $h->li ({ style => "padding-bottom:10px;" }, "Did you attend the Officiating Huddle on:"),
60
  push @announcements, $h->li ({ style => "padding-bottom:10px;" }, "Did you attend the Officiating Huddle on:"),
61
#    $h->form ({ action => "add_officiating_huddle_time.pl", target => "_blank" }, [
61
    $h->form ({ action => "add_officiating_huddle_time.pl", target => "_blank" }, [
62
#      map ({ inArray($_, \@dayschecked) ? $h->input ({ type => "checkbox", name => $_, checked => [] }).$_.$h->br : $h->input ({ type => "checkbox", name => $_ }).$_.$h->br } @days),
62
      map ({ inArray($_, \@dayschecked) ? $h->input ({ type => "checkbox", name => $_, checked => [] }).$_.$h->br : $h->input ({ type => "checkbox", name => $_ }).$_.$h->br } @days),
63
#      $h->input ({ type => "submit", value => scalar @dayschecked ? "Update my hours." : "Give me credit!" })
63
      $h->input ({ type => "submit", value => scalar @dayschecked ? "Update my hours." : "Give me credit!" })
Line 64... Line 64...
64
#    ]);
64
    ]);
65
#}
65
}
66
 
66
 
67
#if ($user->{department}->{OFF} > 1) {
67
if ($user->{department}->{OFF} > 1) {
68
#  my @days = ("Thursday", "Friday", "Saturday");
68
  my @days = ("Thursday", "Friday", "Saturday");
69
#  my @dayschecked;
69
  my @dayschecked;
70
#	foreach my $day (@{$dbh->selectall_arrayref ("select dayofweek from v_shift where year(date) = year(now()) and RCid = ? and role = 'Officiating Leads Huddle'", undef, $user->{RCid})}) {
70
	foreach my $day (@{$dbh->selectall_arrayref ("select dayofweek from v_shift where year(date) = year(now()) and RCid = ? and role = 'Officiating Leads Huddle'", undef, $user->{RCid})}) {
71
#	  push @dayschecked, @{$day};
71
	  push @dayschecked, @{$day};
72
#	}
72
	}
73
#  
73
  
74
#  use tableViewer qw/inArray/;
74
  use tableViewer qw/inArray/;
75
#  push @announcements, $h->li ({ style => "padding-bottom:10px;" }, "Did you attend the Officiating Leads Huddle on:"),
75
  push @announcements, $h->li ({ style => "padding-bottom:10px;" }, "Did you attend the Officiating Leads Huddle on:"),
76
#    $h->form ({ action => "add_officiating_leads_huddle_time.pl", target => "_blank" }, [
76
    $h->form ({ action => "add_officiating_leads_huddle_time.pl", target => "_blank" }, [
77
#      map ({ inArray($_, \@dayschecked) ? $h->input ({ type => "checkbox", name => $_, checked => [] }).$_.$h->br : $h->input ({ type => "checkbox", name => $_ }).$_.$h->br } @days),
77
      map ({ inArray($_, \@dayschecked) ? $h->input ({ type => "checkbox", name => $_, checked => [] }).$_.$h->br : $h->input ({ type => "checkbox", name => $_ }).$_.$h->br } @days),
Line 78... Line 78...
78
#      $h->input ({ type => "submit", value => scalar @dayschecked ? "Update my hours." : "Give me credit!" })
78
      $h->input ({ type => "submit", value => scalar @dayschecked ? "Update my hours." : "Give me credit!" })
Line 79... Line 79...
79
#    ]);
79
    ]);
80
#}
80
}