">
<%= @count %>
|
<%=news.course_id %>
|
<%=link_to(news.course.name, course_path(news.course)) %>
|
<%=link_to(news.course.try(:teacher).try(:realname), user_path(news.course.teacher)) %>
|
<%= news.try(:author)%><% else %><%=news.try(:author).try(:realname) %><% end %>'>
<% if news.try(:author).try(:realname) == ' '%>
<%= link_to(news.try(:author), user_path(news.author)) %>
<% else %>
<%= link_to(news.try(:author).try(:realname), user_path(news.author)) %>
<% end %>
|
<%= format_date(news.created_on) %>
|
<%= link_to(news.title, news_path(news)) %>
|
<%= link_to(news.comments_count, news_path(news)) %>
|
<% end %>