dev_forum
daiao 5 years ago
parent 4efa98153f
commit cd87ea9b5a

@ -631,7 +631,7 @@ class ShixunsController < ApplicationController
limit = params[:limit] || 20
@users = User.joins(user_extension: :school).where("users.id not in #{member_ids} AND users.status = 1 AND
LOWER(users.lastname) LIKE '#{user_name}' AND LOWER(schools.name) LIKE
'#{school_name}'").page(page).per(limit)
'#{school_name}'").distinct.page(page).per(limit)
else
@users = User.none
end

Loading…
Cancel
Save