fixed 授权登录绑定账号返回用户信息
This commit is contained in:
parent
3459054349
commit
87ee19e882
|
@ -12,7 +12,7 @@ class BindUsersController < ApplicationController
|
|||
tip_exception '该账号已被绑定,请更换其他账号进行绑定' if bind_user.bind_open_user?(params[:type].to_s)
|
||||
|
||||
"OpenUsers::#{params[:type].to_s.capitalize}".constantize.create!(user: bind_user, uid: session[:unionid])
|
||||
render_ok
|
||||
@user = bind_user
|
||||
end
|
||||
|
||||
def new_user
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
json.username @user.full_name
|
||||
json.real_name @user.real_name
|
||||
json.login @user.login
|
||||
json.user_id @user.id
|
||||
json.image_url url_to_avatar(@user)
|
||||
json.admin @user.admin?
|
||||
json.user_identity @user.identity
|
||||
json.is_watch current_user&.watched?(@user)
|
Loading…
Reference in New Issue