Subversion Repositories PEEPS

Rev

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

Rev 34 Rev 36
Line 134... Line 134...
134
print $h->open ("form", { action=>url, method=>'POST', name=>'UserRoleForm', id=>'UserForm'  });
134
print $h->open ("form", { action=>url, method=>'POST', name=>'UserRoleForm', id=>'UserForm'  });
135
print $h->input ({ type=>"hidden", name=>"person_id", value=>$person_id}),
135
print $h->input ({ type=>"hidden", name=>"person_id", value=>$person_id}),
136
      $h->input ({ type=>"hidden", name=>"league_id", value=>$league_id});
136
      $h->input ({ type=>"hidden", name=>"league_id", value=>$league_id});
Line 137... Line 137...
137
 
137
 
-
 
138
my @leagueroles = ($h->div ({ class=>"rTableRow" },[ $h->div ({ class=>"rTableHead", style=>"font-size: smaller;" }, "Role".' '.$h->input ({type=>"submit", name=>"Add", value=>"Add"}),  "Change" ) ]));
138
my @leagueroles = ($h->div ({ class=>"rTableRow" },[ $h->div ({ class=>"rTableHead", style=>"font-size: smaller;" }, "Role".' '.$h->input ({type=>"submit", name=>"Add", value=>"Add"}),  "Change" ) ]));
139
 
139
push @leagueroles, map { $h->div ({ class=>"rTableRow shaded" },
140
push @leagueroles, map { $h->div ({ class=>"rTableRow shaded" },
140
                         [ $h->div ({ class=>"rTableCellr".($_->[1] eq "Pending" ? " highlighted" : ""), style=>"font-size: smaller;".($_->[1] eq "Pending" ? " font-style: italic;" : "") },
141
                         [ $h->div ({ class=>"rTableCellr".($_->[1] eq "Pending" ? " highlighted" : ""), style=>"font-size: smaller;".($_->[1] eq "Pending" ? " font-style: italic;" : "") },
Line 141... Line 142...
141
                           $_->[1], [ $h->input ({type=>"submit", name=>"Delete", value=>"Delete", onClick=>"this.value=$_->[0]"}) ] ) ]) } @roles; # Change button -> , $h->input ({type=>"submit", name=>"Change", value=>"Change", onClick=>"this.value=$_->[0]"})
142
                           $_->[1], [ $h->input ({type=>"submit", name=>"Delete", value=>"Delete", onClick=>"this.value=$_->[0]"}) ] ) ]) } @roles; # Change button -> , $h->input ({type=>"submit", name=>"Change", value=>"Change", onClick=>"this.value=$_->[0]"})
Line 147... Line 148...
147
                       [ $h->div ({ class=>"rTableCellr"}, $h->select ({name=>"newrole"}, [ map { $h->option ($_) } @allowed_roles ]), $h->input ({type=>"submit", name=>"savenewrole", value=>"Save"}).' '.$h->button ("Cancel")) ]);
148
                       [ $h->div ({ class=>"rTableCellr"}, $h->select ({name=>"newrole"}, [ map { $h->option ($_) } @allowed_roles ]), $h->input ({type=>"submit", name=>"savenewrole", value=>"Save"}).' '.$h->button ("Cancel")) ]);
148
}
149
}
Line 149... Line 150...
149
 
150
 
Line -... Line 151...
-
 
151
print $h->ul ([@leagueroles]);
-
 
152
 
-
 
153
use tableViewer qw(inArray);
-
 
154
if (inArray ("Pending", [values %rolename])) {
-
 
155
  print $h->p ($h->div ({class=>"hint"}, "To accept a Pending member request, Add them to an appropriate role for your league."));
-
 
156
  
150
print $h->ul ([@leagueroles]);
157
}
Line 151... Line 158...
151
 
158
 
Line 152... Line 159...
152
print $h->ul ($h->input ({type=>"button", onClick=>"window.location.href='view_user?person_id=$person_id'", value=>"Back"}));
159
print $h->ul ($h->input ({type=>"button", onClick=>"window.location.href='view_user?person_id=$person_id'", value=>"Back"}));