Commit ec1935f8 authored by Daniel Libanori's avatar Daniel Libanori
Browse files

Chaning user to form

parent da13d1dd
......@@ -10,7 +10,9 @@ class UsersController < ApplicationController
end
def update
current_user.update_attributes params[:user]
@user = User.find(params[:id])
@user.update_attributes(params[:user])
head status: 200
end
end
.sheet
%button.close
%h2 Sir Lancelot
%h3 Character Sheet
%form
%fieldset
= find_and_preserve do
%textarea= @user.sheet
%input( type="Submit" value="Save" )
%button.close
%h2 Sir Lancelot
%h3 Character Sheet
= form_for @user do |form|
%fieldset
= find_and_preserve do
= form.text_area :sheet
%input( type="Submit" value="Save" )
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment