Profile Picture

Hi, I'm Sheeju Alex.

I'm a developer, living in Bangalore, India and this is my personal development blog. I plan to share my technical stuff here, long back but not so long back I used to share my technical and crazy stuff on Sheeju Alex, Blog Spot.

Shoot me an email if you'd like to be in touch.

Check out my Resume here

Sheeju Alex

JPList Perl Module and Server side JPList UI Demo

jPList is a flexible jQuery plugin for sorting, pagination and filtering of any HTML structure (DIVs, UL/LI, tables, etc). Get started at jplist.com

Data Sources

Server side rendering for JPLIst depends on the module used for parsing the JPList Request and based on the request applying the request parameters to appropriate DB table and columns.

Data Source Examples for PHP/ASP

Below URL shows example of using PHP/ASP as server side backend for rendering server side data.

https://jplist.com/datasourcesexamples/index

Data Source Examples for Perl/Catalyst MVC

Below URL shows example of using Catalyst/Perl as server side backend for rendering server side data.

https://jplistdemo-catalyst-perl.herokuapp.com/datasources

JPList Module

The latest version of JPList module is available on CPAN and Github

Any issues please report here

Integration with CGI

use CGI::Request;
use JPList;

$req = new CGI::Request;       # fetch and parse request

my $jplist = JPList->new
            ({
                dbh             => $dbh,
                db_table_name   => 'Items', 
                request_params  => $req->param('statuses')
            });

my $jp_resultset = $jplist->get_resultset();

$jp_resultset->{data};

$jp_resultset->{count};

Integration with Catalyst MVC

Add this below code in Catalyst Controller

use JPList;

my $jplist = JPList->new
            ({
                dbh             => $c->model('DB')->schema->storage->dbh,
                db_table_name   => 'Items', 
                request_params  => $c->request->body_params->{statuses}
            });

my $jp_resultset = $jplist->get_resultset();

$jp_resultset->{data};

$jp_resultset->{count};

Integration with Dancer MVC

Add this below code in Dancer Controller

use JPList;

my $jplist = JPList->new
            ({
                dbh             => $dbh,
                db_table_name   => 'Items', 
                request_params  => params->{statuses}
            });

my $jp_resultset = $jplist->get_resultset();

$jp_resultset->{data};

$jp_resultset->{count};

Links

https://metacpan.org/pod/JPList

https://github.com/sheeju/JPList

http://jplist.com

Datasources examples available on www.jplist.com

Perl Datasources examples deployed on www.heruko.com

comments powered by Disqus