增加自动创建搜索功能 增加搜索条件 增加数据库注释 增加插件功能(0.0.1版 请勿用于生产)
This commit is contained in:
@@ -6,9 +6,9 @@ import (
|
||||
|
||||
type ExaCustomer struct {
|
||||
gorm.Model
|
||||
CustomerName string `json:"customerName" form:"customerName"`
|
||||
CustomerPhoneData string `json:"customerPhoneData" form:"customerPhoneData"`
|
||||
SysUserID uint `json:"sysUserId" form:"sysUserId"`
|
||||
SysUserAuthorityID string `json:"sysUserAuthorityID" form:"sysUserAuthorityID"`
|
||||
SysUser SysUser `json:"sysUser" form:"sysUser"`
|
||||
CustomerName string `json:"customerName" form:"customerName" gorm:"comment:'客户名'"`
|
||||
CustomerPhoneData string `json:"customerPhoneData" form:"customerPhoneData" gorm:"comment:'客户手机号'"`
|
||||
SysUserID uint `json:"sysUserId" form:"sysUserId" gorm:"comment:'管理ID'"`
|
||||
SysUserAuthorityID string `json:"sysUserAuthorityID" form:"sysUserAuthorityID" gorm:"comment:'管理角色ID'"`
|
||||
SysUser SysUser `json:"sysUser" form:"sysUser" gorm:"comment:'管理详情'"`
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@ import (
|
||||
|
||||
type ExaFileUploadAndDownload struct {
|
||||
gorm.Model
|
||||
Name string `json:"name"`
|
||||
Url string `json:"url"`
|
||||
Tag string `json:"tag"`
|
||||
Key string `json:"key"`
|
||||
Name string `json:"name" gorm:"comment:'文件名'"`
|
||||
Url string `json:"url" gorm:"comment:'文件地址'"`
|
||||
Tag string `json:"tag" gorm:"comment:'文件标签'"`
|
||||
Key string `json:"key" gorm:"comment:'编号'"`
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@ import (
|
||||
|
||||
type SysApi struct {
|
||||
gorm.Model
|
||||
Path string `json:"path"`
|
||||
Description string `json:"description"`
|
||||
ApiGroup string `json:"apiGroup"`
|
||||
Method string `json:"method" gorm:"default:'POST'"`
|
||||
Path string `json:"path" gorm:"comment:'api路径'"`
|
||||
Description string `json:"description" gorm:"comment:'api中文描述'"`
|
||||
ApiGroup string `json:"apiGroup" gorm:"comment:'api组'"`
|
||||
Method string `json:"method" gorm:"default:'POST'" gorm:"comment:'方法'"`
|
||||
}
|
||||
|
||||
@@ -8,9 +8,9 @@ type SysAuthority struct {
|
||||
CreatedAt time.Time
|
||||
UpdatedAt time.Time
|
||||
DeletedAt *time.Time `sql:"index"`
|
||||
AuthorityId string `json:"authorityId" gorm:"not null;unique;primary_key"`
|
||||
AuthorityName string `json:"authorityName"`
|
||||
ParentId string `json:"parentId"`
|
||||
AuthorityId string `json:"authorityId" gorm:"not null;unique;primary_key" gorm:"comment:'角色ID'"`
|
||||
AuthorityName string `json:"authorityName" gorm:"comment:'角色名'"`
|
||||
ParentId string `json:"parentId" gorm:"comment:'父角色ID'"`
|
||||
DataAuthorityId []SysAuthority `json:"dataAuthorityId" gorm:"many2many:sys_data_authority_id;association_jointable_foreignkey:data_authority_id"`
|
||||
Children []SysAuthority `json:"children"`
|
||||
SysBaseMenus []SysBaseMenu `json:"menus" gorm:"many2many:sys_authority_menus;"`
|
||||
|
||||
@@ -2,7 +2,7 @@ package model
|
||||
|
||||
type SysMenu struct {
|
||||
SysBaseMenu
|
||||
MenuId string `json:"menuId"`
|
||||
AuthorityId string `json:"-"`
|
||||
MenuId string `json:"menuId" gorm:"comment:'菜单ID'"`
|
||||
AuthorityId string `json:"-" gorm:"comment:'角色ID'"`
|
||||
Children []SysMenu `json:"children"`
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ type AutoCodeStruct struct {
|
||||
StructName string `json:"structName"`
|
||||
PackageName string `json:"packageName"`
|
||||
Abbreviation string `json:"abbreviation"`
|
||||
Description string `json:"description"`
|
||||
AutoCreateApiToSql bool `json:"autoCreateApiToSql"`
|
||||
Fields []Field `json:"fields"`
|
||||
}
|
||||
@@ -14,5 +15,7 @@ type Field struct {
|
||||
FieldDesc string `json:"fieldDesc"`
|
||||
FieldType string `json:"fieldType"`
|
||||
FieldJson string `json:"fieldJson"`
|
||||
Comment string `json:"comment"`
|
||||
ColumnName string `json:"columnName"`
|
||||
}
|
||||
FieldSearchType string `json:"fieldSearchType"`
|
||||
}
|
||||
@@ -7,20 +7,20 @@ import (
|
||||
type SysBaseMenu struct {
|
||||
gorm.Model
|
||||
MenuLevel uint `json:"-"`
|
||||
ParentId string `json:"parentId"`
|
||||
Path string `json:"path"`
|
||||
Name string `json:"name"`
|
||||
Hidden bool `json:"hidden"`
|
||||
Component string `json:"component"`
|
||||
Sort int `json:"sort"`
|
||||
Meta `json:"meta"`
|
||||
ParentId string `json:"parentId" gorm:"comment:'父菜单ID'"`
|
||||
Path string `json:"path" gorm:"comment:'路由path'"`
|
||||
Name string `json:"name" gorm:"comment:'路由name'"`
|
||||
Hidden bool `json:"hidden" gorm:"comment:'是否在列表隐藏'"`
|
||||
Component string `json:"component" gorm:"comment:'对应前端文件路径'"`
|
||||
Sort int `json:"sort" gorm:"comment:'排序标记'"`
|
||||
Meta `json:"meta" gorm:"comment:'附加属性'"`
|
||||
SysAuthoritys []SysAuthority `json:"authoritys" gorm:"many2many:sys_authority_menus;"`
|
||||
Children []SysBaseMenu `json:"children"`
|
||||
}
|
||||
|
||||
type Meta struct {
|
||||
KeepAlive bool `json:"keepAlive"`
|
||||
DefaultMenu bool `json:"defaultMenu"`
|
||||
Title string `json:"title"`
|
||||
Icon string `json:"icon"`
|
||||
KeepAlive bool `json:"keepAlive" gorm:"comment:'是否缓存'"`
|
||||
DefaultMenu bool `json:"defaultMenu" gorm:"comment:'是否是基础路由(开发中)'"`
|
||||
Title string `json:"title" gorm:"comment:'菜单名'"`
|
||||
Icon string `json:"icon" gorm:"comment:'菜单图标'"`
|
||||
}
|
||||
|
||||
@@ -6,5 +6,5 @@ import (
|
||||
|
||||
type JwtBlacklist struct {
|
||||
gorm.Model
|
||||
Jwt string `gorm:"type:text"`
|
||||
Jwt string `gorm:"type:text;comment:'jwt'"`
|
||||
}
|
||||
|
||||
@@ -7,12 +7,12 @@ import (
|
||||
|
||||
type SysUser struct {
|
||||
gorm.Model
|
||||
UUID uuid.UUID `json:"uuid"`
|
||||
Username string `json:"userName"`
|
||||
Password string `json:"-"`
|
||||
NickName string `json:"nickName" gorm:"default:'系统用户'"`
|
||||
HeaderImg string `json:"headerImg" gorm:"default:'http://qmplusimg.henrongyi.top/head.png'"`
|
||||
Authority SysAuthority `json:"authority" gorm:"ForeignKey:AuthorityId;AssociationForeignKey:AuthorityId"`
|
||||
AuthorityId string `json:"authorityId" gorm:"default:888"`
|
||||
UUID uuid.UUID `json:"uuid" gorm:"comment:'用户UUID'"`
|
||||
Username string `json:"userName" gorm:"comment:'用户登录名'"`
|
||||
Password string `json:"-" gorm:"comment:'用户登录密码'"`
|
||||
NickName string `json:"nickName" gorm:"default:'系统用户';comment:'用户昵称'" `
|
||||
HeaderImg string `json:"headerImg" gorm:"default:'http://qmplusimg.henrongyi.top/head.png';comment:'用户头像'"`
|
||||
Authority SysAuthority `json:"authority" gorm:"ForeignKey:AuthorityId;AssociationForeignKey:AuthorityId;comment:'用户角色'"`
|
||||
AuthorityId string `json:"authorityId" gorm:"default:888;comment:'用户角色ID'"`
|
||||
}
|
||||
|
||||
|
||||
@@ -7,19 +7,19 @@ import (
|
||||
// 工作流属性表
|
||||
type SysWorkflow struct {
|
||||
gorm.Model
|
||||
WorkflowNickName string `json:"workflowNickName"` // 工作流名称
|
||||
WorkflowName string `json:"workflowName"` // 工作流英文id
|
||||
WorkflowDescription string `json:"workflowDescription"` // 工作流描述
|
||||
WorkflowStepInfo []SysWorkflowStepInfo `json:"workflowStep"` // 工作流步骤
|
||||
WorkflowNickName string `json:"workflowNickName" gorm:"comment:'工作流中文名称'"` // 工作流名称
|
||||
WorkflowName string `json:"workflowName" gorm:"comment:'工作流英文名称'"` // 工作流英文id
|
||||
WorkflowDescription string `json:"workflowDescription" gorm:"comment:'工作流描述'"` // 工作流描述
|
||||
WorkflowStepInfo []SysWorkflowStepInfo `json:"workflowStep" gorm:"comment:'工作流步骤'"` // 工作流步骤
|
||||
}
|
||||
|
||||
// 工作流状态表
|
||||
type SysWorkflowStepInfo struct {
|
||||
gorm.Model
|
||||
SysWorkflowID uint `json:"workflowID"` // 所属工作流ID
|
||||
IsStrat bool `json:"isStrat"` // 是否是开始流节点
|
||||
StepName string `json:"stepName"` // 工作流名称
|
||||
StepNo float64 `json:"stepNo"` // 步骤id (第几步)
|
||||
StepAuthorityID string `json:"stepAuthorityID"` // 操作者级别id
|
||||
IsEnd bool `json:"isEnd"` // 是否是完结流节点
|
||||
SysWorkflowID uint `json:"workflowID" gorm:"comment:'所属工作流ID'"` // 所属工作流ID
|
||||
IsStrat bool `json:"isStrat" gorm:"comment:'是否是开始流节点'"` // 是否是开始流节点
|
||||
StepName string `json:"stepName" gorm:"comment:'工作流节点名称'"` // 工作流名称
|
||||
StepNo float64 `json:"stepNo" gorm:"comment:'步骤id (第几步)'"` // 步骤id (第几步)
|
||||
StepAuthorityID string `json:"stepAuthorityID" gorm:"comment:'操作者级别id'"` // 操作者级别id
|
||||
IsEnd bool `json:"isEnd" gorm:"comment:'是否是完结流节点'"` // 是否是完结流节点
|
||||
}
|
||||
|
||||
@@ -5,10 +5,10 @@ import "github.com/jinzhu/gorm"
|
||||
// 工作流流转表
|
||||
type SysWorkFlowProcess struct {
|
||||
gorm.Model
|
||||
ApplicationID uint // 当前工作流所属申请的ID
|
||||
CurrentNode string // 当前进度节点
|
||||
HistoricalNode string // 上一个进度节点
|
||||
CurrentUser string // 当前进度操作人
|
||||
HistoricalUser string // 上一个进度的操作人
|
||||
State bool // 状态 是否是正在进行的状态
|
||||
ApplicationID uint `json:"applicationID" gorm:"comment:'当前工作流所属申请的ID'"`// 当前工作流所属申请的ID
|
||||
CurrentNode string `json:"currentNode" gorm:"comment:'当前进度节点'"`// 当前进度节点
|
||||
HistoricalNode string `json:"historicalNode" gorm:"comment:'上一个进度节点'"`// 上一个进度节点
|
||||
CurrentUser string `json:"currentUser" gorm:"comment:'当前进度操作人'"`// 当前进度操作人
|
||||
HistoricalUser string `json:"historicalUser" gorm:"comment:'上一个进度的操作人'"`// 上一个进度的操作人
|
||||
State bool `json:"state" gorm:"comment:'状态 是否是正在进行的状态'"`// 状态 是否是正在进行的状态
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user