Class: DispatchLinksController

Inherits:
ApplicationController show all
Defined in:
lib/forge/app/controllers/dispatch_links_controller.rb

Instance Method Summary collapse

Methods inherited from ApplicationController

#app_init

Instance Method Details

#showObject



2
3
4
5
6
# File 'lib/forge/app/controllers/dispatch_links_controller.rb', line 2

def show
  @dispatch_link = DispatchLink.find_by_dispatch_id_and_position(params[:dispatch_id], params[:id])
  @dispatch_link.clicks.create(:ip => request.env["HTTP_X_FORWARDED_FOR"])
  redirect_to @dispatch_link.uri
end