# encoding: UTF-8
module Admin
  class SvgElementsController < Admin::ApplicationController
    def index
      @svg_elements = SvgElement.all
    end

    def new

    end

    def create
      if @svg_element.save
        redirect_to [:edit, :admin, @svg_element]
      else
        render 'new'
      end
    end

    def update
      if @svg_element.update_attributes svg_element_params
        redirect_to [:edit, :admin, @svg_element]
      else
        render 'edit'
      end
    end

    def show

    end

    def edit

    end

    private

    def svg_element_params
      params.require(:svg_element).permit!
    end
  end
end
