Sha256: 7be775c86929969c8845a04da33509a81e151bb1754ff30999a26de96fdff2ec

Contents?: true

Size: 489 Bytes

Versions: 5

Compression:

Stored size: 489 Bytes

Contents

class Ckeditor::PicturesController < Ckeditor::BaseController

  def index
    @pictures = Ckeditor.picture_model.find_all(ckeditor_pictures_scope)
    respond_with(@pictures) 
  end
  
  def create
    @picture = Ckeditor::Picture.new
	  respond_with_asset(@picture)
  end
  
  def destroy
    @picture.destroy
    respond_with(@picture, :location => ckeditor_pictures_path)
  end
  
  protected
  
    def find_asset
      @picture = Ckeditor.picture_model.get!(params[:id])
    end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
ckeditor-3.6.3 app/controllers/ckeditor/pictures_controller.rb
ckeditor-3.6.2 app/controllers/ckeditor/pictures_controller.rb
ckeditor-3.6.1 app/controllers/ckeditor/pictures_controller.rb
ckeditor-3.6.0 app/controllers/ckeditor/pictures_controller.rb
ckeditor-3.6.0.pre app/controllers/ckeditor/pictures_controller.rb