瀏覽代碼

Merge branch '0.0.1' into debug

Roc 3 年之前
父節點
當前提交
bb5252345e
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      controllers/admin.go

+ 4 - 0
controllers/admin.go

@@ -37,6 +37,10 @@ func (this *AdminCommon) Login() {
 
 
 	adminWx, err := services.BindWxUser(this.Session.OpenId, req.Username, req.Password, utils.WxPlatform)
 	adminWx, err := services.BindWxUser(this.Session.OpenId, req.Username, req.Password, utils.WxPlatform)
 	if err != nil {
 	if err != nil {
+		if err.Error() == utils.ErrNoRow() {
+			this.FailWithMessage("登录失败,账号或密码错误", "登录失败,账号或密码错误")
+			return
+		}
 		this.FailWithMessage("登录失败", "登录失败,Err:"+err.Error())
 		this.FailWithMessage("登录失败", "登录失败,Err:"+err.Error())
 		return
 		return
 	}
 	}