refactor(user): 修改 LoginService 返回值
- 将固定返回值 111 改为根据请求密码动态生成 - 使用密码的第一个字符作为 UserId 的值
This commit is contained in:
parent
85d297aeaa
commit
0d5fa6e9f7
@ -16,6 +16,6 @@ func NewLoginService(ctx context.Context) *LoginService {
|
|||||||
func (s *LoginService) Run(req *user.LoginReq) (resp *user.LoginResp, err error) {
|
func (s *LoginService) Run(req *user.LoginReq) (resp *user.LoginResp, err error) {
|
||||||
// Finish your business logic.
|
// Finish your business logic.
|
||||||
|
|
||||||
resp = &user.LoginResp{UserId: 111}
|
resp = &user.LoginResp{UserId: int32(req.Password[0])}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user