Nils Diewald | a944fab | 2015-04-08 21:02:04 +0000 | [diff] [blame^] | 1 | % my $res = stash('search.resource'); |
| 2 | % if (ref($res) eq 'ARRAY') { |
| 3 | |
Nils Diewald | 2329e1d | 2014-06-12 16:07:57 +0000 | [diff] [blame] | 4 | <h2>Virtual Collections</h2> |
| 5 | <ul> |
Nils Diewald | a944fab | 2015-04-08 21:02:04 +0000 | [diff] [blame^] | 6 | % foreach my $vc (@$res) { |
Nils Diewald | 44a7278 | 2014-06-20 16:03:21 +0000 | [diff] [blame] | 7 | <li class="active" title="<%= $vc->{description} // '' %>"><h3><%= $vc->{name} %></h3> |
Nils Diewald | 4e9fbcb | 2014-07-15 11:45:09 +0000 | [diff] [blame] | 8 | % my $stats = $vc->{statistics}; |
Nils Diewald | 44a7278 | 2014-06-20 16:03:21 +0000 | [diff] [blame] | 9 | <dl class="info"> |
Nils Diewald | 13bad6a | 2014-07-18 16:44:51 +0000 | [diff] [blame] | 10 | <dt>Texts</dt> <dd><%= commify($stats->{documents} // $stats->{texts}) %></dd> |
Nils Diewald | 44a7278 | 2014-06-20 16:03:21 +0000 | [diff] [blame] | 11 | <dt>Paragraphs</dt> <dd><%= commify $stats->{paragraphs} %></dd> |
| 12 | <dt>Sentences</dt> <dd><%= commify $stats->{sentences} %></dd> |
| 13 | <dt>Tokens</dt> <dd><%= commify $stats->{tokens} %></dd> |
| 14 | </dl> |
| 15 | </li> |
Nils Diewald | 2329e1d | 2014-06-12 16:07:57 +0000 | [diff] [blame] | 16 | % }; |
| 17 | </ul> |
Nils Diewald | a944fab | 2015-04-08 21:02:04 +0000 | [diff] [blame^] | 18 | % } |
| 19 | |
| 20 | |
Nils Diewald | 2fe12e1 | 2015-03-06 16:47:06 +0000 | [diff] [blame] | 21 | % if (kalamar_test_port()) { |
| 22 | <p style="font-size: 9pt; padding-left: 1em">Index port: <%= $c->url_for($c->config('Kalamar')->{'api-0.1'})->port %></p> |
Nils Diewald | 3663013 | 2014-11-07 03:52:00 +0000 | [diff] [blame] | 23 | % }; |