From 0dce86d47ed0346538bae26b9bf3525406af6311 Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Mon, 23 Jun 2014 09:42:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=A6=96=E9=A1=B5=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=E6=98=BE=E7=A4=BA=E4=B8=BA=E6=8C=89=E6=B4=BB=E8=B7=83?= =?UTF-8?q?=E5=BA=A6=E6=8E=92=E5=90=8D=E7=9A=84=E5=89=8D10=E4=B8=AA?= =?UTF-8?q?=E9=A1=B9=E7=9B=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/helpers/welcome_helper.rb | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/helpers/welcome_helper.rb b/app/helpers/welcome_helper.rb index 62cb451cc..003c6f288 100644 --- a/app/helpers/welcome_helper.rb +++ b/app/helpers/welcome_helper.rb @@ -158,10 +158,11 @@ module WelcomeHelper end def find_miracle_project(sum, max_rate) - max = sum*(max_rate.to_f/10) - c1 = find_new_project(sum).to_a.dup - c2 = find_all_hot_project(sum).to_a.dup - (c2.take(sum-max)+c1.take(max)).take(sum) + #max = sum*(max_rate.to_f/10) + #c1 = find_new_project(sum).to_a.dup + #c2 = find_all_hot_project(sum).to_a.dup + #(c2.take(sum-max)+c1.take(max)).take(sum) + find_all_hot_project(sum).to_a.dup end def find_new_course limit=15