fixes
This commit is contained in:
@@ -16,7 +16,7 @@ class ForumPostsController < ApplicationController
|
||||
|
||||
def index
|
||||
@search = ForumPost.search(params[:search])
|
||||
@forum_posts = @search.paginate(:page => params[:page], :order => "id DESC")
|
||||
@forum_posts = @search.paginate(params[:page])
|
||||
respond_with(@forum_posts)
|
||||
end
|
||||
|
||||
|
||||
@@ -18,13 +18,13 @@ class ForumTopicsController < ApplicationController
|
||||
|
||||
def index
|
||||
@search = ForumTopic.search(params[:search])
|
||||
@forum_topics = @search.paginate(:page => params[:page], :order => "is_sticky DESC, updated_at DESC")
|
||||
@forum_topics = @search.paginate(params[:page]).order("is_sticky DESC, updated_at DESC")
|
||||
respond_with(@forum_topics)
|
||||
end
|
||||
|
||||
def show
|
||||
@forum_topic = ForumTopic.find(params[:id])
|
||||
@forum_posts = ForumPost.search(:topic_id_eq => @forum_topic.id).paginate(:page => params[:page])
|
||||
@forum_posts = ForumPost.search(:topic_id_eq => @forum_topic.id).paginate(params[:page])
|
||||
respond_with(@forum_topic)
|
||||
end
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ class NoteVersionsController < ApplicationController
|
||||
|
||||
def index
|
||||
@search = NoteVersion.search(params[:search])
|
||||
@note_versions = @search.paginate(:page => params[:page])
|
||||
@note_versions = @search.paginate(params[:page])
|
||||
respond_with(@note_versions)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -16,7 +16,7 @@ class WikiPagesController < ApplicationController
|
||||
|
||||
def index
|
||||
@search = WikiPage.search(params[:search])
|
||||
@wiki_pages = @search.paginate(:page => params[:page])
|
||||
@wiki_pages = @search.paginate(params[:page])
|
||||
respond_with(@wiki_pages) do |format|
|
||||
format.html do
|
||||
if @wiki_pages.count == 1
|
||||
|
||||
Reference in New Issue
Block a user