Sha256: 96a41e27811b14a749aa194d8e7ba73a5e4d453038f21383f19e0998d7676b7a
Contents?: true
Size: 496 Bytes
Versions: 35
Compression:
Stored size: 496 Bytes
Contents
class Admin::PagePartsController < Admin::BaseController def new render :partial => "/admin/pages/page_part_field", :locals => { :part => PagePart.new(:title => params[:title], :body => params[:body]), :new_part => true, :part_index => params[:part_index] } end def destroy part = PagePart.find(params[:id]) if part.destroy render :text => "'#{part.title}' deleted." else render :text => "'#{part.title}' not deleted." end end end
Version data entries
35 entries across 35 versions & 2 rubygems