Class: Dust::SiteWidesController

Inherits:
AuthenticationController show all
Defined in:
app/controllers/dust/site_wides_controller.rb

Instance Method Summary collapse

Methods inherited from AuthenticationController

#not_authenticated, #permission_denied, #try_return_to_previous_page

Instance Method Details

#createObject



11
12
13
14
15
16
17
18
# File 'app/controllers/dust/site_wides_controller.rb', line 11

def create
  @site_wide = Dust::SiteWide.new(params[:dust_site_wide])
  if @site_wide.save
    redirect_to dust_dashboard_path
  else
    render :action => :new
  end
end

#destroyObject



20
21
22
23
24
25
# File 'app/controllers/dust/site_wides_controller.rb', line 20

def destroy
  @site_wide = Dust::SiteWide.find params[:id]
  @site_wide.destroy

  redirect_to dust_dashboard_path
end

#newObject



7
8
9
# File 'app/controllers/dust/site_wides_controller.rb', line 7

def new
  @site_wide = Dust::SiteWide.new
end