Sha256: eab8eb8041124afb00e34976875f565bb5c2b2fd600b69c3cd87ed771dcf58f6

Contents?: true

Size: 765 Bytes

Versions: 12

Compression:

Stored size: 765 Bytes

Contents

class EricWeixin::Cms::Weixin::UsersController < EricWeixin::Cms::BaseController
  def index
    pp user_params
    @user = ::EricWeixin::WeixinUser.search_weixin_user(user_params).paginate(:page => params[:page], :per_page => 10)
  end


  def modify_remark
    user = ::EricWeixin::WeixinUser.find(params[:id])
    user.set_remark params[:new_remark]
    user.reload
    render text: user.remark
  end

  private
  	def user_params
      params.permit(:id, :openid, :sex, :nickname, :language, :city, :province, :country, :subscribe_time_start, :subscribe, :subscribe_time_end, :created_at_start, :created_at_end, :updated_at_start, :updated_at_end, :remark, :member_info_id, :weixin_public_account_id, :last_register_channel, :first_register_channel)
    end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
eric_weixin-0.4.2 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.4.1 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.4.0 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.3.3 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.3.2 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.3.1 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.3.0 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.2.3 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.2.1 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.2.0 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.1.1 app/controllers/eric_weixin/cms/weixin/users_controller.rb
eric_weixin-0.1.0 app/controllers/eric_weixin/cms/weixin/users_controller.rb