🎨 优化项目结构 && 完善ai配置
This commit is contained in:
@@ -4,15 +4,25 @@ import (
|
||||
"git.echol.cn/loser/ai_proxy/server/global"
|
||||
)
|
||||
|
||||
// SysApi API管理
|
||||
type SysApi struct {
|
||||
global.GVA_MODEL
|
||||
Path string `json:"path" gorm:"comment:API路径;size:255;not null"`
|
||||
Description string `json:"description" gorm:"comment:API描述;size:500"`
|
||||
ApiGroup string `json:"apiGroup" gorm:"comment:API分组;size:100"`
|
||||
Method string `json:"method" gorm:"comment:请求方法;size:20;not null"` // GET/POST/PUT/DELETE
|
||||
Path string `json:"path" gorm:"comment:api路径"` // api路径
|
||||
Description string `json:"description" gorm:"comment:api中文描述"` // api中文描述
|
||||
ApiGroup string `json:"apiGroup" gorm:"comment:api组"` // api组
|
||||
Method string `json:"method" gorm:"default:POST;comment:方法"` // 方法:创建POST(默认)|查看GET|更新PUT|删除DELETE
|
||||
}
|
||||
|
||||
func (SysApi) TableName() string {
|
||||
return "sys_apis"
|
||||
}
|
||||
|
||||
type SysIgnoreApi struct {
|
||||
global.GVA_MODEL
|
||||
Path string `json:"path" gorm:"comment:api路径"` // api路径
|
||||
Method string `json:"method" gorm:"default:POST;comment:方法"` // 方法:创建POST(默认)|查看GET|更新PUT|删除DELETE
|
||||
Flag bool `json:"flag" gorm:"-"` // 是否忽略
|
||||
}
|
||||
|
||||
func (SysIgnoreApi) TableName() string {
|
||||
return "sys_ignore_apis"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user