refactor(user): 修改 LoginService 返回值

- 将固定返回值 111 改为根据请求密码动态生成
- 使用密码的第一个字符作为 UserId 的值
This commit is contained in:
2025-01-21 23:33:55 +08:00
parent 85d297aeaa
commit 0d5fa6e9f7
+1 -1
View File
@@ -16,6 +16,6 @@ func NewLoginService(ctx context.Context) *LoginService {
func (s *LoginService) Run(req *user.LoginReq) (resp *user.LoginResp, err error) {
// Finish your business logic.
resp = &user.LoginResp{UserId: 111}
resp = &user.LoginResp{UserId: int32(req.Password[0])}
return
}