游客身份,隐藏讨论区二级栏目新建帖子的入口

This commit is contained in:
cxt 2016-10-24 14:10:37 +08:00
parent fcb1d4d115
commit c2a7ec4fc7
3 changed files with 7 additions and 3 deletions

View File

@ -4,7 +4,9 @@
<li id="board_children_<%=board.id %>">
<% count = board ? (board.topics.count + Message.where("board_id =? and parent_id is not ?", board.id, nil).count) : 0 %>
<a href="<%=course_boards_path(@course, :board_id =>board.id) %>"><font class="hidden dis" style="max-width: 120px;"><%=board.name %></font><span style="vertical-align: top;"><%=count %></span></a>
<% if User.current.logged? %>
<%= link_to( "",course_boards_path(@course, :board_id =>board.id, :flag => true, :is_new => 1), :class => 'sy_class_add', :title =>"#{l(:label_message_new)}") %>
<% end %>
</li>
<% end %>
</ul>

View File

@ -4,7 +4,9 @@
<li id="course_group_<%=group.id %>">
<% count = group.members.count %>
<a href="<%= group_member_course_path(course, :group_id => group.id) %>"><font class="hidden dis" style="max-width: 120px;"><%=group.name %></font><span style="vertical-align: top;"><%=count %></span></a>
<% if is_teacher %>
<%= link_to '', search_not_group_member_course_path(@course,:group_id => group.id),:remote => true, :class => "sy_class_add", :title => "添加成员" %>
<% end %>
</li>
<% end %>
</ul>

View File

@ -121,7 +121,7 @@
<!--<a href="javascript:void(0);" class="sy_class_add"></a>-->
</li>
<div id="group_children_list">
<%= render :partial => 'layouts/group_children_list', :locals => {:course => @course} %>
<%= render :partial => 'layouts/group_children_list', :locals => {:course => @course, :is_teacher => is_teacher} %>
</div>
<% end %>
<% statistics_count = 0 %>