fix
This commit is contained in:
parent
141851568e
commit
0c1fc57f15
|
@ -16,6 +16,7 @@ class AnnouncementsController < ApplicationController
|
||||||
announcements_count = announcements.count
|
announcements_count = announcements.count
|
||||||
keyword = params[:unit]
|
keyword = params[:unit]
|
||||||
elsif params[:tag]
|
elsif params[:tag]
|
||||||
|
!params[:sort].blank? ? sort = {params[:sort].to_sym=>params[:order]} : sort = {:postdate=>"desc"}
|
||||||
announcements = Bulletin.where(:title.ne => "" ,:is_preview.in=>[false,nil]).is_approved.order_by(sort).filter_by_categories(["all"]).filter_by_tags([params[:tag]])
|
announcements = Bulletin.where(:title.ne => "" ,:is_preview.in=>[false,nil]).is_approved.order_by(sort).filter_by_categories(["all"]).filter_by_tags([params[:tag]])
|
||||||
else
|
else
|
||||||
!params[:sort].blank? ? sort = {params[:sort].to_sym=>params[:order]} : sort = {:postdate=>"desc"}
|
!params[:sort].blank? ? sort = {params[:sort].to_sym=>params[:order]} : sort = {:postdate=>"desc"}
|
||||||
|
|
Reference in New Issue