Sha256: d0ac9012d3f15972e16ac1ee5d4e46fc0c91ad6cd6af2b256c363087344a2efd

Contents?: true

Size: 755 Bytes

Versions: 1

Compression:

Stored size: 755 Bytes

Contents

class Spud::UsersController < Spud::ApplicationController
	before_filter :require_user
	layout 'spud/admin/detail'

	def settings
		add_breadcrumb "Settings", :spud_settings_path
		@page_thumbnail = "spud/admin/users_thumb.png"
		@page_name = "Settings"	
	end

	def update
		
		add_breadcrumb "Settings", :spud_settings_path
		@page_thumbnail = "spud/admin/users_thumb.png"
		@page_name = "Settings"	
		if @current_user.update_attributes(params[:spud_user].slice :login,:first_name,:last_name,:email,:password,:password_confirmation,:time_zone)
			flash[:notice] = "User settings saved successfully."
			redirect_to spud_admin_root_url()
		else
			flash[:error] = "There was an error while saving the user."
			render :action => "settings"
		end
	end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
spud_core-0.8.0 app/controllers/spud/users_controller.rb