课程动态
course activities
<% @course_acts_homework.each do |act| %>
<% if act.container_type == 'Course' %>
<% case act.org_act_type.to_s %>
<% when 'HomeworkCommon' %>
<%= render :partial => 'org_new_course_homework', :locals => {:activity => HomeworkCommon.find(act.org_act_id),:user_activity_id =>act.id,:course_activity => 0} %>
<% when 'News' %>
<%= render :partial => 'org_new_course_news', :locals => {:activity => News.find(act.org_act_id),:user_activity_id =>act.id} %>
<% when 'Message'%>
<%= render :partial => 'org_new_course_message', :locals => {:activity => Message.find(act.org_act_id),:user_activity_id =>act.id} %>
<% when 'Poll' %>
<%= render :partial => 'org_new_course_poll', :locals => {:activity => Poll.find(act.org_act_id), :user_activity_id => act.id} %>
<% when 'Course'%>
<%= render :partial => 'org_new_course_create', :locals => {:activity => Course.find(act.org_act_id), :user_activity_id => act.id} %>
<% end %>
<% end %>
<% end %>
More
<% @course_acts_message.each do |act| %>
<% if act.container_type == 'Course' %>
<% case act.org_act_type.to_s %>
<% when 'HomeworkCommon' %>
<%= render :partial => 'org_new_course_homework', :locals => {:activity => HomeworkCommon.find(act.org_act_id),:user_activity_id =>act.id,:course_activity => 0} %>
<% when 'News' %>
<%= render :partial => 'org_new_course_news', :locals => {:activity => News.find(act.org_act_id),:user_activity_id =>act.id} %>
<% when 'Message'%>
<%= render :partial => 'org_new_course_message', :locals => {:activity => Message.find(act.org_act_id),:user_activity_id =>act.id} %>
<% when 'Poll' %>
<%= render :partial => 'org_new_course_poll', :locals => {:activity => Poll.find(act.org_act_id), :user_activity_id => act.id} %>
<% when 'Course'%>
<%= render :partial => 'org_new_course_create', :locals => {:activity => Course.find(act.org_act_id), :user_activity_id => act.id} %>
<% end %>
<% end %>
<% end %>
More