Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- my $boob = $c->model('Db::Boob');
- $c->session->{boobs} = [] unless ($c->session->{boobs});
- my $row;
- unless ($row = shift(@{$c->session->{boobs}})){
- my (@rows) = $boob->search(undef, {rows => 10, order_by => 'RANDOM()'});
- push(@{$c->session->{boobs}}, @rows);
- $row = shift(@{$c->session->{boobs}});
- }
- $c->stash( row => $row );
- $c->stash(content_class=>'index');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement