backend: include links to tags in media#show
This commit is contained in:
parent
ac9054f918
commit
0a20d7e9f7
@ -14,7 +14,11 @@
|
|||||||
<dt>Content-Type</dt>
|
<dt>Content-Type</dt>
|
||||||
<dd><%= $media->{content_type} %></dd>
|
<dd><%= $media->{content_type} %></dd>
|
||||||
<dt>Tags</dt>
|
<dt>Tags</dt>
|
||||||
<% for my $tag ($media->{tags}->@*) { %>
|
% if ($media->{tags}->@* == 0) {
|
||||||
<dd><%= link_to $tag => url_for("tag_show", tag_id_or_name => $tag) %></dd>
|
<dd>None yet.</dd>
|
||||||
<% } %>
|
% } else {
|
||||||
|
<dd><%= c($media->{tags}->@*)
|
||||||
|
->map(sub { link_to $_ => url_for("tag_show", tag_id_or_name => $_) })
|
||||||
|
->join(", ") %>.</dd>
|
||||||
|
% }
|
||||||
</dl>
|
</dl>
|
||||||
|
Loading…
Reference in New Issue
Block a user