|
|
@ -70,7 +70,7 @@ class ShixunsController < ApplicationController
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
## 排序参数
|
|
|
|
## 排序参数
|
|
|
|
bsort = params[:sort] || 'desc'
|
|
|
|
bsort = (params[:sort] == "desc" ? "desc" : "asc")
|
|
|
|
case params[:order_by] || 'new'
|
|
|
|
case params[:order_by] || 'new'
|
|
|
|
when 'hot'
|
|
|
|
when 'hot'
|
|
|
|
@shixuns = @shixuns.order("shixuns.public = 2 desc, shixuns.myshixuns_count #{bsort}")
|
|
|
|
@shixuns = @shixuns.order("shixuns.public = 2 desc, shixuns.myshixuns_count #{bsort}")
|
|
|
|