diff --git a/app/controllers/announcements_controller.rb b/app/controllers/announcements_controller.rb index 13b39d6..3763fb0 100644 --- a/app/controllers/announcements_controller.rb +++ b/app/controllers/announcements_controller.rb @@ -342,9 +342,9 @@ class AnnouncementsController < ApplicationController OrbitHelper.set_current_widget_module("announcement") OrbitHelper.set_params(params,current_user) Bulletin.remove_expired_status - sorted,total_pages = get_sorted_annc OrbitHelper.set_page_number(params[:page_no].to_i) OrbitHelper.set_page_data_count((params[:data_count].blank? ? 10 : params[:data_count].to_i)) + sorted,total_pages = get_sorted_annc anns = sorted.collect do |a| if a["source-site"].blank? statuses = a.statuses_with_classname.collect do |status| diff --git a/app/helpers/announcements_helper.rb b/app/helpers/announcements_helper.rb index 5d898bc..276d03b 100644 --- a/app/helpers/announcements_helper.rb +++ b/app/helpers/announcements_helper.rb @@ -372,7 +372,7 @@ module AnnouncementsHelper end html = render_link_to_edit(html, data["url_to_edit"]) if !data["url_to_edit"].nil? total_pages = data['total_pages'].to_i rescue 1 - if @show_page == false + if @show_page == "false" html = html.gsub("{{pagination_goes_here}}","") else if total_pages > 1