[Jifty-commit] r6791 - jifty/trunk/lib/Jifty/View/Declare
Jifty commits
jifty-commit at lists.jifty.org
Thu Apr 16 17:01:20 EDT 2009
Author: sartak
Date: Thu Apr 16 17:01:20 2009
New Revision: 6791
Modified:
jifty/trunk/lib/Jifty/View/Declare/CRUD.pm
Log:
Make no_items_found a region
Modified: jifty/trunk/lib/Jifty/View/Declare/CRUD.pm
==============================================================================
--- jifty/trunk/lib/Jifty/View/Declare/CRUD.pm (original)
+++ jifty/trunk/lib/Jifty/View/Declare/CRUD.pm Thu Apr 16 17:01:20 2009
@@ -683,7 +683,7 @@
=cut
-private template 'no_items_found' => sub {
+template 'no_items_found' => sub {
div {
{ class is 'no_items' };
outs( _("No items found.") );
@@ -704,8 +704,12 @@
my $object_type = $self->object_type;
$collection->_do_search(); # we're going to need the results.
# XXX TODO, should use a real API to force the search
+
if ( $collection->count == 0 ) {
- show('./no_items_found');
+ render_region(
+ name => 'no_items_found',
+ path => $self->fragment_for('no_items_found'),
+ );
}
my $i = 0;
More information about the Jifty-commit
mailing list