shows add related content link if user is logged
This commit is contained in:
@@ -4,11 +4,13 @@
|
|||||||
<h2 class="inline-block">
|
<h2 class="inline-block">
|
||||||
<%= t("related_content.title") %> <span>(<%= relationable.relationed_contents.count %>)</span>
|
<%= t("related_content.title") %> <span>(<%= relationable.relationed_contents.count %>)</span>
|
||||||
</h2>
|
</h2>
|
||||||
|
<% if current_user %>
|
||||||
<a>
|
<a>
|
||||||
<button type="button" data-toggle="related_content" class="add-related-content" id="add-related-content">
|
<button type="button" data-toggle="related_content" class="add-related-content" id="add-related-content">
|
||||||
<%= t("related_content.add") %>
|
<%= t("related_content.add") %>
|
||||||
</button>
|
</button>
|
||||||
</a>
|
</a>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<%= render 'relationable/form', relationable: relationable %>
|
<%= render 'relationable/form', relationable: relationable %>
|
||||||
|
|||||||
Reference in New Issue
Block a user