解决项目讨论区置顶功能不能使用问题

tmp
huang 10 years ago
parent 7c8525298c
commit d0ea49d1e9

@ -103,7 +103,7 @@ class BoardsController < ApplicationController
@topic_pages = Paginator.new @topic_count, per_page_option, params['page'] @topic_pages = Paginator.new @topic_count, per_page_option, params['page']
#现在发布帖子的时候置顶功能已经没有了。所以取消这个置顶排序 #{Message.table_name}.sticky DESC, #现在发布帖子的时候置顶功能已经没有了。所以取消这个置顶排序 #{Message.table_name}.sticky DESC,
@topics = @board.topics. @topics = @board.topics.
reorder("#{Message.table_name}.created_on desc"). reorder("#{Message.table_name}.sticky DESC, #{Message.table_name}.created_on desc").
includes(:last_reply). includes(:last_reply).
limit(@topic_pages.per_page). limit(@topic_pages.per_page).
offset(@topic_pages.offset). offset(@topic_pages.offset).

@ -51,9 +51,9 @@
:data => {:confirm => l(:text_are_you_sure)}, :data => {:confirm => l(:text_are_you_sure)},
:class => 'talk_edit fr', :class => 'talk_edit fr',
:style => ' margin-right: 10px;') if topic.destroyable_by?(User.current) %> :style => ' margin-right: 10px;') if topic.destroyable_by?(User.current) %>
<%# if topic.sticky? %> <% if topic.sticky? %>
<!--<a href="javascript:void(0)" class="talk_up fr c_red" style="margin-right: 10px;"><%#= l(:label_board_sticky)%></a>--> <a href="javascript:void(0)" class="talk_up fr c_red" style="margin-right: 10px;"><%= l(:label_board_sticky)%></a>
<%# end %> <% end %>
<script> <script>
//$(function(){if($("#contentmessage<%#=topic.id %>").height()>182){$("#project_show_<%#= topic.id%>").show();}}); //$(function(){if($("#contentmessage<%#=topic.id %>").height()>182){$("#project_show_<%#= topic.id%>").show();}});
//解决由于图片加载慢造成div高度不够 以至于展开按钮不显示的bug //解决由于图片加载慢造成div高度不够 以至于展开按钮不显示的bug

Loading…
Cancel
Save