🎨 更新项目版本
This commit is contained in:
@@ -158,7 +158,7 @@ func (r *AutoCode) Pretreatment() error {
|
||||
r.NeedJSON = true
|
||||
case "time.Time":
|
||||
r.HasTimer = true
|
||||
if r.Fields[i].FieldSearchType != "" {
|
||||
if r.Fields[i].FieldSearchType != "" && r.Fields[i].FieldSearchType != "BETWEEN" && r.Fields[i].FieldSearchType != "NOT BETWEEN" {
|
||||
r.HasSearchTimer = true
|
||||
}
|
||||
}
|
||||
|
16
model/system/request/sys_auto_code_mcp.go
Normal file
16
model/system/request/sys_auto_code_mcp.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package request
|
||||
|
||||
type AutoMcpTool struct {
|
||||
Name string `json:"name" form:"name" binding:"required"`
|
||||
Description string `json:"description" form:"description" binding:"required"`
|
||||
Params []struct {
|
||||
Name string `json:"name" form:"name" binding:"required"`
|
||||
Description string `json:"description" form:"description" binding:"required"`
|
||||
Type string `json:"type" form:"type" binding:"required"` // string, number, boolean, object, array
|
||||
Required bool `json:"required" form:"required"`
|
||||
Default string `json:"default" form:"default"`
|
||||
} `json:"params" form:"params"`
|
||||
Response []struct {
|
||||
Type string `json:"type" form:"type" binding:"required"` // text, image
|
||||
} `json:"response" form:"response"`
|
||||
}
|
@@ -33,6 +33,11 @@ type ChangePasswordReq struct {
|
||||
NewPassword string `json:"newPassword"` // 新密码
|
||||
}
|
||||
|
||||
type ResetPassword struct {
|
||||
ID uint `json:"ID" form:"ID"`
|
||||
Password string `json:"password" form:"password" gorm:"comment:用户登录密码"` // 用户登录密码
|
||||
}
|
||||
|
||||
// SetUserAuth Modify user's auth structure
|
||||
type SetUserAuth struct {
|
||||
AuthorityId uint `json:"authorityId"` // 角色ID
|
||||
@@ -51,7 +56,6 @@ type ChangeUserInfo struct {
|
||||
AuthorityIds []uint `json:"authorityIds" gorm:"-"` // 角色ID
|
||||
Email string `json:"email" gorm:"comment:用户邮箱"` // 用户邮箱
|
||||
HeaderImg string `json:"headerImg" gorm:"default:https://qmplusimg.henrongyi.top/gva_header.jpg;comment:用户头像"` // 用户头像
|
||||
SideMode string `json:"sideMode" gorm:"comment:用户侧边主题"` // 用户侧边主题
|
||||
Enable int `json:"enable" gorm:"comment:冻结用户"` //冻结用户
|
||||
Authorities []system.SysAuthority `json:"-" gorm:"many2many:sys_user_authority;"`
|
||||
}
|
||||
|
40
model/system/request/sys_version.go
Normal file
40
model/system/request/sys_version.go
Normal file
@@ -0,0 +1,40 @@
|
||||
package request
|
||||
|
||||
import (
|
||||
"git.echol.cn/loser/lckt/model/common/request"
|
||||
"git.echol.cn/loser/lckt/model/system"
|
||||
"time"
|
||||
)
|
||||
|
||||
type SysVersionSearch struct {
|
||||
CreatedAtRange []time.Time `json:"createdAtRange" form:"createdAtRange[]"`
|
||||
VersionName *string `json:"versionName" form:"versionName"`
|
||||
VersionCode *string `json:"versionCode" form:"versionCode"`
|
||||
request.PageInfo
|
||||
}
|
||||
|
||||
// ExportVersionRequest 导出版本请求结构体
|
||||
type ExportVersionRequest struct {
|
||||
VersionName string `json:"versionName" binding:"required"` // 版本名称
|
||||
VersionCode string `json:"versionCode" binding:"required"` // 版本号
|
||||
Description string `json:"description"` // 版本描述
|
||||
MenuIds []uint `json:"menuIds"` // 选中的菜单ID列表
|
||||
ApiIds []uint `json:"apiIds"` // 选中的API ID列表
|
||||
DictIds []uint `json:"dictIds"` // 选中的字典ID列表
|
||||
}
|
||||
|
||||
// ImportVersionRequest 导入版本请求结构体
|
||||
type ImportVersionRequest struct {
|
||||
VersionInfo VersionInfo `json:"version" binding:"required"` // 版本信息
|
||||
ExportMenu []system.SysBaseMenu `json:"menus"` // 菜单数据,直接复用SysBaseMenu
|
||||
ExportApi []system.SysApi `json:"apis"` // API数据,直接复用SysApi
|
||||
ExportDictionary []system.SysDictionary `json:"dictionaries"` // 字典数据,直接复用SysDictionary
|
||||
}
|
||||
|
||||
// VersionInfo 版本信息结构体
|
||||
type VersionInfo struct {
|
||||
Name string `json:"name" binding:"required"` // 版本名称
|
||||
Code string `json:"code" binding:"required"` // 版本号
|
||||
Description string `json:"description"` // 版本描述
|
||||
ExportTime string `json:"exportTime"` // 导出时间
|
||||
}
|
14
model/system/response/sys_version.go
Normal file
14
model/system/response/sys_version.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package response
|
||||
|
||||
import (
|
||||
"git.echol.cn/loser/lckt/model/system"
|
||||
"git.echol.cn/loser/lckt/model/system/request"
|
||||
)
|
||||
|
||||
// ExportVersionResponse 导出版本响应结构体
|
||||
type ExportVersionResponse struct {
|
||||
Version request.VersionInfo `json:"version"` // 版本信息
|
||||
Menus []system.SysBaseMenu `json:"menus"` // 菜单数据,直接复用SysBaseMenu
|
||||
Apis []system.SysApi `json:"apis"` // API数据,直接复用SysApi
|
||||
Dictionaries []system.SysDictionary `json:"dictionaries"` // 字典数据,直接复用SysDictionary
|
||||
}
|
@@ -21,12 +21,13 @@ type SysBaseMenu struct {
|
||||
}
|
||||
|
||||
type Meta struct {
|
||||
ActiveName string `json:"activeName" gorm:"comment:高亮菜单"`
|
||||
KeepAlive bool `json:"keepAlive" gorm:"comment:是否缓存"` // 是否缓存
|
||||
DefaultMenu bool `json:"defaultMenu" gorm:"comment:是否是基础路由(开发中)"` // 是否是基础路由(开发中)
|
||||
Title string `json:"title" gorm:"comment:菜单名"` // 菜单名
|
||||
Icon string `json:"icon" gorm:"comment:菜单图标"` // 菜单图标
|
||||
CloseTab bool `json:"closeTab" gorm:"comment:自动关闭tab"` // 自动关闭tab
|
||||
ActiveName string `json:"activeName" gorm:"comment:高亮菜单"`
|
||||
KeepAlive bool `json:"keepAlive" gorm:"comment:是否缓存"` // 是否缓存
|
||||
DefaultMenu bool `json:"defaultMenu" gorm:"comment:是否是基础路由(开发中)"` // 是否是基础路由(开发中)
|
||||
Title string `json:"title" gorm:"comment:菜单名"` // 菜单名
|
||||
Icon string `json:"icon" gorm:"comment:菜单图标"` // 菜单图标
|
||||
CloseTab bool `json:"closeTab" gorm:"comment:自动关闭tab"` // 自动关闭tab
|
||||
TransitionType string `json:"transitionType" gorm:"comment:路由切换动画"` // 路由切换动画
|
||||
}
|
||||
|
||||
type SysBaseMenuParameter struct {
|
||||
|
20
model/system/sys_version.go
Normal file
20
model/system/sys_version.go
Normal file
@@ -0,0 +1,20 @@
|
||||
// 自动生成模板SysVersion
|
||||
package system
|
||||
|
||||
import (
|
||||
"git.echol.cn/loser/lckt/global"
|
||||
)
|
||||
|
||||
// 版本管理 结构体 SysVersion
|
||||
type SysVersion struct {
|
||||
global.GVA_MODEL
|
||||
VersionName *string `json:"versionName" form:"versionName" gorm:"comment:版本名称;column:version_name;size:255;" binding:"required"` //版本名称
|
||||
VersionCode *string `json:"versionCode" form:"versionCode" gorm:"comment:版本号;column:version_code;size:100;" binding:"required"` //版本号
|
||||
Description *string `json:"description" form:"description" gorm:"comment:版本描述;column:description;size:500;"` //版本描述
|
||||
VersionData *string `json:"versionData" form:"versionData" gorm:"comment:版本数据JSON;column:version_data;type:longtext;postgres:type:text;sqlite:type:text;"` //版本数据
|
||||
}
|
||||
|
||||
// TableName 版本管理 SysVersion自定义表名 sys_versions
|
||||
func (SysVersion) TableName() string {
|
||||
return "sys_versions"
|
||||
}
|
Reference in New Issue
Block a user