From 77bb60f3235a0642628835491a27acfa75b52e9f Mon Sep 17 00:00:00 2001 From: jingquan huang Date: Sat, 3 Aug 2019 10:17:56 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9C=80=E5=A4=A7=E6=8F=90=E4=BA=A4=E6=97=B6?= =?UTF-8?q?=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/managements_controller.rb | 2 +- app/views/managements/evaluate_simple.html.erb | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/controllers/managements_controller.rb b/app/controllers/managements_controller.rb index 6217532c..6e495cdf 100644 --- a/app/controllers/managements_controller.rb +++ b/app/controllers/managements_controller.rb @@ -878,7 +878,7 @@ class ManagementsController < ApplicationController def evaluate_simple page = params[:page] - @recodes = EvaluateRecord.where("created_at > ?", Time.now - 1.days).reorder("consume_time desc") + @recodes = EvaluateRecord.where("created_at < ?", Time.now).reorder("consume_time desc") @recodes_count = @recodes.size @record_pages = Paginator.new @recodes_count, 20, page || 1 @offset ||= @record_pages.offset diff --git a/app/views/managements/evaluate_simple.html.erb b/app/views/managements/evaluate_simple.html.erb index 30e8cd39..514223a3 100644 --- a/app/views/managements/evaluate_simple.html.erb +++ b/app/views/managements/evaluate_simple.html.erb @@ -5,7 +5,6 @@ ID 总耗时 - 作品更新 文件更新 中间层总耗时 pull代码 @@ -15,7 +14,8 @@ 前端轮询 结果存储 创建时间 - 最大执行时间 + 评测时最大时间 + 最新执行时间 唯一标识 实训名称 @@ -26,7 +26,6 @@ <%= record.id %> <%= record.consume_time %> - <%= record.student_work %> <%= record.file_update %> <%= record.brige %> <%= record.git_pull %> @@ -37,8 +36,9 @@ <%= record.test_cases %> <%= format_time record.created_at %> <% challenge = Game.find(record.game_id).challenge %> + <%= record.try(:exec_time) %> <%= challenge.try(:exec_time) %> - <%= record.shixun.try(:identifier) %> + <%= record.try(:identifier) %> <%= link_to record.shixun.try(:name), task_path(record.game), :target => "_blank", :title => "#{record.shixun.try(:name)}" %> <% end %>