Merge remote branch 'jeffry/master'
This commit is contained in:
commit
0859d8ebfe
1 changed files with 5 additions and 5 deletions
|
|
@ -32,8 +32,8 @@ class AspectsController < ApplicationController
|
||||||
|
|
||||||
begin
|
begin
|
||||||
current_user.drop_aspect @aspect
|
current_user.drop_aspect @aspect
|
||||||
flash[:notice] = i18n.t 'aspects.destroy.success',:name => @aspect.name
|
flash[:notice] = I18n.t 'aspects.destroy.success',:name => @aspect.name
|
||||||
rescue RuntimeError => e
|
rescue RuntimeError => e
|
||||||
flash[:error] = e.message
|
flash[:error] = e.message
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -67,7 +67,7 @@ class AspectsController < ApplicationController
|
||||||
|
|
||||||
data = clean_hash(params[:aspect])
|
data = clean_hash(params[:aspect])
|
||||||
@aspect.update_attributes( data )
|
@aspect.update_attributes( data )
|
||||||
flash[:notice] = i18n.t 'aspects.update.success',:name => @aspect.name
|
flash[:notice] = I18n.t 'aspects.update.success',:name => @aspect.name
|
||||||
respond_with @aspect
|
respond_with @aspect
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -75,13 +75,13 @@ class AspectsController < ApplicationController
|
||||||
params[:moves].each{ |move|
|
params[:moves].each{ |move|
|
||||||
move = move[1]
|
move = move[1]
|
||||||
unless current_user.move_friend(move)
|
unless current_user.move_friend(move)
|
||||||
flash[:error] = i18n.t 'aspects.move_friends.failure', :real_name => Person.find_by_id( move[:friend_id] ).real_name
|
flash[:error] = I18n.t 'aspects.move_friends.failure', :real_name => Person.find_by_id( move[:friend_id] ).real_name
|
||||||
redirect_to aspects_manage_path
|
redirect_to aspects_manage_path
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
|
|
||||||
flash[:notice] = i18n.t 'aspects.move_friends.success'
|
flash[:notice] = I18n.t 'aspects.move_friends.success'
|
||||||
redirect_to aspects_manage_path
|
redirect_to aspects_manage_path
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue