Author/speakers can link to member page

If author/speaker is a member's name (or short name, or alias),
a link to the members' page will be set.
This commit is contained in:
Stefan Schlott 2019-10-28 18:26:34 +01:00 committed by Stefan Schlott
parent f85edcc5f0
commit 306155b571
10 changed files with 39 additions and 9 deletions

View file

@ -8,7 +8,7 @@
<p>
<ul class="unstyled inline">
<li><i class="fas fa-calendar-alt"></i> <time itemprop="dateCreated" datetime="<%= @item[:created_at].strftime("%Y-%m-%d") %>"><%= @item[:created_at].strftime("%d.%m.%Y") %></time></li>
<% if @item[:author] %><li><i class="fas fa-pencil-alt"></i> <%= @item[:author] %></li><% end %>
<% if @item[:author] %><li><i class="fas fa-pencil-alt"></i> <%= member_link(@item[:author]) %></li><% end %>
<% if @item[:refers_to] %><li><i class="fas fa-cogs"></i> <a href="<%= @items[sanitize_path(@item[:refers_to])].path() %>"><%= @items[sanitize_path(@item[:refers_to])][:title] %></a></li><% end %>
<li><i class="fas fa-bookmark"></i> <a itemprop="url" href="<%= item.path() %>">Permalink</a></li>
</ul>