You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
551 B
14 lines
551 B
class Admins::ShixunFeedbackMessagesController < Admins::BaseController
|
|
|
|
def index
|
|
default_sort('created_at', 'desc')
|
|
@params_page = params[:page] || 1
|
|
if params[:keyword]
|
|
discusses = Discuss.find_by_sql("select * from discusses join shixuns on discusses.dis_id = shixuns.id where discusses.dis_type='Shixun' AND
|
|
shixuns.name like '%#{params[:keyword]}%'")
|
|
else
|
|
discusses = Discuss.where(:dis_type => 'Shixun').includes(:user, :dis)
|
|
end
|
|
@discusses = paginate discusses
|
|
end
|
|
end |