diff --git a/app/controllers/graduation_tasks_controller.rb b/app/controllers/graduation_tasks_controller.rb index cadac75be..9b62f7dbd 100644 --- a/app/controllers/graduation_tasks_controller.rb +++ b/app/controllers/graduation_tasks_controller.rb @@ -110,9 +110,9 @@ class GraduationTasksController < ApplicationController end # 排序 - rorder = params[:order].blank? ? "updated_at" : params[:order] + rorder = params[:order].blank? ? "update_time" : params[:order] b_order = params[:b_order].blank? ? "desc" : params[:b_order] - if rorder == "updated_at" || rorder == "work_score" + if rorder == "update_time" || rorder == "work_score" @work_list = @work_list.order("graduation_works.#{rorder} #{b_order}") elsif rorder == "student_id" @work_list = @work_list.joins(user: :user_extension).order("user_extensions.#{rorder} #{b_order}")