DG, RS; Albums create failure prettier
This commit is contained in:
parent
a19e29f2c2
commit
eb36190188
2 changed files with 2 additions and 15 deletions
|
|
@ -12,7 +12,8 @@ class AlbumsController < ApplicationController
|
|||
flash[:notice] = "Successfully created album."
|
||||
redirect_to @album
|
||||
else
|
||||
render :action => 'new'
|
||||
flash[:error] = "Successfully failed."
|
||||
redirect_to albums_path
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -1,14 +0,0 @@
|
|||
%h1.big_text
|
||||
=link_to 'albums', albums_path
|
||||
>>
|
||||
new album
|
||||
|
||||
= form_for @album do |f|
|
||||
= f.error_messages
|
||||
%p
|
||||
= f.label :name
|
||||
= f.text_field :name
|
||||
%p
|
||||
= f.submit
|
||||
|
||||
%p= link_to "Back to List", albums_path
|
||||
Loading…
Reference in a new issue