|
|
@ -42,13 +42,16 @@ class WelcomeController < ApplicationController
|
|
|
|
|
|
|
|
|
|
|
|
# 运营引流个人数据展示
|
|
|
|
# 运营引流个人数据展示
|
|
|
|
def user_agents
|
|
|
|
def user_agents
|
|
|
|
@user_agents = UserAgent.find_by_key(params[:edu])
|
|
|
|
@user_agents = UserAgent.where(key: params[:edu])
|
|
|
|
@agents_count = @user_agents.count
|
|
|
|
@agents_count = @user_agents.count
|
|
|
|
limit = 20
|
|
|
|
limit = 20
|
|
|
|
@agents_pages = Paginator.new @agents_count, limit, params['page'] || 1
|
|
|
|
@agents_pages = Paginator.new @agents_count, limit, params['page'] || 1
|
|
|
|
@offset ||= @agents_pages.offset
|
|
|
|
@offset ||= @agents_pages.offset
|
|
|
|
@user_agents = paginateHelper @user_agents, limit
|
|
|
|
@user_agents = paginateHelper @user_agents, limit
|
|
|
|
|
|
|
|
respond_to do |format|
|
|
|
|
|
|
|
|
format.js
|
|
|
|
|
|
|
|
format.html{ render :layout=>'users_base'}
|
|
|
|
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|