From 5223734c4a40ebde1e39f2329c937254433dc00d Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Wed, 15 Jan 2020 17:01:23 +0800 Subject: [PATCH] 1 --- app/controllers/application_controller.rb | 2 +- app/services/shixun_search_service.rb | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index fdb41c114..3c481e8b6 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -23,7 +23,7 @@ class ApplicationController < ActionController::Base # 所有请求必须合法签名 def check_sign - if !Rails.env.development? + if !Rails.env.development? || Rails.logger.info("66666 #{params}") # suffix = request.url.split(".").last.split("?").first # suffix_arr = ["xls", "xlsx", "pdf", "zip"] # excel文件先注释 diff --git a/app/services/shixun_search_service.rb b/app/services/shixun_search_service.rb index 071b9f478..323804e95 100644 --- a/app/services/shixun_search_service.rb +++ b/app/services/shixun_search_service.rb @@ -43,7 +43,6 @@ class ShixunSearchService < ApplicationService @shixuns = @shixuns.where(trainee: params[:diff]) end - Rails.logger.info("search_shixun_ids: #{@shixuns.pluck(:id)}") Shixun.search(keyword, search_options) end @@ -53,7 +52,7 @@ class ShixunSearchService < ApplicationService order = if sort_str == "wechat_myshixuns_count" - {"is_wechat_support" => "desc", sort_str => order_str} + {"is_wechat_support" => "desc", "myshixuns_count" => order_str} else {sort_str => order_str} end