Method: Admin::CategoriesController#create

Defined in:
app/controllers/formol/admin/categories_controller.rb

#createObject



14
15
16
17
18
19
20
21
22
# File 'app/controllers/formol/admin/categories_controller.rb', line 14

def create
  if category.save
    respond_with(category, :status => :created, :location => admin_categories_path)
  else
    respond_with(category, :status => :unprocessable_entity) do |format|
      format.html { render :new }
    end
  end
end