Module: Abstractor::Methods::Controllers::AbstractorAbstractionsController
- Included in:
- AbstractorAbstractionsController
- Defined in:
- lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.included(base) ⇒ Object
5 6 7 |
# File 'lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb', line 5 def self.included(base) base.send :before_filter, :set_abstractor_abstraction, :only => [:show, :edit, :update] end |
Instance Method Details
#edit ⇒ Object
18 19 20 21 22 |
# File 'lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb', line 18 def edit respond_to do |format| format.html { render :layout => false } end end |
#index ⇒ Object
9 10 |
# File 'lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb', line 9 def index end |
#show ⇒ Object
12 13 14 15 16 |
# File 'lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb', line 12 def show respond_to do |format| format.html { render :layout => false } end end |
#update ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb', line 24 def update respond_to do |format| if @abstractor_abstraction.update_attributes(abstractor_abstraction_params) format.html { redirect_to(abstractor_abstraction_path(@abstractor_abstraction)) } else format.html { render :action => "edit" } end end end |
#update_all ⇒ Object
34 35 36 37 38 39 40 41 |
# File 'lib/abstractor/methods/controllers/abstractor_abstractions_controller.rb', line 34 def update_all abstractor_abstraction_value = params[:abstractor_abstraction_value] @about = params[:about_type].constantize.find(params[:about_id]) Abstractor::AbstractorAbstraction.update_abstractor_abstraction_other_value(@about.abstractor_abstractions, abstractor_abstraction_value) respond_to do |format| format.html { redirect_to :back } end end |