2016-10-19 09:57:17 +08:00
|
|
|
<div class="homepagePostReplyPublisher">
|
|
|
|
<%= link_to comment.creator_user.show_name, user_url_in_org(comment.creator_user.id), :class => "newsBlue mr10 f14" %>
|
|
|
|
<%= time_from_now(comment.respond_to?(:created_on) ? comment.created_on : comment.created_at) %>
|
|
|
|
</div>
|
|
|
|
<% if !comment.parent.nil? && !comment.parent.parent.nil? %>
|
|
|
|
<% parents_rely = [] %>
|
|
|
|
<% parents_rely = get_reply_parents_no_root parents_rely, comment %>
|
|
|
|
<% length = parents_rely.length %>
|
|
|
|
<div id="comment_reply_<%=comment.id %>">
|
|
|
|
<% if length <= 3 %>
|
2016-10-24 11:26:12 +08:00
|
|
|
<%=render :partial => 'projects/journal_comment_reply', :locals => {:comment => comment.parent} %>
|
2016-10-19 09:57:17 +08:00
|
|
|
<% else %>
|
|
|
|
<div class="orig_cont clearfix">
|
|
|
|
<div class="orig_cont clearfix">
|
|
|
|
<div>
|
2016-10-24 11:26:12 +08:00
|
|
|
<%=render :partial => 'projects/journal_comment_reply', :locals => {:comment => parents_rely[length - 1]} %>
|
2016-10-19 09:57:17 +08:00
|
|
|
</div>
|
2016-10-24 11:26:12 +08:00
|
|
|
<%=render :partial => 'projects/comment_reply_detail', :locals => {:comment => parents_rely[length - 2]} %>
|
2016-10-19 09:57:17 +08:00
|
|
|
</div>
|
|
|
|
<div class="orig_cont_hide clearfix">
|
|
|
|
<span class="orig_icon" >↓ </span>
|
|
|
|
<span class="orig_icon" style="display:none;" > ↑</span>
|
|
|
|
<%= link_to '点击展开隐藏楼层', show_all_replies_users_path(:comment => comment, :type => comment.class),:remote=>true %>
|
|
|
|
</div>
|
2016-10-24 11:26:12 +08:00
|
|
|
<%=render :partial => 'projects/comment_reply_detail', :locals => {:comment => parents_rely[0]} %>
|
2016-10-19 09:57:17 +08:00
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
<% end %>
|