diff options
Diffstat (limited to 'app/controllers')
| -rw-r--r-- | app/controllers/chouette_controller.rb | 4 | ||||
| -rw-r--r-- | app/controllers/companies_controller.rb | 15 | ||||
| -rw-r--r-- | app/controllers/referentials_controller.rb | 7 | 
3 files changed, 18 insertions, 8 deletions
| diff --git a/app/controllers/chouette_controller.rb b/app/controllers/chouette_controller.rb index 051e2fd77..1b9f30a85 100644 --- a/app/controllers/chouette_controller.rb +++ b/app/controllers/chouette_controller.rb @@ -7,7 +7,7 @@ class ChouetteController < InheritedResources::Base    end     def referential -    @referential = Referential.find params[:referential_id]   +    @referential ||= Referential.find params[:referential_id]      end  -end
\ No newline at end of file +end diff --git a/app/controllers/companies_controller.rb b/app/controllers/companies_controller.rb index 3cb440ea2..4fb83d789 100644 --- a/app/controllers/companies_controller.rb +++ b/app/controllers/companies_controller.rb @@ -4,4 +4,19 @@ class CompaniesController < ChouetteController    respond_to :xml    respond_to :json +  # def update +  #   update! do |success, failure| +  #     failure.html { redirect_to referential_companies_path(@resource,  @referential) } +  #   end     +  # end + +  protected + + +  # def resource_url(company = nil) +  #   puts "########################################" +  #   puts referential_company_path(referential, company || @resource).inspect +  #   referential_company_path(referential, company || @resource) +  # end +  end diff --git a/app/controllers/referentials_controller.rb b/app/controllers/referentials_controller.rb index 539c7ca5d..a5e3b7247 100644 --- a/app/controllers/referentials_controller.rb +++ b/app/controllers/referentials_controller.rb @@ -1,9 +1,4 @@  class ReferentialsController < InheritedResources::Base - -  before_filter :switch_referential - -  def switch_referential -    Apartment::Database.switch(referential.slug) -  end  +  respond_to :html  end | 
