<% comments.each do |comment| %>
  • <%= link_to image_tag(url_to_avatar(comment.creator_user), :width => 33, :height => 33, :alt => "用户头像"), user_url_in_org(comment.creator_user.id) %>
    <%= link_to comment.creator_user.show_name, user_url_in_org(comment.creator_user.id), :class => "newsBlue mr10 f14" %> <%= time_from_now(comment.created_on) %>
    <% if !comment.parent.nil? && !comment.parent.parent.nil? %> <% parents_rely = [] %> <% parents_rely = get_reply_parents_no_root parents_rely, comment %> <% length = parents_rely.length %>
    <% if length <= 3 %> <%=render :partial => 'users/journal_comment_reply', :locals => {:comment => comment.parent} %> <% else %>
    <%=render :partial => 'users/journal_comment_reply', :locals => {:comment => parents_rely[length - 1]} %>
    <%=render :partial => 'users/comment_reply_detail', :locals => {:comment => parents_rely[length - 2]} %>
    ↓ ↑ <%= link_to '点击展开隐藏楼层', show_all_replies_users_path(:comment => comment, :type => comment.class),:remote=>true %>
    <%=render :partial => 'users/comment_reply_detail', :locals => {:comment => parents_rely[0]} %>
    <% end %>
    <% end %> <% if !comment.content_detail.blank? || comment.class == Journal %>
    <% if comment.class == Journal %> <% if comment.details.any? %> <% details_to_strings(comment.details).each do |string| %>

    <%= string %>

    <% end %> <% end %>

    <%= comment.notes.html_safe %>

    <% else %> <%= comment.content_detail.html_safe %> <% end %>
    <%=render :partial=> "praise_tread/praise", :locals => {:activity=>comment, :user_activity_id=>comment.id,:type=>"reply"}%> <%= link_to( l(:button_reply), {:controller => 'users' ,:action => 'reply_to', :reply_id => comment.id, :type => type, :user_activity_id => user_activity_id, :activity_id => activity_id}, :remote => true, :method => 'get', :title => l(:button_reply)) %> ︿ <% if allow_delete %> <%= link_to('删除', {:controller => 'words', :action => 'destroy', :object_id => comment, :user_id => comment.user, :user_activity_id => user_activity_id, :activity_id => activity_id}, :remote => true, :confirm => l(:text_are_you_sure), :method => 'delete', :class => "fr mr20", :title => l(:button_delete)) %> <% end %>

    <% end %>
  • <% end %>