修改菜单
This commit is contained in:
parent
f53d9e19f7
commit
697906509b
|
@ -172,6 +172,7 @@ class WechatsController < ActionController::Base
|
|||
raise "非法操作, code不存在" unless params[:code]
|
||||
openid = get_openid(params[:code])
|
||||
raise "无法获取到openid" unless openid
|
||||
raise "此微信号已绑定用户, 不能得复绑定" if UserWechat.where(openid: openid).first
|
||||
|
||||
user, last_login_on = User.try_to_login(params[:username], params[:password])
|
||||
raise "用户名或密码错误,请重新登录" unless user
|
||||
|
|
Loading…
Reference in New Issue