Changeset 266 for trunk/lib/Epoll/Controller
- Timestamp:
- 12/10/09 09:29:20 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/lib/Epoll/Controller/Admin.pm
r264 r266 129 129 ); 130 130 } 131 foreach my $bid ($ poll->list_ballot_needvalid) {131 foreach my $bid ($c->req->param('bsubvalid')) { 132 132 if (!$c->req->param($bid)) { 133 133 next; … … 156 156 } 157 157 158 sub ballotfilter : Private { 159 my ($self, $c) = @_; 160 161 my $poll = $c->model('Vote')->poll($c->stash->{voteid}); 162 $c->req->params->{ballotvalue} = 's:needvalid' 163 if (!$c->req->param('ballotvalue')); 164 165 for ($c->req->param('ballotvalue') || '') { 166 /^v:(.*)/ and $c->stash->{ballotfilter} = 167 [ $poll->ballot_by_value($1) ]; 168 /^s:invalid$/ and $c->stash->{ballotfilter} = 169 [ $poll->list_ballot_invalid ]; 170 /^s:valid$/ and $c->stash->{ballotfilter} = 171 [ $poll->list_ballot_valid ]; 172 /^s:needvalid$/ and $c->stash->{ballotfilter} = 173 [ $poll->list_ballot_needvalid ]; 174 } 175 } 176 158 177 sub auth : Private { 159 178 my ($self, $c) = @_; … … 259 278 260 279 $c->forward('auth') or return; 280 $c->forward('modify_poll'); 261 281 $c->stash->{page}{title} = $poll->info('label') . ': Administration: Validation'; 282 283 $c->forward('ballotfilter'); 262 284 } 263 285
Note: See TracChangeset
for help on using the changeset viewer.