用户权限更新问题
This commit is contained in:
parent
2e96977f26
commit
fa0781c353
|
|
@ -1,6 +1,7 @@
|
|||
package service
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"regexp"
|
||||
"videoplayer/dao"
|
||||
"videoplayer/proto"
|
||||
|
|
@ -44,6 +45,7 @@ func GetUserByNameLike(name string) []proto.User {
|
|||
|
||||
func UpdateUser(user_id int, req proto.UpdateUserInfoReq) (int, error) {
|
||||
cur_user := dao.FindUserByID2(user_id)
|
||||
fmt.Println("cur_user:", cur_user, "req:", req)
|
||||
if user_id == req.ID {
|
||||
dao.UpdateUserByID2(user_id, req)
|
||||
return user_id, nil
|
||||
|
|
|
|||
Loading…
Reference in New Issue