Sha256: a9b3e6f54e9041575dc56ae7bca1a114f31d6d1c2f2687f2801b3cd1cdf4c168

Contents?: true

Size: 236 Bytes

Versions: 3

Compression:

Stored size: 236 Bytes

Contents

  def destroy
    @<%= singular_name %> = <%= class_name %>.find(params[:id])
    @<%= singular_name %>.destroy
    flash[:notice] = "Successfully destroyed <%= name.humanize.downcase %>."
    redirect_to <%= items_path('url') %>
  end

Version data entries

3 entries across 3 versions & 3 rubygems

Version Path
intinno-nifty-generators-0.2.5 rails_generators/nifty_scaffold/templates/actions/destroy.rb
rubycs-nifty-generators-compass-0.0.1 rails_generators/nifty_scaffold/templates/actions/destroy.rb
nifty-generators-0.2.4 rails_generators/nifty_scaffold/templates/actions/destroy.rb