mirror of https://github.com/1Panel-dev/1Panel
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
51 lines
1.1 KiB
51 lines
1.1 KiB
4 months ago
|
package dto
|
||
|
|
||
|
import (
|
||
|
"time"
|
||
|
)
|
||
|
|
||
|
type OperationLog struct {
|
||
|
ID uint `json:"id"`
|
||
|
Source string `json:"source"`
|
||
|
|
||
|
IP string `json:"ip"`
|
||
|
Path string `json:"path"`
|
||
|
Method string `json:"method"`
|
||
|
UserAgent string `json:"userAgent"`
|
||
|
|
||
|
Latency time.Duration `json:"latency"`
|
||
|
Status string `json:"status"`
|
||
|
Message string `json:"message"`
|
||
|
|
||
|
DetailZH string `json:"detailZH"`
|
||
|
DetailEN string `json:"detailEN"`
|
||
|
CreatedAt time.Time `json:"createdAt"`
|
||
|
}
|
||
|
|
||
|
type SearchOpLogWithPage struct {
|
||
|
PageInfo
|
||
|
Source string `json:"source"`
|
||
|
Status string `json:"status"`
|
||
|
Operation string `json:"operation"`
|
||
|
}
|
||
|
|
||
|
type SearchLgLogWithPage struct {
|
||
|
PageInfo
|
||
|
IP string `json:"ip"`
|
||
|
Status string `json:"status"`
|
||
|
}
|
||
|
|
||
|
type LoginLog struct {
|
||
|
ID uint `json:"id"`
|
||
|
IP string `json:"ip"`
|
||
|
Address string `json:"address"`
|
||
|
Agent string `json:"agent"`
|
||
|
Status string `json:"status"`
|
||
|
Message string `json:"message"`
|
||
|
CreatedAt time.Time `json:"createdAt"`
|
||
|
}
|
||
|
|
||
|
type CleanLog struct {
|
||
|
LogType string `json:"logType" validate:"required,oneof=login operation"`
|
||
|
}
|