% my $a = shift;
%% layout 'blog', title => 'Blog/<%= ucfirst $a->{t} %>';
%% my @columns = qw(<%= join(' ', @{$a->{columns}}) %>); #table columns
%%= link_to 'New record in table "<%= $a->{t} %>"' => 'create_<%= $a->{t} %>'
<table>
    <thead>
        <tr>
    %% for my $column (@columns) {
            <th><%%= uc($column) %></th>
    %% }
        </tr>
    </thead>
    <tbody>
%% for my $item (@$<%= $a->{t} %>) {
        <tr>
            <td><%%= link_to $item->{id} => show_<%= $a->{t} %> => {id => $item->{id}} %></td>
    %% for my $column (@columns[1 .. $#columns]) {
            <td><%%= $item->{$column} %></td>
    %% }
        </tr>
%% }
    </tbody>
</table>