No description, website, or topics provided.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib/Teng/Plugin
t
xt
.gitignore
Changes
MANIFEST.SKIP
Makefile.PL
README
README.pod

README.pod

NAME

Teng::Plugin::SearchBySQLWithPager - Teng plugin to add 'search_by_sql_with_pager' method

SYNOPSIS

package MyApp::DB;
use parent 'Teng';
__PACKAGE__->load_plugin('SearchBySQLWithPager');

package main;
my $db = MyApp::DB->new(...);
my $page = $c->req->param('page') || 1;
my ($rows, $pager) = $db->search_by_sql_with_pager(
    'SELECT id, name, type FROM user WHERE type = ?',
    [ 3 ],
    'user',
    { page => $page, rows => 5 },
);

DESCRIPTION

Teng::Plugin::SearchBySQLWithPager is

AUTHOR

Yuki Ibe <yibe at yibe dot org>

SEE ALSO

Teng, Teng::Plugin::Pager

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.