Add missing JSON/XML responses.
* GET /bans.json * GET /bans/1.json * GET /ip_bans.json * POST /ip_bans.json * DELETE /ip_bans.json * GET /mod_actions.json * GET /posts/1/events.json * POST /saved_searches.json * DELETE /saved_searches/1.json * GET /super_voters.json
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
class BansController < ApplicationController
|
||||
before_filter :moderator_only, :except => [:show, :index]
|
||||
respond_to :html, :xml, :json
|
||||
|
||||
def new
|
||||
@ban = Ban.new(params[:ban])
|
||||
@@ -12,10 +13,12 @@ class BansController < ApplicationController
|
||||
def index
|
||||
@search = Ban.search(params[:search]).order("id desc")
|
||||
@bans = @search.paginate(params[:page], :limit => params[:limit])
|
||||
respond_with(@bans)
|
||||
end
|
||||
|
||||
def show
|
||||
@ban = Ban.find(params[:id])
|
||||
respond_with(@ban)
|
||||
end
|
||||
|
||||
def create
|
||||
|
||||
Reference in New Issue
Block a user