|
@@ -260,7 +260,7 @@ func (this *UserController) Login() {
|
|
br.ErrMsg = "无效的登录方式,Err:" + err.Error()
|
|
br.ErrMsg = "无效的登录方式,Err:" + err.Error()
|
|
return
|
|
return
|
|
}
|
|
}
|
|
- user, err = services.BindWxUser(openId, req.Mobile, req.Email)
|
|
|
|
|
|
+ user, err = services.BindWxUser(openId, req.Mobile, req.Email, req.CountryCode)
|
|
userId := user.UserId
|
|
userId := user.UserId
|
|
var token string
|
|
var token string
|
|
tokenItem, err := models.GetTokenByOpenId(openId)
|
|
tokenItem, err := models.GetTokenByOpenId(openId)
|
|
@@ -336,7 +336,7 @@ func (this *UserController) Detail() {
|
|
}
|
|
}
|
|
uid := user.UserId
|
|
uid := user.UserId
|
|
|
|
|
|
- fmt.Println("uid:",uid)
|
|
|
|
|
|
+ fmt.Println("uid:", uid)
|
|
|
|
|
|
var hasPermission int
|
|
var hasPermission int
|
|
detail := new(models.UserDetail)
|
|
detail := new(models.UserDetail)
|
|
@@ -808,9 +808,9 @@ func (this *UserController) ApplyTryOut() {
|
|
uid := user.UserId
|
|
uid := user.UserId
|
|
|
|
|
|
//缓存校验
|
|
//缓存校验
|
|
- cacheKey := fmt.Sprint("xygx:apply_record:add:",uid)
|
|
|
|
|
|
+ cacheKey := fmt.Sprint("xygx:apply_record:add:", uid)
|
|
ttlTime := utils.Rc.GetRedisTTL(cacheKey)
|
|
ttlTime := utils.Rc.GetRedisTTL(cacheKey)
|
|
- if ttlTime > 0{
|
|
|
|
|
|
+ if ttlTime > 0 {
|
|
br.Msg = "申请失败,申请过于频繁"
|
|
br.Msg = "申请失败,申请过于频繁"
|
|
br.ErrMsg = "申请失败,申请过于频繁"
|
|
br.ErrMsg = "申请失败,申请过于频繁"
|
|
return
|
|
return
|
|
@@ -946,9 +946,10 @@ func (this *UserController) ApplyTryOut() {
|
|
br.Data = sellerMobile
|
|
br.Data = sellerMobile
|
|
}
|
|
}
|
|
|
|
|
|
-func sentMsgToSeller(){
|
|
|
|
|
|
+func sentMsgToSeller() {
|
|
|
|
|
|
}
|
|
}
|
|
|
|
+
|
|
//func init() {
|
|
//func init() {
|
|
// fmt.Println("start")
|
|
// fmt.Println("start")
|
|
// realName:="沈涛"
|
|
// realName:="沈涛"
|
|
@@ -959,4 +960,4 @@ func sentMsgToSeller(){
|
|
// services.SendPermissionApplyTemplateMsg(realName, companyName, mobile, openId, applyMethod)
|
|
// services.SendPermissionApplyTemplateMsg(realName, companyName, mobile, openId, applyMethod)
|
|
// return
|
|
// return
|
|
// fmt.Println("end")
|
|
// fmt.Println("end")
|
|
-//}
|
|
|
|
|
|
+//}
|