初始化项目文件

This commit is contained in:
2025-07-11 16:54:11 +08:00
parent 6bffd582a0
commit 39fedaac16
213 changed files with 16944 additions and 0 deletions

55
api_file/model/sysinfo.go Normal file
View File

@ -0,0 +1,55 @@
package model
import "gorm.io/gorm"
type SysInfo struct {
Date string `json:"date" gorm:"index:select_info"`
Datetime string `json:"datetime" gorm:"index:datetime_index"`
Username string `json:"username" gorm:"index:select_info"`
Hostname string `json:"hostname"`
Ip string `json:"ip" gorm:"index:select_info"`
SysVersion string `json:"sysVersion"`
PhysicalCount int `json:"physicalCount"`
LogicalCount int `json:"logicalCount"`
CpuPer float64 `json:"cpuPer"`
MemTotal string `json:"memTotal"`
MemUsed string `json:"memUsed"`
MemPer float64 `json:"memPer"`
DiskPoint string `json:"diskPoint"`
DiskTotal string `json:"diskTotal"`
DiskUsed string `json:"diskUsed"`
DiskPer string `json:"diskPer"`
NetSent int64 `json:"netSent"`
NetRec int64 `json:"netRec"`
SentSpeed string `json:"sentSpeed"`
RecSpeed string `json:"recSpeed"`
gorm.Model
}
type SysInfoOld struct {
Datetime string `json:"datetime" gorm:"index:datetime_index"`
Username string `json:"username"`
Hostname string `json:"hostname"`
Ip string `json:"ip"`
SysVersion string `json:"sysVersion"`
PhysicalCount int `json:"physicalCount"`
LogicalCount int `json:"logicalCount"`
CpuPer float64 `json:"cpuPer"`
MemTotal string `json:"memTotal"`
MemUsed string `json:"memUsed"`
MemPer float64 `json:"memPer"`
DiskPoint string `json:"diskPoint"`
DiskTotal string `json:"diskTotal"`
DiskUsed string `json:"diskUsed"`
DiskPer string `json:"diskPer"`
NetSent int64 `json:"netSent"`
NetRec int64 `json:"netRec"`
SentSpeed string `json:"sentSpeed"`
RecSpeed string `json:"recSpeed"`
}
type SysInfoUpdateLog struct {
Datetime string `json:"datetime"`
Update bool `json:"update"`
gorm.Model
}