115 lines
6.8 KiB
Plaintext
115 lines
6.8 KiB
Plaintext
<%= javascript_include_tag "/assets/kindeditor/kindeditor",'/assets/kindeditor/pasteimg',"init_KindEditor","forum" %>
|
|
<style type="text/css">
|
|
/*回复框*/
|
|
div.ke-toolbar{display:none;width:400px;border:none;background:none;padding:0px 0px;}
|
|
span.ke-toolbar-icon{line-height:26px;font-size:14px;padding-left:26px;}
|
|
span.ke-toolbar-icon-url{background-image:url( /images/public_icon.png )}
|
|
div.ke-toolbar .ke-outline{padding:0px 0px;line-height:26px;font-size:14px;}
|
|
span.ke-icon-emoticons{background-position:0px -671px;width:50px;height:26px;}
|
|
span.ke-icon-emoticons:hover{background-position:-79px -671px;width:50px;height:26px;}
|
|
div.ke-toolbar .ke-outline{border:none;}
|
|
/*.ke-container{height: 80px !important;}*/
|
|
</style>
|
|
<script>
|
|
init_KindEditor_data('',30);
|
|
</script>
|
|
<div class="postRightContainer">
|
|
<div class="postThemeContainer">
|
|
<div class="postDetailPortrait">
|
|
<%= link_to image_tag(url_to_avatar(@memo.author),:width=>50,:height => 50,:alt=>'贴吧图像' ),user_path(@memo.author) %>
|
|
</div>
|
|
<div class="postThemeWrap">
|
|
<div class="postDetailTitle"><a href="javascript:void(0);" class="f14 linkGrey4 fb">主题: <%= @memo.subject%></a></div>
|
|
<div class="postDetailCreater"><a href="javascript:void(0);" class="linkBlue2" target="_blank"><%= @memo.author.name%></a></div>
|
|
<div class="postDetailDate mb5"><%= format_date( @memo.created_at)%></div>
|
|
<span id="praise_tread" style="float: right">
|
|
<%= render :partial => "memos/praise_tread",:locals => {:obj => @memo,:show_flag => true,:user_id =>User.current.id,:horizontal => true}%>
|
|
</span>
|
|
<div class="cl"></div>
|
|
<div class="fl fontGrey3">
|
|
<%= @memo.content.html_safe%>
|
|
</div>
|
|
<div class="cl"></div>
|
|
<div class="mt10 fl">
|
|
<% if @memo.attachments.any?%>
|
|
<% options = {:author => true, :deletable => @memo.deleted_attach_able_by?(User.current) } %>
|
|
<%= render :partial => 'attachments_links', :locals => {:attachments => @memo.attachments, :options => options, :is_float => true} %>
|
|
<% end %>
|
|
</div>
|
|
</div>
|
|
<div class="cl"></div>
|
|
</div>
|
|
<div class="cl"></div>
|
|
<div class="homepagePostReply">
|
|
<div nhname='new_message' style="display:none;">
|
|
<%= form_for(@memo_new, url: forum_memos_path, :html => {:multipart => true}) do |f|%>
|
|
<%= f.hidden_field :subject, :required => true, value: @memo.subject %>
|
|
<%= f.hidden_field :forum_id, :required => true, value: @memo.forum_id %>
|
|
<%= f.hidden_field :parent_id, :required => true, value: @memo.id %>
|
|
<textarea placeholder="有问题或有建议,请直接给我留言吧!" style="display: none" nhname='new_message_textarea' name="memo[content]"></textarea>
|
|
<p nhname='contentmsg'></p>
|
|
<div nhname='toolbar_container' style="float:left;padding-top:3px;"></div>
|
|
<a id="new_message_cancel_btn" href="javascript:void(0)" class="grey_n_btn fr " style="margin-top:6px;">取消</a>
|
|
<a id="new_message_submit_btn" href="javascript:void(0)" class="blue_n_btn fr mr5 " style="margin-top:6px;">留言</a>
|
|
<% end %>
|
|
</div>
|
|
<div class="cl"></div>
|
|
<% @replies.each do |reply| %>
|
|
<div class="homepagePostReplyContainer">
|
|
<div class="homepagePostReplyPortrait">
|
|
<!--<a href="javascript:void(0);"><img src="images/homepageImage.jpg" width="45" height="45" alt="用户头像" /></a>-->
|
|
<%= link_to image_tag(url_to_avatar(reply.author), :width => 45,:height => 45), user_path(reply.author) %>
|
|
</div>
|
|
<div class="homepagePostReplyDes">
|
|
<div class="homepagePostReplyPublisher"><a href="<%=user_path(reply.author)%>" class="newsBlue mr10 f14"><%= reply.author.name%></a>
|
|
<% if reply.parent && reply.parent.id != @memo.id%>
|
|
<span class="f14">回复</span><a href="<%= user_path(reply.parent.author)%>" class="newsBlue mr10 ml15 f14"><%= reply.parent.author.name%></a>
|
|
<% end %>
|
|
|
|
<%= format_date(reply.created_at)%>
|
|
<!--<a href="javascript:void(0);" class="replyGrey fr ml10" >删除</a>-->
|
|
<%= link_to(
|
|
l(:button_delete),
|
|
{:action => 'destroy', :id => reply},
|
|
:method => :delete,
|
|
:data => {:confirm => l(:text_are_you_sure)},
|
|
:title => l(:button_delete),:class=>'replyGrey fr ml10'
|
|
) if reply.destroyable_by?(User.current) %>
|
|
<a href="javascript:void(0);" class="newsBlue fr" nhname="reply_btn">回复</a></div>
|
|
<div class="homepagePostReplyContent"><%= reply.content.html_safe%></div>
|
|
<div nhname='div_form' class="mt10 ml80" style="display:none;">
|
|
<%= form_for(@memo_new, url: forum_memos_path, :method=>'post') do |f| %>
|
|
|
|
<%= f.hidden_field :subject, :required => true, value: @memo.subject %>
|
|
<%= f.hidden_field :forum_id, :required => true, value: @memo.forum_id %>
|
|
<%= f.hidden_field :parent_id, :required => true, value: @memo.id %>
|
|
<%= hidden_field_tag :quote,"",:required => false,:style => 'display:none' %>
|
|
<textarea name='memo[content]' style="display:none;"></textarea>
|
|
<p nhname='contentmsg'></p>
|
|
<div nhname='toolbar_container' style="float:left;padding-top:3px;"></div>
|
|
<a nhname="cancel_btn" href="javascript:;" class="grey_n_btn fr" style="margin-top:3px;">取消</a>
|
|
<a nhname="submit_btn" href="javascript:;" class="blue_n_btn fr mr5" style="margin-top:3px;">发布</a>
|
|
<% end %>
|
|
<div class="cl"></div>
|
|
</div>
|
|
<div class="cl"></div>
|
|
</div>
|
|
<div class="cl"></div>
|
|
</div>
|
|
<% end %>
|
|
<!--<div class="homepagePostReplyContainer borderBottomNone">-->
|
|
<!--<div class="homepagePostReplyPortrait"><a href="javascript:void(0);"><img src="images/homepageImage.jpg" width="45" height="45" alt="用户头像" /></a></div>-->
|
|
<!--<div class="homepagePostReplyDes">-->
|
|
<!--<div class="homepagePostReplyPublisher">-->
|
|
<!--<a href="javascript:void(0);" class="newsBlue mr15 f14">linchun</a>-->
|
|
<!--<span class="f14">回复</span><a href="javascript:void(0);" class="newsBlue mr10 ml15 f14">Tangxiang</a>刚刚-->
|
|
<!--<a href="javascript:void(0);" class="replyGrey fr ml10">删除</a><a href="javascript:void(0);" class="newsBlue fr">回复</a></div>-->
|
|
<!--<div class="homepagePostReplyContent">点击设置就可以了。</div>-->
|
|
<!--</div>-->
|
|
<!--<div class="cl"></div>-->
|
|
<!--</div>-->
|
|
</div>
|
|
<div class="pagination">
|
|
<%= pagination_links_full @reply_pages, @reply_count, :per_page_links => false %>
|
|
</div>
|
|
</div> |