Files
PandaX/apps/develop/entity/dev_gen_table.go
PandaGoAdmin b6a8fe5e1b 代码生成
2022-01-03 19:03:39 +08:00

37 lines
2.4 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package entity
import "pandax/base/model"
type DevGenTable struct {
TableId int64 `gorm:"primaryKey;autoIncrement" json:"tableId"` // 编号
TableName string `gorm:"table_name" json:"tableName"` // 表名称
TableComment string `gorm:"table_comment" json:"tableComment"` // 表描述
ClassName string `gorm:"class_name" json:"className"` // 实体类名称
TplCategory string `gorm:"tpl_category" json:"tplCategory"` // 使用的模板crud单表操作 tree树表操作
PackageName string `gorm:"package_name" json:"packageName"` // 生成包路径
ModuleName string `gorm:"module_name" json:"moduleName"` // 生成模块名
BusinessName string `gorm:"business_name" json:"businessName"` // 生成业务名
FunctionName string `gorm:"function_name" json:"functionName"` // 生成功能名
FunctionAuthor string `gorm:"function_author" json:"functionAuthor"` // 生成功能作者
TreeCode string `gorm:"tree_code" json:"treeCode"`
TreeParentCode string `gorm:"tree_parent_code" json:"treeParentCode"`
TreeName string `gorm:"tree_name" json:"treeName"`
Options string `gorm:"options" json:"options"` // 其它生成选项
Remark string `gorm:"remark" json:"remark"` // 备注
PkColumn string `gorm:"pk_column;" json:"pkColumn"`
PkGoField string `gorm:"pk_go_field" json:"pkGoField"`
PkJsonField string `gorm:"pk_json_field" json:"pkJsonField"`
Columns []DevGenTableColumn `gorm:"-" json:"columns"` // 字段信息
model.BaseModel
}
type DBTables struct {
TableName string `gorm:"column:TABLE_NAME" json:"tableName"`
Engine string `gorm:"column:ENGINE" json:"engine"`
TableRows string `gorm:"column:TABLE_ROWS" json:"tableRows"`
TableCollation string `gorm:"column:TABLE_COLLATION" json:"tableCollation"`
CreateTime string `gorm:"column:CREATE_TIME" json:"createTime"`
UpdateTime string `gorm:"column:UPDATE_TIME" json:"updateTime"`
TableComment string `gorm:"column:TABLE_COMMENT" json:"tableComment"`
}