Sha256: 12dee6d306f28704c6b13321a7cf3c6f5cf9bf80a39048d5083ea4252cf46adb

Contents?: true

Size: 617 Bytes

Versions: 14

Compression:

Stored size: 617 Bytes

Contents

module Naf
  class LogViewerController < Naf::ApplicationController

  	def index
       if params['record_type'] == 'job'
        @job = ::Naf::HistoricalJob.find_by_id(params['record_id'].to_i)
        @status = ::Logical::Naf::Job.new(@job).status
        @partial = 'job_logs'
      elsif params['record_type'] == 'machine'
        @machine = ::Naf::Machine.find_by_id(params['record_id'].to_i)
        @partial = 'machine_logs'
      elsif params['record_type'] == 'runner'
        @runner = ::Naf::MachineRunner.find_by_id(params['record_id'].to_i)
        @partial = 'runner_logs'
      end
    end

  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
naf-2.1.9 app/controllers/naf/log_viewer_controller.rb
naf-2.1.8 app/controllers/naf/log_viewer_controller.rb
naf-2.1.6 app/controllers/naf/log_viewer_controller.rb
naf-2.1.5 app/controllers/naf/log_viewer_controller.rb
naf-2.1.4 app/controllers/naf/log_viewer_controller.rb
naf-2.1.3 app/controllers/naf/log_viewer_controller.rb
naf-2.1.2 app/controllers/naf/log_viewer_controller.rb
naf-2.1.1 app/controllers/naf/log_viewer_controller.rb
naf-2.1.0 app/controllers/naf/log_viewer_controller.rb
naf-2.0.4 app/controllers/naf/log_viewer_controller.rb
naf-2.0.3 app/controllers/naf/log_viewer_controller.rb
naf-2.0.2 app/controllers/naf/log_viewer_controller.rb
naf-2.0.1 app/controllers/naf/log_viewer_controller.rb
naf-2.0.0 app/controllers/naf/log_viewer_controller.rb