work on controllers/views started

This commit is contained in:
albert
2010-03-11 19:42:04 -05:00
parent ac98d7db37
commit 15c134b270
34 changed files with 720 additions and 7543 deletions

View File

@@ -1,17 +1,28 @@
class UsersController < ApplicationController
respond_to :html, :xml, :json
def new
@user = User.new
end
def edit
@user = User.find(params[:id])
unless @current_user.is_admin?
@user = @current_user
end
end
def index
end
def show
@user = User.find(params[:id])
end
def create
@user = User.new(params[:user])
flash[:notice] = "You have succesfully created a new account." if @user.save
respond_with(@user)
end
def update