From c20b7fff43da7eeda39bd0ff8b18d70031b8771b Mon Sep 17 00:00:00 2001 From: cxt Date: Fri, 10 Mar 2017 17:54:40 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=BB=BA/=E7=BC=96=E8=BE=91=E4=BD=9C?= =?UTF-8?q?=E5=93=81=E7=9A=84=E6=88=AA=E6=AD=A2=E6=97=B6=E9=97=B4=E6=98=BE?= =?UTF-8?q?=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/avatar_controller.rb | 3 ++- app/views/student_work/edit.html.erb | 2 +- app/views/student_work/new.html.erb | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/app/controllers/avatar_controller.rb b/app/controllers/avatar_controller.rb index 228f20599..e3625cfde 100644 --- a/app/controllers/avatar_controller.rb +++ b/app/controllers/avatar_controller.rb @@ -75,7 +75,8 @@ class AvatarController < ApplicationController end @temp_file = nil - while !File.exist?(diskfile) + while !File.exists?(diskfile) + logger.info("###############################################################sleep") sleep(0.5) end diff --git a/app/views/student_work/edit.html.erb b/app/views/student_work/edit.html.erb index 68c7a129b..4b34de454 100644 --- a/app/views/student_work/edit.html.erb +++ b/app/views/student_work/edit.html.erb @@ -16,7 +16,7 @@ <%= @homework.name%>(作业名称) - 截止时间:<%= @homework.end_time%> + 截止时间:<%= format_time @homework.end_time%>
diff --git a/app/views/student_work/new.html.erb b/app/views/student_work/new.html.erb index e9f3a03de..6a8da2b94 100644 --- a/app/views/student_work/new.html.erb +++ b/app/views/student_work/new.html.erb @@ -222,7 +222,7 @@ <%= @homework.name%>(作业名称) - 截止时间:<%= @homework.end_time%> + 截止时间:<%= format_time @homework.end_time%>