engine/app/controllers/locomotive/my_account_controller.rb

25 lines
498 B
Ruby
Raw Normal View History

module Locomotive
2011-07-06 18:48:04 +00:00
class MyAccountController < BaseController
sections 'settings', 'account'
respond_to :json, :only => :update
helper 'Locomotive::Accounts'
skip_load_and_authorize_resource
def edit
@account = current_locomotive_account
respond_with @account
end
def update
@account = current_locomotive_account
@account.update_attributes(params[:account])
respond_with @account, :location => edit_my_account_url
end
end
end