69 lines
3.3 KiB
Plaintext
69 lines
3.3 KiB
Plaintext
<div class="orig_user fl">
|
|
<%= link_to image_tag(url_to_avatar(comment.creator_user), :width => "33", :height => "33"), user_path(comment.creator_user), :alt => "用户头像" %>
|
|
</div>
|
|
<script type="text/javascript">
|
|
$(function(){
|
|
showNormalImage('reply_content_<%= comment.id %>');
|
|
autoUrl('reply_content_<%= comment.id %>');
|
|
});
|
|
</script>
|
|
<div class="<%= type == 'TrainingTask' ? 'new_orig_right fl' : 'orig_right fl' %>" onmouseout="$(this).find('.reply-right').hide();" onmouseover="$(this).find('.reply-right').show();">
|
|
<%= link_to comment.creator_user.show_name, user_path(comment.creator_user), :class => "content-username" %>
|
|
<span class="orig_area"><%= time_from_now(comment.respond_to?(:created_on) ? comment.created_on : comment.created_at) %></span>
|
|
<div class="orig_content" id="reply_content_<%= comment.id %>">
|
|
<% if comment.class == Journal %>
|
|
<% if comment.details.any? %>
|
|
<% details_to_strings(comment.details).each do |string| %>
|
|
<p><%= string %></p>
|
|
<% end %>
|
|
<% end %>
|
|
<P><%= comment.content_detail.html_safe %></P>
|
|
<% else %>
|
|
<%= comment.content_detail.html_safe %>
|
|
<% end %>
|
|
</div>
|
|
<div class="orig_reply mt-10 pr" style="height: 18px;">
|
|
<div class="reply">
|
|
<div class="reply-right none" style="position: absolute; right: 0px;">
|
|
<span class="reply_praise_count_<%=comment.id %>">
|
|
<%=render :partial=> "praise_tread/praise", :locals => {:activity=>comment, :user_activity_id=>comment.id,:type=>"reply"}%>
|
|
</span>
|
|
<% if type == 'Message' %>
|
|
<% topic = comment.root %>
|
|
<% if !topic.locked? && authorize_for('messages', 'reply') %>
|
|
<span class="fr mr20">
|
|
<%= link_to(l(:button_reply),
|
|
{:controller => 'users' ,
|
|
:action => 'reply_to_comment',
|
|
:reply_id => comment.id,
|
|
:type => type,
|
|
:user_activity_id => user_activity_id,
|
|
:parent_id => parent_id},
|
|
:remote => true,
|
|
:method => 'get',
|
|
:title => l(:button_reply)) %>
|
|
<span id="reply_iconup_<%=comment.id %>" class="reply_iconup03" style="display: none"> ︿</span>
|
|
</span>
|
|
<% end %>
|
|
<% else %>
|
|
<span class="fr mr20">
|
|
<%= link_to(l(:button_reply),
|
|
{:controller => 'users',
|
|
:action => 'reply_to_comment',
|
|
:reply_id => comment.id,
|
|
:type => type,
|
|
:user_activity_id => user_activity_id,
|
|
:parent_id => parent_id},
|
|
:remote => true,
|
|
:method => 'get',
|
|
:title => l(:button_reply)) %>
|
|
<span id="reply_iconup_<%=comment.id %>" class="reply_iconup03" style="display: none"> ︿</span>
|
|
</span>
|
|
<% end %>
|
|
</div>
|
|
<div class="cl"></div>
|
|
</div>
|
|
</div>
|
|
<p id="reply_message_<%= comment.id%>"></p>
|
|
</div>
|
|
<div class="cl"></div> |