| | |
| | | |
| | | } |
| | | |
| | | func (sv *UserService) Login(phoneNum, code string) (bool,*vo.UserInfo,error) { |
| | | func (sv *UserService) Login(phoneNum, code, cid string) (bool,*vo.UserInfo,error) { |
| | | if verifyCode(phoneNum, code) { |
| | | carSv := NewCarService() |
| | | |
| | |
| | | plateNos = append(plateNos, up.PlateNo) |
| | | } |
| | | } |
| | | //客户端cid绑定别名 |
| | | if cid != "" { |
| | | go func() { |
| | | bindR, bindE := BindAlias(cid, phoneNum) |
| | | fmt.Println("bind cid:",cid, "phoneNum:",phoneNum,"result:", bindR, "err:", bindE) |
| | | }() |
| | | } |
| | | return true, &vo.UserInfo{ |
| | | UserId: u.Id, |
| | | PhoneNum: phoneNum, |
| | |
| | | plateNos = append(plateNos, up.PlateNo) |
| | | } |
| | | } |
| | | //客户端cid绑定别名 |
| | | if cid != "" { |
| | | go func() { |
| | | bindR, bindE := BindAlias(cid, phoneNum) |
| | | fmt.Println("bind cid:",cid, "phoneNum:",phoneNum,"result:", bindR, "err:", bindE) |
| | | }() |
| | | } |
| | | return true, &vo.UserInfo{ |
| | | UserId: tmpUser.Id, |
| | | PhoneNum: phoneNum, |