Changeset 82 for trunk


Ignore:
Timestamp:
03/19/09 13:32:53 (15 years ago)
Author:
nanardon
Message:
  • fix request->param usage, fixing nul ballot view
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/Vote/Controller/Ballot.pm

    r53 r82  
    8080        lc($_) 
    8181    } ($c->req->param('fsbal')) ]; 
     82    $c->request->parameters->{fsbal} = $c->stash->{fsbal}; 
    8283 
    8384    my @sbalval = grep { $_ } map { $choices{$_} } $c->req->param('sbal'); 
     
    8586    if (scalar(@sbalval) + scalar(@{$c->stash->{fsbal} || []}) 
    8687        > $vote->vote_info($id)->{choice_count}) { 
    87         $c->req->param('ballot', ''); 
     88        $c->req->parameters->{'ballot'} = ''; 
    8889        $c->stash->{vote_error} = 'Seulement ' . 
    8990            $vote->vote_info($id)->{choice_count} . ' choix possible'; 
     
    9495        $uniq{lc($_)} = 1 foreach(@sbalval, @{$c->stash->{fsbal} || []}); 
    9596        if (scalar(keys %uniq) != scalar(@sbalval) + scalar(@{$c->stash->{fsbal} || []})) { 
    96             $c->req->param('ballot', ''); 
     97            $c->req->parameters->{'ballot'} = ''; 
    9798            $c->stash->{vote_error} = 'Une valeur est en double'; 
    9899            return; 
Note: See TracChangeset for help on using the changeset viewer.