[Dancer-users] Dancer::Plugin::SimpleCRUD - more features
gordon at cshl.edu
Tue Oct 18 00:39:56 CEST 2011
I've added couple of more features to make the awesome SimpleCRUD even more awesome (but hopefully still keeping it simple):
1. Add "sortable" feature: each column header becomes clickable, and allows the user to sort (ascending/descending) the results:
2. Add "paginate" feature: show only X number of results, and add "next/prev page" links.
Badly needed if using SimpleCRUD for large tables.
3. Make the search form select the last searched field by default:
4. Auto-focus keyboard input on the search field by default (but can be disabled by the user):
5. Add "downloadable" option, to download results as CSV/TXT/json/xml instead of showing as HTML.
You can experiment with these here:
The code for the above website is:
use Dancer ':syntax';
our $VERSION = '0.1';
record_title => "Gene",
prefix => "/genes",
db_table => "genes",
sortable => 1,
paginate => 300,
downloadable => 1,
editable => 0,
deletable => 0,
Comments are welcomed,
More information about the Dancer-users