Refactor code

pull/131/head
wenxu12345 3 years ago
parent db37d0197a
commit 447ccdf042

@ -31,9 +31,9 @@ func main() {
friendRouterGroup := r.Group("/friend")
{
// friendRouterGroup.POST("/get_friends_info", friend.GetFriendsInfo)
friendRouterGroup.POST("/add_friend", friend.AddFriend) //1
friendRouterGroup.POST("/get_friend_apply_list", friend.GetFriendApplyList)
friendRouterGroup.POST("/get_self_apply_list", friend.GetSelfApplyList) //1
friendRouterGroup.POST("/add_friend", friend.AddFriend) //1
friendRouterGroup.POST("/get_friend_apply_list", friend.GetFriendApplyList) //1
friendRouterGroup.POST("/get_self_apply_list", friend.GetSelfApplyList) //1
friendRouterGroup.POST("/get_friend_list", friend.GetFriendList)
friendRouterGroup.POST("/add_blacklist", friend.AddBlacklist)
friendRouterGroup.POST("/get_blacklist", friend.GetBlacklist)

@ -120,6 +120,8 @@ func AddFriendResponse(c *gin.Context) {
}
req := &rpc.AddFriendResponseReq{CommID: &rpc.CommID{}}
utils.CopyStructFields(req.CommID, &params.ParamsCommFriend)
req.HandleMsg = params.HandleMsg
req.Flag = params.Flag
var ok bool
ok, req.CommID.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token"))
if !ok {

Loading…
Cancel
Save