style(formatter): 格式化代码中的缩进和空行
- 统一了结构体字段的对齐方式,保持一致的缩进 - 调整了 import 语句的顺序,将 fmt 移至合适位置 - 修复了多处多余的空行和空白字符 - 规范化了注释的缩进格式 - 整理了路由配置的缩进层次 - 调整了常量定义的对齐格式
This commit is contained in:
@@ -435,15 +435,15 @@ func serveUploadFileHandler(ctx *svc.ServiceContext) http.HandlerFunc {
|
||||
|
||||
// diskStatusView 磁盘状态视图(供接口/页面告警条使用)。
|
||||
type diskStatusView struct {
|
||||
RootDir string `json:"rootDir"`
|
||||
UsedPercent int `json:"usedPercent"`
|
||||
FreeBytes uint64 `json:"freeBytes"`
|
||||
TotalBytes uint64 `json:"totalBytes"`
|
||||
WarnPercent int `json:"warnPercent"`
|
||||
CritPercent int `json:"critPercent"`
|
||||
Level string `json:"level"` // ok / warn / critical
|
||||
Message string `json:"message"`
|
||||
CheckedUnix int64 `json:"checkedAt"`
|
||||
RootDir string `json:"rootDir"`
|
||||
UsedPercent int `json:"usedPercent"`
|
||||
FreeBytes uint64 `json:"freeBytes"`
|
||||
TotalBytes uint64 `json:"totalBytes"`
|
||||
WarnPercent int `json:"warnPercent"`
|
||||
CritPercent int `json:"critPercent"`
|
||||
Level string `json:"level"` // ok / warn / critical
|
||||
Message string `json:"message"`
|
||||
CheckedUnix int64 `json:"checkedAt"`
|
||||
}
|
||||
|
||||
// diskStatus 读取附件根目录所在磁盘剩余空间并给出告警级别。
|
||||
|
||||
Reference in New Issue
Block a user