(c *gin.Context)
| 66 | } |
| 67 | |
| 68 | func SearchUserLogs(c *gin.Context) { |
| 69 | keyword := c.Query("keyword") |
| 70 | userId := c.GetInt("id") |
| 71 | logs, err := model.SearchUserLogs(userId, keyword) |
| 72 | if err != nil { |
| 73 | common.ApiError(c, err) |
| 74 | return |
| 75 | } |
| 76 | c.JSON(http.StatusOK, gin.H{ |
| 77 | "success": true, |
| 78 | "message": "", |
| 79 | "data": logs, |
| 80 | }) |
| 81 | return |
| 82 | } |
| 83 | |
| 84 | func GetLogByKey(c *gin.Context) { |
| 85 | key := c.Query("key") |
nothing calls this directly
no test coverage detected