Sha256: c250c170711b2a68292d6a830dd1be1295ea6af157a8eeea3684d6e1db0b88ab

Contents?: true

Size: 537 Bytes

Versions: 7

Compression:

Stored size: 537 Bytes

Contents

module AboutPage
  module AboutHelper
    def render_about_pane key, profile
      render :partial => partial_for_about_key(key), :locals => { :key => key, :profile => profile } 
    rescue 
      render :partial => 'exception', :locals => { :key => key, :profile => profile, :exception => $! }
    end

    def partial_for_about_key key
      about_page_partials[key] || key.to_s
    end

    private

    def about_page_partials
      { :solr => 'generic_hash', :fedora => 'generic_hash', :request => 'environment' }
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
about_page-0.0.7 app/helpers/about_page/about_helper.rb
about_page-0.0.6 app/helpers/about_page/about_helper.rb
about_page-0.0.5 app/helpers/about_page/about_helper.rb
about_page-0.0.4 app/helpers/about_page/about_helper.rb
about_page-0.0.3 app/helpers/about_page/about_helper.rb
about_page-0.0.2 app/helpers/about_page/about_helper.rb
about_page-0.0.1 app/helpers/about_page/about_helper.rb