任务一完成

This commit is contained in:
Yvan
2026-01-07 10:13:35 +08:00
parent e8f8c2819a
commit 35ab7c0b70
24 changed files with 3397 additions and 160 deletions
+30
View File
@@ -0,0 +1,30 @@
package model
import (
"time"
"gorm.io/gorm"
)
// Model 基础模型
type Model struct {
ID uint `gorm:"primarykey" json:"id"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
}
// PageInfo 分页请求
type PageInfo struct {
Page int `json:"page" form:"page"`
PageSize int `json:"pageSize" form:"pageSize"`
Keyword string `json:"keyword" form:"keyword"`
}
// PageResult 分页响应
type PageResult struct {
List interface{} `json:"list"`
Total int64 `json:"total"`
Page int `json:"page"`
PageSize int `json:"pageSize"`
}