small fix for top anns while filtering

This commit is contained in:
Harry Bomrah 2016-04-27 18:59:29 +08:00
parent e0b0ffcd09
commit 9e5d5cf095
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ class AnnouncementsController < ApplicationController
end end
end end
if OrbitHelper.page_number == 1 or OrbitHelper.page_number.nil? if OrbitHelper.page_number == 1 or OrbitHelper.page_number.nil? && !params["source"].present?
top_anns = Bulletin.where(:title.ne => "",:is_preview.in=>[false,nil], :is_top => true).and(:title.ne => nil).can_display.filter_by_categories([],false).to_a top_anns = Bulletin.where(:title.ne => "",:is_preview.in=>[false,nil], :is_top => true).and(:title.ne => nil).can_display.filter_by_categories([],false).to_a
end end
if !feeds_anns.blank? if !feeds_anns.blank?