消息信息显示

This commit is contained in:
ouyangxuhua 2015-08-20 12:41:53 +08:00
parent b256d0a24e
commit 84182171f5
1 changed files with 16 additions and 14 deletions

View File

@ -9,42 +9,44 @@
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "全部",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user} %></a></li>
<%# 课程相关消息 %>
<% unless @user_course_messages.nil? %>
<% unless @user_course_messages_count > 0 %>
<% if @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "作业消息",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'homework'} %></a></li>
<% end %>
<% unless @user_course_messages_count > 0 %>
<% if @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "课程讨论区",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'course_message'} %></a></li>
<% end %>
<% unless @user_course_messages_count > 0 %>
<% if @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "发布了课程通知",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'course_news'} %></a></li>
<% end %>
<% unless @user_course_messages_count > 0 %>
<% if @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "问卷调查",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'poll'} %></a></li>
<% end %>
<% unless @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "作品评阅",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'works_reviewers'} %></a></li>
<% if @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "作品评阅",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'works_reviewers'} %></a></li>
<% end %>
<% if @user_course_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "作品讨论",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'works_reply'} %></a></li>
<% end %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "作品讨论",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'works_reply'} %></a></li>
<% end %>
<%# 项目相关消息 %>
<% unless @user_forge_messages.nil? %>
<% unless @user_forge_messages_count > 0 %>
<% if @user_forge_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "指派给我",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'issue'} %></a></li>
<% end %>
<% unless @user_forge_messages_count > 0 %>
<% if @user_forge_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "更新了问题",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'issue_update'} %></a></li>
<% end %>
<% unless @user_forge_messages_count > 0 %>
<% if @user_forge_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "项目讨论区",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'forge_message'} %></a></li>
<% end %>
<% unless @user_forge_messages_count > 0 %>
<% if @user_forge_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "发布了新闻",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'forge_news'} %></a></li>
<% end %>
<% end %>
<%# 公共贴吧 %>
<% unless @user_forum_messages.nil? %>
<% unless @user_memo_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "发布了帖子",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'forum'} %></a></li>
<% unless @user_memo_messages.nil? %>
<% if @user_memo_messages_count > 0 %>
<li><a href="javascript:void(0);" class="resourcesGrey"><%= link_to "发布了xiang帖子",{:controller=> 'users', :action => 'user_messages', id: User.current.id, host: Setting.host_user, :type => 'forum'} %></a></li>
<% end %>
<% end %>
<%# 用户留言 %>