1
0
mirror of https://github.com/amix/vimrc synced 2025-02-28 14:12:51 +08:00
amix-vimrc-mirror/bundle/snipmate-snippets/ruby-rails/defshow.snippet
2014-05-09 21:28:39 +02:00

9 lines
175 B
Plaintext

def show
@${1:model_class_name} = ${2:ModelClassName}.find(params[:id])
respond_to do |wants|
wants.html # show.html.erb
wants.xml { render :xml => @$1 }
end
end${3}