remove links that are not usable by anon users, fixes #977
This commit is contained in:
@@ -1,11 +1,15 @@
|
||||
<% content_for(:secondary_links) do %>
|
||||
<menu>
|
||||
<li><%= link_to "Listing", forum_topics_path %></li>
|
||||
<li><%= link_to "New", new_forum_topic_path %></li>
|
||||
|
||||
<% if CurrentUser.is_member? %>
|
||||
<li><%= link_to "New", new_forum_topic_path %></li>
|
||||
<li><%= link_to "Mark all as read", mark_all_as_read_forum_topics_path, :method => :post %></li>
|
||||
<% end %>
|
||||
|
||||
<li><%= link_to "Search", search_forum_posts_path %></li>
|
||||
<li><%= link_to "Mark all as read", mark_all_as_read_forum_topics_path, :method => :post %></li>
|
||||
<li><%= link_to "Help", wiki_pages_path(:title => "help:forum") %></li>
|
||||
<% if @forum_topic && !@forum_topic.new_record? %>
|
||||
<% if CurrentUser.is_member? && @forum_topic && !@forum_topic.new_record? %>
|
||||
<li>|</li>
|
||||
<li><%= link_to "Reply", new_forum_post_path(:topic_id => @forum_topic.id) %></li>
|
||||
<% if !@forum_topic.new_record? && @forum_topic.editable_by?(CurrentUser.user) %>
|
||||
|
||||
@@ -15,11 +15,13 @@
|
||||
|
||||
<%= render "forum_posts/listing", :forum_posts => @forum_posts %>
|
||||
|
||||
<p><%= link_to "Reply »".html_safe, new_forum_post_path(:topic_id => @forum_topic.id), :id => "new-response-link" %></p>
|
||||
<% if CurrentUser.is_member? %>
|
||||
<p><%= link_to "Reply »".html_safe, new_forum_post_path(:topic_id => @forum_topic.id), :id => "new-response-link" %></p>
|
||||
|
||||
<div style="display: none;" id="topic-response">
|
||||
<%= render "forum_posts/form", :forum_post => ForumPost.new(:topic_id => @forum_topic.id) %>
|
||||
</div>
|
||||
<div style="display: none;" id="topic-response">
|
||||
<%= render "forum_posts/form", :forum_post => ForumPost.new(:topic_id => @forum_topic.id) %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<%= numbered_paginator(@forum_posts) %>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user