状态位调整

dev_local
cxt 6 years ago
parent 48d64133b2
commit 08df962ee6

@ -21,19 +21,17 @@ class GraduationTasksController < ApplicationController
end
unless @order.blank?
case @order
if @course.is_end
@tasks = @tasks.where("0=1")
else
case @order
when '0', '1', '2', '3'
@tasks = @tasks.where(:status => @order)
when '4'
if @course.is_end
@tasks = @tasks
else
@tasks = @tasks.where("0=1")
end
@tasks = @tasks.where("status > 1 and allow_late = 1 and late_time > '#{Time.now}'")
else
if @course.is_end
@tasks = @tasks.where("0=1")
else
@tasks = @tasks.where(:status => @order)
end
@tasks = @tasks.where("0=1")
end
end
end

Loading…
Cancel
Save