added faceted links
[MojoFacets.git] / templates / data / items / list.html.ep
1
2 % foreach my $row ( @$sorted ) {
3 <ul>
4 % foreach my $col ( @$columns ) {
5 %  next unless defined $row->{$col};
6 %  my $v = ref $row->{$col} eq 'ARRAY' ? join(', ',@{ $row->{$col} }) : $row->{$col};
7 %  next if $v =~ m/^\s*$/;
8 <li>
9 % my $count = defined $filters->{$col} ? $#{ $filters->{$col} } + 1 : '';
10 <a class="facet" title="<%= $count %>" href="<%= url_for( action => 'facet' )->query( name => $col, all => 0 ) %>"><%= $col %></a>
11 <%= $v %>
12 % }
13 </ul>
14 % }
15