分页参数优化

dev_daiao
daiao 5 years ago
parent 6a2813c0aa
commit 34d7f73f91

@ -931,7 +931,7 @@ class ShixunsController < ApplicationController
page = params[:page] || 1
limit = params[:limit] || 20
@user_count = @users.count
@users = @users.page(page).per(limit)
@users = @users.page(page).per(20)
end
@ -995,7 +995,7 @@ class ShixunsController < ApplicationController
@courses = @courses.where(id: current_laboratory.all_courses)
@course_count = @courses.count
@courses = @courses.page(page).per(limit)
@courses = @courses.page(page).per(10)
end
# 将实训发送到课程

Loading…
Cancel
Save