diff --git a/apps/dashboard/app/controllers/active_jobs_controller.rb b/apps/dashboard/app/controllers/active_jobs_controller.rb index f830f63cfd..ece6423244 100644 --- a/apps/dashboard/app/controllers/active_jobs_controller.rb +++ b/apps/dashboard/app/controllers/active_jobs_controller.rb @@ -79,11 +79,11 @@ def get_job(jobid, cluster) ActiveJobs::Jobstatusdata.new(data, cluster, true) rescue OodCore::JobAdapterError - OpenStruct.new(name: jobid, error: "No job details because job has already left the queue." , status: status_label("completed") ) + OpenStruct.new(name: jobid, error: "No job details because job has already left the queue." , status: "completed" ) rescue => e Rails.logger.info("#{e}:#{e.message}") Rails.logger.info(e.backtrace.join("\n")) - OpenStruct.new(name: jobid, error: "No job details available.\n" + e.backtrace.to_s, status: status_label("") ) + OpenStruct.new(name: jobid, error: "No job details available.\n" + e.backtrace.to_s, status: "" ) end end diff --git a/apps/dashboard/app/models/active_jobs/jobstatusdata.rb b/apps/dashboard/app/models/active_jobs/jobstatusdata.rb index 5e2468e2d5..b95d5c88e8 100644 --- a/apps/dashboard/app/models/active_jobs/jobstatusdata.rb +++ b/apps/dashboard/app/models/active_jobs/jobstatusdata.rb @@ -7,7 +7,6 @@ module ActiveJobs # @author Brian L. McMichael # @version 0.0.1 class Jobstatusdata - include ActiveJobsHelper attr_reader :pbsid, :jobname, :username, :account, :status, :cluster, :cluster_title, :nodes, :starttime, :walltime, :walltime_used, :submit_args, :output_path, :nodect, :ppn, :total_cpu, :queue, :cput, :mem, :vmem, :shell_url, :file_explorer_url, :extended_available, :native_attribs, :error Attribute = Struct.new(:name, :value) @@ -28,7 +27,7 @@ def initialize(info, cluster=OODClusters.first, extended=false) self.jobname = info.job_name self.username = info.job_owner self.account = info.accounting_id || '' - self.status = status_label(info.status.state.to_s) + self.status = info.status.state.to_s self.cluster = cluster.id.to_s self.cluster_title = cluster.metadata.title || cluster.id.to_s.titleize self.walltime_used = info.wallclock_time.to_i > 0 ? pretty_time(info.wallclock_time) : '' diff --git a/apps/dashboard/app/views/active_jobs/_extended_panel.html.erb b/apps/dashboard/app/views/active_jobs/_extended_panel.html.erb index b6b96bfe3f..3c4486a16a 100644 --- a/apps/dashboard/app/views/active_jobs/_extended_panel.html.erb +++ b/apps/dashboard/app/views/active_jobs/_extended_panel.html.erb @@ -7,7 +7,7 @@
<%# FIXME: ul/li with css %> - <%= data.status %> + <%= status_label(data.status) %> <%= data.jobname %> <%= data.pbsid %>