From 02b95b16f92f800a1c7396730e27e7bbffef834e Mon Sep 17 00:00:00 2001 From: wenxu12345 <44203734@qq.com> Date: Wed, 9 Feb 2022 09:50:03 +0800 Subject: [PATCH] Refactor code --- pkg/common/db/mysql_model/im_mysql_model/friend_request_model.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/common/db/mysql_model/im_mysql_model/friend_request_model.go b/pkg/common/db/mysql_model/im_mysql_model/friend_request_model.go index 693bd71ac..bcb734281 100644 --- a/pkg/common/db/mysql_model/im_mysql_model/friend_request_model.go +++ b/pkg/common/db/mysql_model/im_mysql_model/friend_request_model.go @@ -78,6 +78,7 @@ func InsertFriendApplication(friendRequest *db.FriendRequest, args map[string]in } friendRequest.CreateTime = time.Now() + args["create_time"] = friendRequest.CreateTime u := dbConn.Model(friendRequest).Updates(args) //u := dbConn.Table("friend_requests").Where("from_user_id=? and to_user_id=?", // friendRequest.FromUserID, friendRequest.ToUserID).Update(&friendRequest)