12345678910111213141516171819202122232425262728293031323334 |
- package entity
- type RecordListReq struct {
- ID string `json:"id" bson:"_id"` // ID
- UserName string `json:"user_name" bson:"user_name"` // 用户名
- RoleId string `json:"role_id" bson:"role_id"` // 角色ID
- Path string `json:"path" bson:"url"` // 请求路径
- StatusCode int `json:"status_code" bson:"status_code"` // HTTP状态码
- ClientIP string `json:"client_ip"` // 客户端IP
- StartTime int64 `json:"start_time"` // 开始时间
- EndTime int64 `json:"end_time"` // 结束时间
- DurMin int64 `json:"dur_min"` // 请求耗时(毫秒)最小值
- DurMax int64 `json:"dur_max"` // 请求耗时(毫秒)最大值
- Page int `json:"page"` // 页码
- Size int `json:"size"` // 每页数量
- }
- type RecordListResp struct {
- Details []*RecordListDetail `json:"details"`
- Total int64 `json:"total"`
- }
- type RecordListDetail struct {
- Id string `json:"id" bson:"_id"` // 自增ID
- Username string `json:"user_name" bson:"user_name"` // 用户名
- RoleId string `json:"role_id" bson:"role_id"` // 角色ID
- Path string `json:"url" bson:"url"` // 请求路径
- Method string `json:"method" bson:"method"` // 请求方法
- StatusCode int `json:"status_code" bson:"status_code"` // HTTP状态码
- Dur int64 `json:"dur" bson:"dur"` // 请求耗时(毫秒)
- ClientIP string `json:"client_ip" bson:"client_ip"` // 客户端IP
- ErrorMessage string `json:"error_message" bson:"error_message"` // 错误信息
- CreatedAt int64 `json:"created_at" bson:"created_at"`
- }
|