2015-08-28 11:55:34 +08:00
|
|
|
|
<div class="resources mt10">
|
|
|
|
|
<div class="homepagePostBrief mt10" >
|
2015-08-21 16:07:18 +08:00
|
|
|
|
<div class="homepagePostPortrait">
|
2015-08-21 17:26:52 +08:00
|
|
|
|
<%= link_to image_tag(url_to_avatar(activity.author), :width => "90", :height => "90"), user_path(activity.author_id), :alt => "用户头像" %>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
</div>
|
|
|
|
|
<div class="homepagePostDes">
|
2015-08-28 11:55:34 +08:00
|
|
|
|
<div class="homepagePostTo mb12" style="word-break:break-all;">
|
2015-08-21 17:26:52 +08:00
|
|
|
|
<% if @ctivity.try(:author).try(:realname) == ' ' %>
|
|
|
|
|
<%= link_to activity.try(:author), user_path(activity.author_id), :class => "newsBlue mr15" %>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
<% else %>
|
2015-08-21 17:26:52 +08:00
|
|
|
|
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
<% end %> TO
|
2015-08-25 09:50:36 +08:00
|
|
|
|
<%= link_to activity.course.name.to_s+"(课程名称)", course_path(activity.course), :class => "newsBlue ml15", :style=>"word-break:break-all" %>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
</div>
|
2015-08-28 11:55:34 +08:00
|
|
|
|
<div class="homepagePostTitle mb12" style="word-break:break-all;">
|
2015-08-25 09:50:36 +08:00
|
|
|
|
<%=link_to activity.title.to_s+"(通知标题)", news_path(activity), :class=> "postGrey", :style=>"word-break:break-all" %>
|
|
|
|
|
</div>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
<div class="homepagePostSubmitContainer">
|
2015-08-21 17:26:52 +08:00
|
|
|
|
<div class="homepagePostDeadline">发布时间:<%= format_date(activity.created_on) %></div>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
</div>
|
2015-08-25 09:50:36 +08:00
|
|
|
|
<div class="homepagePostIntro" style="word-break:break-all">(通知描述)<%= activity.description.html_safe %></div>
|
2015-08-21 16:07:18 +08:00
|
|
|
|
<div class="homepagePostSetting" id="act-<%=user_activity.id %>" style="visibility: hidden">
|
|
|
|
|
<ul>
|
|
|
|
|
<li class="homepagePostSettingIcon">
|
|
|
|
|
<ul class="homepagePostSettiongText">
|
|
|
|
|
<li><a href="javascript:void(0);" class="postOptionLink">编辑</a></li>
|
|
|
|
|
<li><a href="javascript:void(0);" class="postOptionLink">复制</a></li>
|
|
|
|
|
<li><a href="javascript:void(0);" class="postOptionLink">删除</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
</div>
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<!--<div class="homepagePostReply">
|
2015-08-24 17:45:09 +08:00
|
|
|
|
<div class="homepagePostReplyBanner">
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<div class="homepagePostReplyBannerCount">回复(<%#=activity.comments_count %>)</div>
|
2015-08-25 15:35:45 +08:00
|
|
|
|
<div class="homepagePostReplyBannerTime"><%#=format_date(activity.updated_on)%></div>
|
2015-08-24 17:45:09 +08:00
|
|
|
|
<div class="homepagePostReplyBannerMore"><a href="javascript:void(0);" class="replyGrey">点击展开更多回复</a>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<%#= render :partial => 'course_news_reply',:locals => { :contest => @contest, :journals => @jour, :state => false}%>
|
|
|
|
|
|
|
|
|
|
<div class="homepagePostReplyInputContainer">
|
|
|
|
|
<%#= form_tag({:controller => 'comments', :action => 'create', :id => activity}, :id => "add_reply_form") do %>
|
|
|
|
|
<textarea id="new_reply" class="homepagePostReplyInput" placeholder="请输入回复"></textarea>
|
|
|
|
|
<div class="homepagePostReplyCancel">
|
|
|
|
|
<a href="javascript:void(0);" class="postReplyCancel" onclick="$('#new_reply').value('');">取消</a>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="homepagePostReplySubmit">
|
|
|
|
|
<a href="javascript:void(0);" class="postReplySubmit" onclick="$('#add_reply_form').submit();">发送</a>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<%# end %>
|
|
|
|
|
</div>
|
|
|
|
|
<%# activity.comments.reorder("created_on desc").each do |comment| unless activity.comments.nil?%>
|
2015-08-25 09:50:36 +08:00
|
|
|
|
<div class="homepagePostReplyContainer">
|
|
|
|
|
<div class="homepagePostReplyPortrait">
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<%#= link_to image_tag(url_to_avatar(comment.author), :width => "45", :height => "45"), user_path(comment.author_id), :alt => "用户头像" %>
|
2015-08-25 09:50:36 +08:00
|
|
|
|
</div>
|
|
|
|
|
<div class="homepagePostReplyDes">
|
|
|
|
|
<div class="homepagePostReplyPublisher">
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<%# if comment.try(:author).try(:realname) == ' ' %>
|
|
|
|
|
<%#= link_to comment.try(:author), user_path(comment.author_id), :class => "newsBlue mr10 f14" %>
|
|
|
|
|
<%# else %>
|
|
|
|
|
<%#= link_to comment.try(:author).try(:realname), user_path(comment.author_id), :class => "newsBlue mr10 f14" %>
|
|
|
|
|
<%# end %>
|
|
|
|
|
<%#=format_date(comment.created_on)%>
|
|
|
|
|
<%#= link_to_if_authorized_course l(:button_delete), {:controller => 'comments', :action => 'destroy', :id => activity, :comment_id => comment},
|
|
|
|
|
:data => {:confirm => l(:text_are_you_sure)}, :method => :delete, :title => l(:button_delete) %>
|
|
|
|
|
<!–<a href="javascript:void(0);" class="replyGrey fr ml10">删除</a>–>
|
2015-08-25 09:50:36 +08:00
|
|
|
|
</div>
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<div class="homepagePostReplyContent" style="white-space: nowrap;overflow: hidden;text-overflow: ellipsis;" title="<%#= comment.comments.html_safe %>"><%#= comment.comments.html_safe %></div>
|
2015-08-25 09:50:36 +08:00
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
</div>
|
2015-08-26 15:24:57 +08:00
|
|
|
|
<%# end %>
|
|
|
|
|
<%# end %>
|
|
|
|
|
</div>-->
|
2015-08-21 16:07:18 +08:00
|
|
|
|
</div>
|