Sha256: d2bff453ceb9504bb39c94d667097ca6b88f260883ab5f6bf19e708a7863b29d
Contents?: true
Size: 855 Bytes
Versions: 2
Compression:
Stored size: 855 Bytes
Contents
class Spud::Admin::SettingsController < Spud::ApplicationController before_filter :require_user layout 'spud/admin/detail' def edit if current_user.has_admin_rights? add_breadcrumb "Dashboard", :spud_admin_root_path end add_breadcrumb "Settings", :spud_admin_settings_path @page_thumbnail = "spud/admin/users_thumb.png" @page_name = "Settings" end def update add_breadcrumb "Settings", :spud_admin_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_path else flash[:error] = "There was an error while saving your settings." render 'edit' end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
tb_core-1.0.2 | app/controllers/spud/admin/settings_controller.rb |
tb_core-1.0.1 | app/controllers/spud/admin/settings_controller.rb |