From fc3df1c26ffa0c17b1f170b4a9956f8533941ed7 Mon Sep 17 00:00:00 2001 From: cxt Date: Tue, 9 Aug 2016 16:38:17 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E9=A2=98=E5=BA=93=E9=A2=84=E8=A7=88?= =?UTF-8?q?=E5=BC=B9=E6=A1=86=E7=9A=84=E6=A0=B7=E5=BC=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/javascripts/application.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/javascripts/application.js b/public/javascripts/application.js index c2152184a..60e5855c2 100644 --- a/public/javascripts/application.js +++ b/public/javascripts/application.js @@ -1498,7 +1498,7 @@ function pop_box_new(value, Width, Top, Left){ showModal('ajax-modal', Width + 'px'); $('#ajax-modal').siblings().remove(); $('#ajax-modal').parent().css({"top": Top+"%","left": Left+"%","transform":"translate(-50%,-50%)","padding":"0","border":"none"}); - $('#ajax-modal').css({"padding":"0"}); + $('#ajax-modal').css({"padding":"0","overflow":"hidden"}); } From a3011c319b8cd32676c32938bf041824bb81fc68 Mon Sep 17 00:00:00 2001 From: cxt Date: Tue, 9 Aug 2016 16:40:56 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=88=91=E7=9A=84=E9=A2=98=E5=BA=93?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E6=88=91=E7=9A=84=E6=89=80=E6=9C=89=E4=BD=9C?= =?UTF-8?q?=E4=B8=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/users_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 932617671..54d43c891 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -599,7 +599,7 @@ class UsersController < ApplicationController if(params[:type].blank? || params[:type] == "1") #我的题库 courses = @user.courses.where("is_delete = 1") course_ids = courses.empty? ? "(-1)" : "(" + courses.map{|course| course.id}.join(",") + ")" - @homeworks = HomeworkCommon.where("user_id = #{@user.id} and publish_time <= '#{Date.today}' and course_id not in #{course_ids}").order("#{@order} #{@b_sort}") + @homeworks = HomeworkCommon.where("user_id = #{@user.id} and course_id not in #{course_ids}").order("#{@order} #{@b_sort}") elsif params[:type] == "2" #公共题库 visible_course = Course.where("is_delete = 0") visible_course_ids = visible_course.empty? ? "(-1)" : "(" + visible_course.map{|course| course.id}.join(",") + ")"