Class: Disclaimer::SegmentsController
Instance Method Summary
collapse
disclaimer, #disclaimer_exists?, #disclaimer_has_been_accepted, #host_app_root_path, #redirect_to_disclaimer, #store_disclaimer_return_location
Instance Method Details
#create ⇒ Object
18
19
20
21
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 18
def create
new
update
end
|
#delete ⇒ Object
32
33
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 32
def delete
end
|
#destroy ⇒ Object
35
36
37
38
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 35
def destroy
@segment.destroy
redirect_to :controller => 'disclaimer/segments', :action => 'index'
end
|
#edit ⇒ Object
23
24
25
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 23
def edit
render :new
end
|
#index ⇒ Object
7
8
9
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 7
def index
@segments = Segment.all
end
|
#new ⇒ Object
14
15
16
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 14
def new
@segment = Segment.new
end
|
#show ⇒ Object
11
12
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 11
def show
end
|
#update ⇒ Object
27
28
29
30
|
# File 'app/controllers/disclaimer/segments_controller.rb', line 27
def update
@segment.update_attributes(params[:segment])
redirect_to segment_path(@segment)
end
|