|
|
|
@ -503,4 +503,64 @@
|
|
|
|
|
<li class="homepageNewsTime fl"><%= time_tag(ma.created_at).html_safe %> </li>
|
|
|
|
|
</ul>
|
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
<!--被老师拉入课程-->
|
|
|
|
|
<% if ma.course_message_type == "JoinCourse" %>
|
|
|
|
|
<ul class="homepageNewsList fl">
|
|
|
|
|
<li class="homepageNewsPortrait fl">
|
|
|
|
|
<a href="javascript:void(0);"><%=link_to image_tag(url_to_avatar(User.find(ma.course_message_id)), :width => "30", :height => "30"), user_path(ma.course_message_id) %></a>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="homepageNewsPubType fl">
|
|
|
|
|
<%=link_to User.find(ma.course_message_id), user_path(User.find(ma.course_message_id)), :class => "newsBlue homepageNewsPublisher" %>
|
|
|
|
|
<span class="<%= ma.viewed == 0 ? "homepageNewsTypeNotRead fl" : "homepageNewsType fl" %>">将您加入了课程:</span>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="homepageNewsContent fl"><a href="javascript:void(0);" class="newsGrey">
|
|
|
|
|
<%= link_to ma.course.name, course_member_path(ma.course), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
|
|
|
|
:onmouseover => "message_titile_show($(this),event)",
|
|
|
|
|
:onmouseout => "message_titile_hide($(this))" %></a>
|
|
|
|
|
</li>
|
|
|
|
|
<div style="display: none" class="message_title_red system_message_style">
|
|
|
|
|
<% if ma.course.is_public? || User.current.member_of_course?(ma.course) || User.current.admin? %>
|
|
|
|
|
<p>课程名称:<%= ma.course.name %>(<%= ma.course.time.to_s + '年'+ ma.course.term %>)</p>
|
|
|
|
|
<p>课程描述:<%= ma.course.description.blank? ? '无':ma.course.description %></p>
|
|
|
|
|
<p>课时总数:<%= ma.course.class_period %></p>
|
|
|
|
|
<% else %>
|
|
|
|
|
<p>
|
|
|
|
|
您已经被移出该私有课程,非课程成员没有权限访问私有课程
|
|
|
|
|
</p>
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
<li class="homepageNewsTime fl"><%= time_tag(ma.created_at).html_safe %> </li>
|
|
|
|
|
</ul>
|
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
<!-被老师移出课程-->
|
|
|
|
|
<% if ma.course_message_type == "RemoveFromCourse" %>
|
|
|
|
|
<ul class="homepageNewsList fl">
|
|
|
|
|
<li class="homepageNewsPortrait fl">
|
|
|
|
|
<a href="javascript:void(0);"><%=link_to image_tag(url_to_avatar(User.find(ma.course_message_id)), :width => "30", :height => "30"), user_path(ma.course_message_id) %></a>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="homepageNewsPubType fl">
|
|
|
|
|
<%=link_to User.find(ma.course_message_id), user_path(User.find(ma.course_message_id)), :class => "newsBlue homepageNewsPublisher" %>
|
|
|
|
|
<span class="<%= ma.viewed == 0 ? "homepageNewsTypeNotRead fl" : "homepageNewsType fl" %>">将您移出了课程:</span>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="homepageNewsContent fl"><a href="javascript:void(0);" class="newsGrey">
|
|
|
|
|
<%= link_to ma.course.name, member_course_path(ma.course), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
|
|
|
|
:onmouseover => "message_titile_show($(this),event)",
|
|
|
|
|
:onmouseout => "message_titile_hide($(this))" %></a>
|
|
|
|
|
</li>
|
|
|
|
|
<div style="display: none" class="message_title_red system_message_style">
|
|
|
|
|
<% if ma.course.is_public? || User.current.member_of?(ma.course) || User.current.admin? %>
|
|
|
|
|
<p>课程名称:<%= ma.course.name %>(<%= ma.course.time.to_s + '年'+ ma.course.term %>)</p>
|
|
|
|
|
<p>课程描述:<%= ma.course.description.blank? ? '无' : ma.course.description %></p>
|
|
|
|
|
<p>学时总数:<%= ma.course.class_period %></p>
|
|
|
|
|
<% else %>
|
|
|
|
|
<p>
|
|
|
|
|
您已经被移出该私有课程,非课程成员没有权限访问私有课程
|
|
|
|
|
</p>
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
<li class="homepageNewsTime fl"><%= time_tag(ma.created_at).html_safe %> </li>
|
|
|
|
|
</ul>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end %>
|