统一表创建表的方式

This commit is contained in:
2026-04-28 16:38:39 +08:00
parent 542d0c394b
commit 5d9d73cb56
9 changed files with 191 additions and 195 deletions
+9 -9
View File
@@ -35,16 +35,16 @@ func GetRealIP(c *gin.Context) string {
return c.ClientIP()
}
func LogAdd(c *gin.Context, msg string) {
// func LogAdd(c *gin.Context, msg string) {
var logtemp APIRequestLog_
// var logtemp APIRequestLog_
logtemp.IPAddress = GetRealIP(c)
logtemp.Path = c.Request.URL.Path
logtemp.Method = c.Request.Method
logtemp.Message = msg
// logtemp.IPAddress = GetRealIP(c)
// logtemp.Path = c.Request.URL.Path
// logtemp.Method = c.Request.Method
// logtemp.Message = msg
//fmt.Println(logtemp)
DB.Create(&logtemp)
// //fmt.Println(logtemp)
// DB.Create(&logtemp)
}
// }