@@ -195,7 +195,7 @@ func (this *WechatCommonController) WechatLogin() {
fmt.Println("unionId", wxInfo.UnionID)
token, userId, firstLogin, _, err := services.WxLogin(code, wxInfo.OpenID, wxInfo.UnionID, wxUserInfo)
- if err != nil {
+ if err != nil && err.Error() != utils.ErrNoRow() {
br.Msg = "微信登录失败"
br.ErrMsg = "微信登录失败,err:" + err.Error()
return
@@ -48,5 +48,6 @@ func init() {
new(CygxArticle),
new(CygxArticleHistoryRecord),
new(CygxSearchKeyWord),
+ new(UserRecord),
)
}