This repository has been archived on 2024-03-16. You can view files and clone it, but cannot push or open issues or pull requests.
2010-03-15 09:35:01 +00:00
|
|
|
class Admin::UserAttributesController < ApplicationController
|
|
|
|
|
2011-12-05 01:54:41 +00:00
|
|
|
layout "admin"
|
2010-03-15 09:35:01 +00:00
|
|
|
before_filter :authenticate_user!
|
|
|
|
|
|
|
|
def index
|
|
|
|
@user_attributes = UserAttribute.all
|
|
|
|
end
|
|
|
|
|
|
|
|
def show
|
|
|
|
@user_attribute = UserAttribute.find(params[:id])
|
|
|
|
end
|
|
|
|
|
|
|
|
def new
|
|
|
|
@user_attribute = UserAttribute.new
|
|
|
|
end
|
|
|
|
|
|
|
|
def edit
|
|
|
|
@user_attribute = UserAttribute.find(params[:id])
|
|
|
|
end
|
|
|
|
|
|
|
|
def create
|
|
|
|
@user_attribute = UserAttribute.new(params[:user_attribute])
|
|
|
|
@user_attribute.save
|
|
|
|
|
|
|
|
redirect_to :action => :index
|
|
|
|
end
|
|
|
|
|
|
|
|
def update
|
|
|
|
@user_attribute = UserAttribute.find(params[:id])
|
|
|
|
@user_attribute.update_attributes(params[:user_attribute])
|
|
|
|
|
|
|
|
redirect_to :action => :index
|
|
|
|
end
|
|
|
|
|
|
|
|
def destroy
|
|
|
|
@user_attribute = UserAttribute.find(params[:id])
|
|
|
|
@user_attribute.destroy
|
|
|
|
|
|
|
|
redirect_to :action => :index
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|