Sha256: 2d3835d8c3f4621d1990dfc989994abcab99c8d898d94a9409319b038ae15464

Contents?: true

Size: 966 Bytes

Versions: 21

Compression:

Stored size: 966 Bytes

Contents

class Muck::VisitsController < ApplicationController
  
  unloadable

  before_filter :store_location

  def show
    @entry = Entry.find(params[:id])
    @page_title = @entry.title
    @resource_uri = @entry.resource_uri
    @share = Share.new(:title => @entry.title, :uri => @resource_uri, :entry_id => @entry.id) if GlobalConfig.enable_services_shares
    @recommendations = @entry.recommendations(5)

    if GlobalConfig.enable_services_comments
      # Show the activities related to this entry
      @activities = @entry.activities.oldest.only_public.find(:all, :include => ['comments'])
      @comment_count = @activities.length + @activities.inject(0) {|n,activity| activity.comments.length + n }
    end
    
    respond_to do |format|
      format.html { render :template => 'visits/show', :layout => 'frame' }
      format.pjs { render :template => 'visits/show', :layout => false }
      format.json { render :json => @entry.as_json }
    end
  end

end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
muck-services-0.1.34 app/controllers/muck/visits_controller.rb
muck-services-0.1.33 app/controllers/muck/visits_controller.rb
muck-services-0.1.32 app/controllers/muck/visits_controller.rb
muck-services-0.1.31 app/controllers/muck/visits_controller.rb
muck-services-0.1.30 app/controllers/muck/visits_controller.rb
muck-services-0.1.29 app/controllers/muck/visits_controller.rb
muck-services-0.1.28 app/controllers/muck/visits_controller.rb
muck-services-0.1.27 app/controllers/muck/visits_controller.rb
muck-services-0.1.26 app/controllers/muck/visits_controller.rb
muck-services-0.1.25 app/controllers/muck/visits_controller.rb
muck-services-0.1.24 app/controllers/muck/visits_controller.rb
muck-services-0.1.23 app/controllers/muck/visits_controller.rb
muck-services-0.1.22 app/controllers/muck/visits_controller.rb
muck-services-0.1.21 app/controllers/muck/visits_controller.rb
muck-services-0.1.20 app/controllers/muck/visits_controller.rb
muck-services-0.1.19 app/controllers/muck/visits_controller.rb
muck-services-0.1.18 app/controllers/muck/visits_controller.rb
muck-services-0.1.17 app/controllers/muck/visits_controller.rb
muck-services-0.1.16 app/controllers/muck/visits_controller.rb
muck-services-0.1.14 app/controllers/muck/visits_controller.rb